Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

One Category point to a different page


Brownangel

Recommended Posts

Posted

Hi,

 

How do I get one Category only to a different page other than index.php. All other Categories will still point to index except that particular one. I tried to use the contribution at http://www.oscommerce.com/forums/index.php?showtopic=296984 but for some reason it is not working for me. I get a box around my category image, the category name disappears and the link seems to be pointing to (catalog/href=). Please help me fix this problem.

Posted

Your code needs a little modification.

 

What's the name of the page (file) you want to link to?

:unsure:

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Posted
Your code needs a little modification.

 

What's the name of the page (file) you want to link to?

:unsure:

 

('FILENAME_HATS', 'hats.php');

 

Thanks

Posted

Then, if the person who started that thread is "worth their salt" in programming, the code should look like this:

 

   if ($tree[$counter]['path'] == 36) {
 $categories_string .= tep_href_link(FILENAME_HATS) . '">';
  } else {
 $categories_string .= tep_href_link(FILENAME_COLLECTION, $cPath_new) . '">';
  }

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Posted
Then, if the person who started that thread is "worth their salt" in programming, the code should look like this:

 

   if ($tree[$counter]['path'] == 36) {
 $categories_string .= tep_href_link(FILENAME_HATS) . '">';
  } else {
 $categories_string .= tep_href_link(FILENAME_COLLECTION, $cPath_new) . '">';
  }

 

It is pointing to hats.php now but not to the cpath. The page doesn't have the Hats category products. In my webrowser I do not see the cpath...

Posted

Maybe this line:

 

$categories_string .= tep_href_link(FILENAME_HATS) . '">';

Needs to be:

 

$categories_string .= tep_href_link(FILENAME_HATS, $cPath_new) . '">';

Some days I'm not as "salty" as I should be either.

:blush:

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Posted
Maybe this line:

 

$categories_string .= tep_href_link(FILENAME_HATS) . '">';

Needs to be:

 

$categories_string .= tep_href_link(FILENAME_HATS, $cPath_new) . '">';

Some days I'm not as "salty" as I should be either.

:blush:

 

It's working yea!!! Make it a GREAT DAY!

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...