From: <dj...@us...> - 2012-05-11 10:02:33
|
Revision: 9482 http://xoops.svn.sourceforge.net/xoops/?rev=9482&view=rev Author: djculex Date: 2012-05-11 10:02:24 +0000 (Fri, 11 May 2012) Log Message: ----------- - Bugfix: Converting CR to <br> in comments / updates (Cesag) Modified Paths: -------------- XoopsModules/smallworld/trunk/smallworld/comment_ajax.php XoopsModules/smallworld/trunk/smallworld/index.php XoopsModules/smallworld/trunk/smallworld/loadmore.php XoopsModules/smallworld/trunk/smallworld/message_ajax.php XoopsModules/smallworld/trunk/smallworld/userprofile.php Modified: XoopsModules/smallworld/trunk/smallworld/comment_ajax.php =================================================================== --- XoopsModules/smallworld/trunk/smallworld/comment_ajax.php 2012-05-11 09:46:14 UTC (rev 9481) +++ XoopsModules/smallworld/trunk/smallworld/comment_ajax.php 2012-05-11 10:02:24 UTC (rev 9482) @@ -51,7 +51,7 @@ if($data) { $wc['msg_id_fk'] = $data['msg_id_fk']; $wc['com_id'] = $data['com_id']; - $wc['comment'] = smallworld_tolink(htmlspecialchars_decode($data['comment']), $data['uid']); + $wc['comment'] = nl2br(smallworld_tolink(htmlspecialchars_decode($data['comment']), $data['uid'])); $wc['time'] = smallworld_time_stamp($data['created']); $wc['username'] = $data['username']; $wc['uid'] = $data['uid_fk']; Modified: XoopsModules/smallworld/trunk/smallworld/index.php =================================================================== --- XoopsModules/smallworld/trunk/smallworld/index.php 2012-05-11 09:46:14 UTC (rev 9481) +++ XoopsModules/smallworld/trunk/smallworld/index.php 2012-05-11 10:02:24 UTC (rev 9482) @@ -73,7 +73,7 @@ foreach ($updatesarray as $data) { $wm['msg_id'] = $data['msg_id']; $wm['orimessage'] = str_replace(array("\r", "\n"), '',Smallworld_stripWordsKeepUrl($data['message'])); - $wm['message'] = smallworld_tolink(htmlspecialchars_decode($data['message']), $data['uid_fk']); + $wm['message'] = nl2br(smallworld_tolink(htmlspecialchars_decode($data['message']), $data['uid_fk'])); $wm['message'] = str_replace(array('<','>'),array('<','>'), $wm['message']); $wm['created'] = smallworld_time_stamp($data['created']); $wm['username'] = $data['username']; @@ -99,7 +99,7 @@ foreach($wm['commentsarray'] as $cdata) { $wc['msg_id_fk'] = $cdata['msg_id_fk']; $wc['com_id'] = $cdata['com_id']; - $wc['comment'] = smallworld_tolink(htmlspecialchars_decode($cdata['comment']),$cdata['uid_fk']); + $wc['comment'] = nl2br(smallworld_tolink(htmlspecialchars_decode($cdata['comment']),$cdata['uid_fk'])); $wc['time'] = smallworld_time_stamp($cdata['created']); $wc['username'] = $cdata['username']; $wc['uid'] = $cdata['uid_fk']; Modified: XoopsModules/smallworld/trunk/smallworld/loadmore.php =================================================================== --- XoopsModules/smallworld/trunk/smallworld/loadmore.php 2012-05-11 09:46:14 UTC (rev 9481) +++ XoopsModules/smallworld/trunk/smallworld/loadmore.php 2012-05-11 10:02:24 UTC (rev 9482) @@ -64,7 +64,7 @@ foreach ($updatesarray as $data) { $wm['msg_id'] = $data['msg_id']; $wm['orimessage'] = str_replace(array("\r", "\n"), '',$data['message']); - $wm['message'] = smallworld_tolink(htmlspecialchars_decode($data['message']), $data['uid_fk']); + $wm['message'] = nl2br(smallworld_tolink(htmlspecialchars_decode($data['message']), $data['uid_fk'])); $wm['created'] = smallworld_time_stamp($data['created']); $wm['username'] = $data['username']; $wm['uid_fk'] = $data['uid_fk']; @@ -91,7 +91,7 @@ foreach($wm['commentsarray'] as $cdata) { $wc['msg_id_fk'] = $cdata['msg_id_fk']; $wc['com_id'] = $cdata['com_id']; - $wc['comment'] = smallworld_tolink(htmlspecialchars_decode($cdata['comment']),$cdata['uid_fk']); + $wc['comment'] = nl2br(smallworld_tolink(htmlspecialchars_decode($cdata['comment']),$cdata['uid_fk'])); $wc['time'] = smallworld_time_stamp($cdata['created']); $wc['username'] = $cdata['username']; $wc['uid'] = $cdata['uid_fk']; Modified: XoopsModules/smallworld/trunk/smallworld/message_ajax.php =================================================================== --- XoopsModules/smallworld/trunk/smallworld/message_ajax.php 2012-05-11 09:46:14 UTC (rev 9481) +++ XoopsModules/smallworld/trunk/smallworld/message_ajax.php 2012-05-11 10:02:24 UTC (rev 9482) @@ -57,7 +57,7 @@ foreach ($insdata as $data) { $wm['msg_id'] = $data['msg_id']; $wm['orimessage'] = str_replace(array("\r", "\n"), '',$data['message']); - $wm['message'] = smallworld_tolink(htmlspecialchars_decode($data['message']), $data['uid_fk']); + $wm['message'] = nl2br(smallworld_tolink(htmlspecialchars_decode($data['message']), $data['uid_fk'])); $wm['created'] = smallworld_time_stamp($data['created']); $wm['username'] = $data['username']; $wm['uid_fk'] = $data['uid_fk']; @@ -84,7 +84,7 @@ foreach($wm['commentsarray'] as $cdata) { $wc['msg_id_fk'] = $cdata['msg_id_fk']; $wc['com_id'] = $cdata['com_id']; - $wc['comment'] = smallworld_tolink(htmlspecialchars_decode($cdata['comment']), $cdata['uid_fk']); + $wc['comment'] = nl2br(smallworld_tolink(htmlspecialchars_decode($cdata['comment']), $cdata['uid_fk'])); $wc['time'] = smallworld_time_stamp($cdata['created']); $wc['username'] = $cdata['username']; $wc['uid'] = $cdata['uid_fk']; Modified: XoopsModules/smallworld/trunk/smallworld/userprofile.php =================================================================== --- XoopsModules/smallworld/trunk/smallworld/userprofile.php 2012-05-11 09:46:14 UTC (rev 9481) +++ XoopsModules/smallworld/trunk/smallworld/userprofile.php 2012-05-11 10:02:24 UTC (rev 9482) @@ -112,7 +112,7 @@ foreach ($updatesarray as $data) { $wm['msg_id'] = $data['msg_id']; $wm['orimessage'] = str_replace(array("\r", "\n"), '',$data['message']); - $wm['message'] = smallworld_tolink(htmlspecialchars_decode($data['message']), $data['uid_fk']); + $wm['message'] = nl2br(smallworld_tolink(htmlspecialchars_decode($data['message']), $data['uid_fk'])); $wm['created'] = smallworld_time_stamp($data['created']); $wm['username'] = $data['username']; $wm['uid_fk'] = $data['uid_fk']; @@ -138,7 +138,7 @@ foreach($wm['commentsarray'] as $cdata) { $wc['msg_id_fk'] = $cdata['msg_id_fk']; $wc['com_id'] = $cdata['com_id']; - $wc['comment'] = smallworld_tolink(htmlspecialchars_decode($cdata['comment']), $cdata['uid_fk']); + $wc['comment'] = nl2br(smallworld_tolink(htmlspecialchars_decode($cdata['comment']), $cdata['uid_fk'])); $wc['time'] = smallworld_time_stamp($cdata['created']); $wc['username'] = $cdata['username']; $wc['uid'] = $cdata['uid_fk']; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |