]> git.mxchange.org Git - friendica.git/commitdiff
export posts also
authorFriendika <info@friendika.com>
Tue, 22 Mar 2011 10:20:41 +0000 (03:20 -0700)
committerFriendika <info@friendika.com>
Tue, 22 Mar 2011 10:20:41 +0000 (03:20 -0700)
mod/uexport.php

index 423c3a82fa137c1d7d86b8f50005947d198a2f45..d8141534a474b87940ed9165532d5f46db5da04c 100644 (file)
@@ -36,9 +36,19 @@ function uexport_init(&$a) {
                                $profile[][$k] = $v;
        }
 
+       $item = array();
+       $r = q("SELECT * FROM `item` WHERE `uid` = %d ",
+               local_user()
+       );
+       if(count($r)) {
+               foreach($r as $rr)
+                       foreach($rr as $k => $v)
+                               $item[][$k] = $v;
+       }
+
 
 
-       $output = array('user' => $user, 'contact' => $contact, 'profile' => $profile);
+       $output = array('user' => $user, 'contact' => $contact, 'profile' => $profile, 'item' => $item );
 
        header("Content-type: text/json");
        echo str_replace('\\/','/',json_encode($output));