Jump to content

Rotating a div image based on page url


jvan1768

Recommended Posts

I am trying to figure out how to rotate an image in a div based on the current url the user is at. I am using this in Zen-cart and want to rotate the header image, but the php for the header section is the same for every page. I want to be able to display a different header image for each of the different shopping categories.  Any ideas? Let me know if you need me to clarify the problem.

Link to comment
https://forums.phpfreaks.com/topic/94311-rotating-a-div-image-based-on-page-url/
Share on other sites

I'm sorry what is the gd library? I am not too familiar with php. Also to clarify, I want the php to select the appropriate image based on the current URL. The header php doesn't change throughout the site but I want the image that is there to change based on the URL

 

thanks

This for an online store using Zen-cart. The url is going to be the location of a certain product.

 

Example: index.php?main_page=index&cPath=65_48 --> is the specific url of the product category

 

Now according to the specific product url, I want to be able to rotate the image that is displayed in the header whose php is the same across the entire site.

 

The images will be house in a central image folder and would be called into the header based on the current url.

 

Does this make more sense

Archived

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

×
×
  • 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.