Notifications
Clear all

viewpage.php "bug" with ?id=

2 Posts
2 Users
0 Reactions
2,863 Views
 Elle
(@jenny)
Posts: 594
Honorable Member
Topic starter
 

I know it's somewhat rare for an archive to use ?id=, but there's still an error with it:

$page = dbquery("SELECT message_title, message_text FROM ".TABLEPREFIX."fanfiction_messages WHERE ".($current ? "message_name = '".escapestring($current)."'" : "message_id = '".(isNumber($_GET['id']) ? $_GET[id] : "0"))." LIMIT 1");

It should be:

$page = dbquery("SELECT message_title, message_text FROM ".TABLEPREFIX."fanfiction_messages WHERE ".($current ? "message_name = '".escapestring($current)."'" : "message_id = '".(isNumber($_GET['id']) ? $_GET['id'] : "0")."'")." LIMIT 1");

(Missing quote for the ID.)


archive: dramione.org
site: accio.nu

Available for skin/mod commission! πŸ™‚

 
Posted : 15/02/2010 8:53 pm
(@tammy)
Posts: 2577
Member Moderator
 

Thanks for the catch.  Updated file is in the SVN.


 
Posted : 15/02/2010 10:39 pm
Share: