]> git.mxchange.org Git - friendica.git/blobdiff - mod/profiles.php
Merge commit 'mike/master'
[friendica.git] / mod / profiles.php
index 54c57f73e45adb74db054617371c977d67b46e8d..d74219501a0ce3501888994bf715e908320188af 100644 (file)
@@ -10,6 +10,8 @@ function profiles_post(&$a) {
 
        $namechanged = false;
 
+       call_hooks('profile_post', $_POST);
+
        if(($a->argc > 1) && ($a->argv[1] !== "new") && intval($a->argv[1])) {
                $orig = q("SELECT * FROM `profile` WHERE `id` = %d AND `uid` = %d LIMIT 1",
                        intval($a->argv[1]),
@@ -201,8 +203,8 @@ function profiles_post(&$a) {
                        $php_path = ((strlen($a->config['php_path'])) ? $a->config['php_path'] : 'php');
                        $url = $_SESSION['my_url'];
                        if($url && strlen(get_config('system','directory_submit_url')))
-                               proc_close(proc_open("\"$php_path\" \"include/directory.php\" \"$url\" &",
-                                       array(),$foo));
+                               //proc_close(proc_open("\"$php_path\" \"include/directory.php\" \"$url\" &", array(),$foo));
+                               proc_run($php_path,"include/directory.php","$url");
                }
        }
 }
@@ -389,6 +391,9 @@ function profiles_content(&$a) {
                        '$contact' => $r[0]['contact']
                ));
 
+               $arr = array('profile' => $r[0], 'entry' => $o);
+               call_hooks('profile_edit', $arr);
+
                return $o;
        }
        else {