tammy507 Posted March 7, 2004 Share Posted March 7, 2004 Anyone have any idea how to get ride of the "+" sign at the end of Product Name+ ? I know its trivial, but it bugs me. Thanks Tammy Link to comment Share on other sites More sharing options...
♥yesudo Posted March 7, 2004 Share Posted March 7, 2004 I like the function that allows the columns to be sorted but agree that it could be done a better way rather than having the +. Your online success is Paramount. Link to comment Share on other sites More sharing options...
♥kymation Posted March 9, 2004 Share Posted March 9, 2004 The + and - signs are in includes/functions/general.php. Look for the tep_create_sort_heading function (at Line 896 in an unmodified copy.) The code looks like this: function tep_create_sort_heading($sortby, $colnum, $heading) { global $PHP_SELF; $sort_prefix = ''; $sort_suffix = ''; if ($sortby) { $sort_prefix = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('page', 'info', 'sort')) . 'page=1&sort=' . $colnum . ($sortby == $colnum . 'a' ? 'd' : 'a')) . '" title="' . tep_output_string(TEXT_SORT_PRODUCTS . ($sortby == $colnum . 'd' || substr($sortby, 0, 1) != $colnum ? TEXT_ASCENDINGLY : TEXT_DESCENDINGLY) . TEXT_BY . $heading) . '" class="productListing-heading">'; $sort_suffix = (substr($sortby, 0, 1) == $colnum ? (substr($sortby, 1, 1) == 'a' ? '+' : '-') : '') . '</a>'; } return $sort_prefix . $heading . $sort_suffix; } Change this line: $sort_suffix = (substr($sortby, 0, 1) == $colnum ? (substr($sortby, 1, 1) == 'a' ? '+' : '-') : '') . '</a>'; to this: $sort_suffix = (substr($sortby, 0, 1) == $colnum ? (substr($sortby, 1, 1) == 'a' ? '' : '') : '') . '</a>'; and no more + or -. A better solution is to replace the + and - with images. I used a couple of small triangles: one pointed up and one pointed down. They are then called by replacing that line with: $sort_suffix = (substr($sortby, 0, 1) == $colnum ? (substr($sortby, 1, 1) == 'a' ? tep_image(DIR_WS_IMAGES . "triangle_down.gif", "ascending") : tep_image(DIR_WS_IMAGES . "triangle_up.gif", "descending") ) : ''); You can have a copy of the images if you want. They are white because my text is white on a dark background, so they may not work for you. Of course you can make your own images in whatever shape that you want. Regards Jim See my profile for a list of my addons and ways to get support. Link to comment Share on other sites More sharing options...
tammy507 Posted March 9, 2004 Author Share Posted March 9, 2004 Thank you!!!!! Your kindness is very much appreciated! Tammy Link to comment Share on other sites More sharing options...
Almirena Posted April 17, 2004 Share Posted April 17, 2004 That's another useful bit of knowledge. I, too, found the + out of place in that heading. Thanks. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.