Show
Ignore:
Timestamp:
05/15/06 16:53:07 (3 years ago)
Author:
sdcosta
Message:

0.5.3.9999999999999999999999999999999999999999999999999999999999

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • release-branches/0.5.4/gregarius/author.php

    r1190 r1470  
    2828require_once ('init.php'); 
    2929 
    30 $a =  preg_replace("/[^A-Za-z0-9\.]/","%",rss_real_escape_string($_REQUEST['author'])); 
    31  
     30$a =trim(sanitize($_REQUEST['author'], RSS_SANITIZER_WORDS)); 
    3231list ($ra) = rss_fetch_row(rss_query( 
    3332    "select distinct(author) from " .getTable('item')  
    34     ." where author like '%$a%'" 
     33    ." where author like '$a'" 
    3534)); 
    3635 
    3736if (!$ra) { 
    38     rss_redirect(); 
     37    rss_404(); 
     38    exit; 
    3939} 
    4040 
     
    4343$GLOBALS['rss']->feedList = new FeedList(false); 
    4444$authorItems = new ItemList(); 
    45 $sqlWhere = " i.author like '%$a%' "; 
    46 $authorItems->populate($sqlWhere); 
     45$sqlWhere = " i.author like '$a' "; 
     46$numItems = getConfig('rss.output.frontpage.numitems'); 
     47$authorItems->populate($sqlWhere, "",  0, $numItems); 
    4748$authorItems->setTitle($t); 
    4849$authorItems->setRenderOptions(IL_NO_COLLAPSE|IL_TITLE_NO_ESCAPE);