[geeklog-cvs] geeklog: Dont display sort by author when searching by author (f...

geeklog-cvs at lists.geeklog.net geeklog-cvs at lists.geeklog.net
Thu Nov 5 16:36:39 EST 2009


changeset 7442:5f5387780b30
url:  http://project.geeklog.net/cgi-bin/hgwebdir.cgi/geeklog/rev/5f5387780b30
user: Sami Barakat <sami at sbarakat.co.uk>
date: Thu Nov 05 21:35:39 2009 +0000
description:
Dont display sort by author when searching by author (feature request #0000910)

diffstat:

 system/classes/listfactory.class.php |  2 +-
 system/classes/search.class.php      |  3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diffs (30 lines):

diff -r 142904168971 -r 5f5387780b30 system/classes/listfactory.class.php
--- a/system/classes/listfactory.class.php	Thu Nov 05 21:33:05 2009 +0000
+++ b/system/classes/listfactory.class.php	Thu Nov 05 21:35:39 2009 +0000
@@ -665,7 +665,7 @@
                 $text = $sort_text . $field['title'];
                 $href = '';
                 $selected = '';
-                
+
                 if ($this->_style == 'inline' && $show_sort && $field['sort'] != false)
                 {
                     $direction = $this->_def_sort_arr['direction'];
diff -r 142904168971 -r 5f5387780b30 system/classes/search.class.php
--- a/system/classes/search.class.php	Thu Nov 05 21:33:05 2009 +0000
+++ b/system/classes/search.class.php	Thu Nov 05 21:35:39 2009 +0000
@@ -481,12 +481,13 @@
         }
         else if ($style == 'google')
         {
+            $sort_uid = $this->_author == '' ? true : false;
             $obj->setStyle('inline');
             $obj->setField('',          LF_ROW_NUMBER,  $show_num,  false, '<b>%d.</b>');
             $obj->setField($LANG09[16], 'title',        true,       true,  '%s<br' . XHTML . '>');
             $obj->setField('',          'description',  true,       false, '%s<br' . XHTML . '>');
             $obj->setField('',          '_html',        true,       false, '<span style="color:green;">');
-            $obj->setField($LANG09[18], 'uid',          $show_user, true,  $LANG01[104].' %s ');
+            $obj->setField($LANG09[18], 'uid',          $show_user, $sort_uid,  $LANG01[104].' %s ');
             $obj->setField($LANG09[17], 'date',         true,       true,  $LANG01[36].' %s');
             $obj->setField($LANG09[5],  LF_SOURCE_TITLE,$show_type, true,  ' - %s');
             $obj->setField($LANG09[50], 'hits',         $show_hits, true,  ' - %s '.$LANG09[50]);



More information about the geeklog-cvs mailing list