Dotclear

Changeset 1155:49ba58cbf593 for inc/core


Ignore:
Timestamp:
04/09/13 09:15:41 (12 years ago)
Author:
Dsls <dsls@…>
Branch:
twig
Parents:
1154:e85c1417b8a4 (diff), 1143:fbf575ae9bda (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge with default

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • inc/core/class.dc.blog.php

    r1111 r1155  
    805805           
    806806          if (!empty($params['user_id'])) { 
    807                $strReq .= "AND U.user_id = '".$this->con->escape($params['user_id'])."' "; 
     807               $strReq .= "AND U.user_id ".$this->con->in($params['user_id'])." "; 
    808808          } 
    809809           
     
    889889                    $strReq .= 'ORDER BY post_dt DESC '; 
    890890               } 
    891           } 
    892            
    893           if (!$count_only && !empty($params['limit'])) { 
    894                $strReq .= $this->con->limit($params['limit']); 
     891               if (!empty($params['limit'])) { 
     892                    $strReq .= $this->con->limit($params['limit']); 
     893               } 
    895894          } 
    896895           
  • inc/core/class.dc.blog.php

    r1154 r1155  
    228228               'SELECT post_id, COUNT(post_id) AS nb_comment,comment_trackback '. 
    229229               'FROM '.$this->prefix.'comment '. 
    230                'WHERE post_id'.$this->con->in($a_ids). 
    231                'AND comment_status = 1 '; 
     230               'WHERE comment_status = 1 '. 
     231               (count($a_ids) > 0 ? 'AND post_id'.$this->con->in($a_ids) : ' '); 
    232232           
    233233          if ($del) { 
Note: See TracChangeset for help on using the changeset viewer.

Sites map