Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

can i change the header.php for every catagie


zencrom

Recommended Posts

hi

 

i have lots of shops at the moment with diffrent header

web site 1

website 2

web site 3

web site 4

 

the only thing that changes is the header

the header is made up of 4 pictures

the 1 on the end whcih the picture changes for the type of products

two in the middle stay the same for all four

and the end one is also a picture whcih changes the text at the bottom for each site

 

is there anyway i can put all of these under one shop and just have the catagories on the side and when the customer clickes on that catagie the header changes so it looks tha same as having 4 shops

 

 

cheers

Link to comment
Share on other sites

In includes/header.php put in code to switch the header depending upon which site is showing. You can check the url to determine that.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

In includes/header.php put in code to switch the header depending upon which site is showing. You can check the url to determine that.

 

Jack

 

i want to do is really change the header for each category

Link to comment
Share on other sites

You can use the same approach. It will just take more coding. Each time you switch pages (like going to a new category), the page is reloaded. So you just tell it what to load based on what item was clicked on.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

You would need to do it yourself unless someone as the time to do it for you. To get it started, it would be something like the following (not real code)

	  if ($category_parent['total'] > 0) {
if ($current_category_id == 1)
$hdrimage = 'some image';
else
$hdrimage = "some other image';
}

<td> display image here - $hdrimage</td>

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

  • 4 months later...

im not so good in coding and stuff , can you write us the real code? and where to put it ?

 

cuz i want to have diffrent header pictrue for each catagie, and this topic is the closet i come to..

 

regards

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...