]> git.mxchange.org Git - friendica-addons.git/commitdiff
xml escape ljpost vars
authorfriendica <info@friendica.com>
Thu, 1 Mar 2012 08:21:30 +0000 (00:21 -0800)
committerfriendica <info@friendica.com>
Thu, 1 Mar 2012 08:21:30 +0000 (00:21 -0800)
ljpost.tgz
ljpost/ljpost.php

index 5189d6e09312ad392b92620e95eda3e691992840..f14b33d4ac398b832e02f46d3469e83ea8db5a22 100644 (file)
Binary files a/ljpost.tgz and b/ljpost.tgz differ
index 6a85d8f2fe2166affe7b417eda75609f8ca1f2ab..c1b9b9758f58a2b036d239211f65c5eff679e54f 100755 (executable)
@@ -161,16 +161,22 @@ function ljpost_send(&$a,&$b) {
        if($x && strlen($x[0]['timezone']))
                $tz = $x[0]['timezone'];        
 
-       $lj_username = get_pconfig($b['uid'],'ljpost','lj_username');
-       $lj_password = get_pconfig($b['uid'],'ljpost','lj_password');
-       $lj_blog = 'http://www.livejournal.com/interface/xmlrpc';
+       $lj_username = xmlify(get_pconfig($b['uid'],'ljpost','lj_username'));
+       $lj_password = xmlify(get_pconfig($b['uid'],'ljpost','lj_password'));
+       $lj_journal = xmlify(get_pconfig($b['uid'],'ljpost','lj_journal'));
+//     if(! $lj_journal)
+//             $lj_journal = $lj_username;
+
+       $lj_blog = xmlify(get_pconfig($b['uid'],'ljpost','lj_blog'));
+       if(! strlen($lj_blog))
+               $lj_blog = xmlify('http://www.livejournal.com/interface/xmlrpc');
 
        if($lj_username && $lj_password && $lj_blog) {
 
                require_once('include/bbcode.php');
                require_once('include/datetime.php');
 
-               $title = $b['title'];
+               $title = xmlify($b['title']);
                $post = bbcode($b['body']);
                $post = xmlify($post);