Jump to content

Shopping Cart In PHP


chey

Recommended Posts

right now my sub categories display the following, which is the name of the category(in blue).

this is the code

[code]/**
    * CATEGORY DESCRIPTION
    */
  $desc =  $ps_product_category->get_description($category_id);
  /* Prepend Product Short Description Meta Tag "description" when applicable */
  if( @$_REQUEST['output'] != "pdf") {
      $mainframe->prependMetaTag( "description", substr(strip_tags($desc ), 0, 255) );
  }
  if( trim(str_replace( "<br />", "" , $desc)) != "" ) {

      echo $desc;
      echo '<br /><br />';
        }

if (!empty($category_id) ) {

        /**
    * PATHWAY - Navigation List
    */
echo '<div style="text-align:left;">';
$nav_list = $ps_product_category->get_navigation_list($category_id);

if( @$_REQUEST['output'] != "pdf") {
$mainframe->appendPathWay( $nav_list );
}
else {
echo "<strong>".$nav_list ."</strong><br />";
}
$child_list = $ps_product_category->get_child_list($category_id);
if (!empty( $child_list )) {
echo $child_list;
echo 'hello';
}
echo '</div>';
if (!empty( $child_list )) {
echo '<br style="clear:both;" /><br />';
}


}[/code]

so now, i want to add the category descriptions underneath it. i believe the variable name for it is 'category_descriptions'

[attachment deleted by admin]
Link to comment
Share on other sites

hmmm, currently i know where to solve the sub category descriptions, but i'm not good with php, so i need help.

$child_list actually displays the categories. BUT, it displays it at the side as well. in shop.browse.php + ps_product_category.php, $child_list is used to generate the display. in order for it to display the descriptions under the one in the sub category page, i'll have to change the child_list function right? is there anyway way to modify the code for it?

in shop.browse.php:

[code]$child_list = $ps_product_category->get_child_list($category_id);
$desc =  $ps_product_category->get_description($category_id);
if (!empty( $child_list )) {
    echo $child_list;

}
echo '</div>';
if (!empty( $child_list )) {
echo '<br style="clear:both;" /><br />';
}[/code]
this would display it on the main page.(shown below in blue)

in ps_product_category.php

[code]function print_child_list($category_id) {
echo $this->get_child_list($category_id);
}[/code]

prints it on the module side.

so... how can i enable both functions to print differently?
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.