Jump to content
Sign in to follow this  
jasonabc

Rollover navigation (category) images

Recommended Posts

Hi there,

 

I've just finished a store where I was able to replace the HTML text links in the category box with really nice rollover Javascript images. If you expend the category (to reveal subcategories) the Category box also dynamically displays the "over" state of the image.

 

I haven't found a contribution that does this (Easy Rollover does ordinary buttons but not the main navigation). Before I submit as an OSC contribution, would anyone find this useful, and more importantly - has it already been done? I don't want to submit a duplicate contribution.

 

cheers

 

Jason

Edited by jasonabc

Share this post


Link to post
Share on other sites
Hi there,

 

I've just finished a store where I was able to replace the HTML text links in the category box with really nice rollover Javascript images. If you expend the category (to reveal subcategories) the Category box also dynamically displays the "over" state of the image.

 

I haven't found a contribution that does this (Easy Rollover does ordinary buttons but not the main navigation). Before I submit as an OSC contribution, would anyone find this useful, and more importantly - has it already been done? I don't want to submit a duplicate contribution.

 

cheers

 

Jason

 

Do you have an example that I can view?

Share this post


Link to post
Share on other sites

Hii!! I Am using this contribution, very good. BUT, i have just one problem...i am using more than one language for the site. You have the images linked to a folder in catalog. If i change the language of catalog, the images will remain the old language...

How can I fix this?

 

Thank you

 

Bruno :thumbsup: :thumbsup:

Share this post


Link to post
Share on other sites

Great contribution. I just have a question - I want to get rid of the subcategory text - is there an easy way to do that?

 

Also, I have some static images that need to be part of the navigation, such as an About Us item, as well as a Contact Us item. Is there an easy way using your contribution to add these static images to the navigation, and have them rollover and display the over state if they're clicked on?

 

I appreciate any help. This is one of the last things I need to do to complete the site I'm working on.

Share this post


Link to post
Share on other sites

Here's what I've commented out so far - this code taken from your categories.php page - for some reason I'm still seeing some sort of a break after the first category image that has a subcategory. Is there an easy way to get rid of that break?

 

# if a subcategory, just write out the name in HTML text:
//else if (isset($cPath_array) && in_array($counter, $cPath_array))	 {
	# if subcategory is the one selected, wrap <b> tags round it:
	//$categories_string .= '<b>';
	//$categories_string .= $tree[$counter]['name'];
	//$categories_string .= '</b>';
//}
# else just write out the name with no bold tags:
//else {
//	$categories_string .= $tree[$counter]['name'];
//}

# if a subcategory, close the subNav span tag:
for ($i=0; $i<$tree[$counter]['level']; $i++) {
  $categories_string .= "</span>";
}

$categories_string .= '</a><br>';

if ($tree[$counter]['next_id'] != false) {
  tep_show_category($tree[$counter]['next_id']);
}
 }
?>

 

Great contribution. I just have a question - I want to get rid of the subcategory text - is there an easy way to do that?

 

Also, I have some static images that need to be part of the navigation, such as an About Us item, as well as a Contact Us item. Is there an easy way using your contribution to add these static images to the navigation, and have them rollover and display the over state if they're clicked on?

 

I appreciate any help. This is one of the last things I need to do to complete the site I'm working on.

Edited by jpipitone43

Share this post


Link to post
Share on other sites

I didn't see your post until today but I think I commented out the same lines to get rid of the plain text subcategory links (I only wanted the Top categories to display horizontally):

 

 # if a subcategory, just write out the name in HTML text:
// Comment lines below to remove subcategory listings from Top Category Menu
/* else if (isset($cPath_array) && in_array($counter, $cPath_array))  {
 # if subcategory is the one selected, wrap <b> tags round it:
//  $categories_string .= '<b>';
 $categories_string .= $tree[$counter]['name'];
// Rollover Image EOF
 $categories_string .= '</b>';
}
// Rollover Image BOF
# else just write out the name with no bold tags:
else {
 $categories_string .= $tree[$counter]['name'];
}*/
// Comment lines above to remove subcategory listings from Top Category Menu

# if a subcategory, close the subNav span tag:
for ($i=0; $i<$tree[$counter]['level']; $i++) {
  $categories_string .= "</span>";


Bill Kellum

 

Sounds Good Productions

STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×