1
szoszon
modules addresses !!! -> block
  • 2005/2/12 12:32

  • szoszon

  • Just popping in

  • Posts: 3

  • Since: 2002/10/21


That greet change and as in order to last time < last > block addresses showed added agencies of estate with (from)category " house adresses and construction " sub-category" agency estate "
function b_addresses_top_show($options) {
    global 
$xoopsDB;
    
$block = array();
    
$myts =& MyTextSanitizer::getInstance();
    
$result $xoopsDB->query("SELECT lid, cid, title, date, hits FROM ".$xoopsDB->prefix("addresses_links")." WHERE status>0 ORDER BY ".$options[0]." DESC",$options[1],0);
    while(
$myrow $xoopsDB->fetchArray($result)){
        
$link = array();
        
$title $myts->makeTboxData4Show($myrow["title"]);
        if ( !
XOOPS_USE_MULTIBYTES ) {
            if (
strlen($myrow['title']) >= $options[2]) {
                
$title $myts->makeTboxData4Show(substr($myrow['title'],0,($options[2] -1)))."...";
            }
        }
        
$link['id'] = $myrow['lid'];
        
$link['cid'] = $myrow['cid'];
        
$link['title'] = $title;
        if(
$options[0] == "date"){
            
$link['date'] = formatTimestamp($myrow['date'],'s');
        }elseif(
$options[0] == "hits"){
            
$link['hits'] = $myrow['hits'];
        }
        
$block['links'][] = $link;
    }
    return 
$block;
}


Login

Who's Online

159 user(s) are online (97 user(s) are browsing Support Forums)


Members: 0


Guests: 159


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits