Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

change text links in to images


Njuwdaij

Recommended Posts

Actually it looks like they added styles to the table cells, it isn't actually images. You can do that in the CSS file, and then you would have to edit the code in the catalog/includes/boxes/catagories.php

 

Not something I would suggest you do unless you know what you are doing or are willing to make mistakes before you get it right. Back up your files! =)

Wendy James

 

Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.

Link to comment
Share on other sites

You can do that in the CSS file, and then you would have to edit the code in the catalog/includes/boxes/catagories.php

 

Thank's Wendy!

 

I have some knowledge of css files and .php, but is there somebody out there that can point me in the right direction about the coding of something like this?

:'(

Link to comment
Share on other sites

I took this from a website...

 

Here is the CSS class that you should add to your "external" style sheet that controls the "onload" table cell color, border width and color. You can name this custom class anything you like provided you assign the td HTML tag with the correct class name. We have named our custom CSS class "btnav".

 

.btnav { background-color: #84C1DF; border: 1px #000000 solid;}

 

Below is what the HTML source code looks like for one table cell. This would apply to all table cells within your table. We have added onmouseover/onmouseout tricks to the td tag. We also assigned our external CSS class to the td tag. Don't forget that step. We have specified the onmouseover color in hex code, and we specified the same color in hex code as the background-color in the "btnav" class we created in the "external" stylesheet for the onmouseout function.

 

<td class="btnav" onmouseover="style.backgroundColor='#84DFC1';"

onmouseout="style.backgroundColor='#84C1DF'">

<div align="center"><a href="http://www.somesite.com/" target="_blank">Some Site</a></div>

</td>

 

 

Ofcourse you will have to change the part that goes on the page but you should be able to figure it out. I am sure you can find more information if you do a search on

Table Cell Background Colors Change on Mouseover with CSS

or something like that =) Good luck.

Wendy James

 

Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.

Link to comment
Share on other sites

Below is what the HTML source code looks like for one table cell. This would apply to all table cells within your table. We have added onmouseover/onmouseout tricks to the td tag.

We also assigned our external CSS class to the td tag. Don't forget that step.

English is not my first language, and sometimes I really have to read something several times to understand it.

Could you please tell me in which files I have to change the td-tags? You've mentioned catalog/includes/boxes/catagories.php, but I can't find td-tags in that file.

How should this complete file look like after updating it with my mouseover color?

We have specified the onmouseover color in hex code, and we specified the same color in hex code as the background-color in the "btnav" class we created in the "external" stylesheet for the onmouseout function.

<td class="btnav" onmouseover="style.backgroundColor='#84DFC1';"

onmouseout="style.backgroundColor='#84C1DF'">

<div align="center"><a href="http://www.somesite.com/" target="_blank">Some Site</a></div>

</td>

You do not put the mouseover and -out background colors in the stylesheet, but directly in the earlier mentioned td-tags?

Ofcourse you will have to change the part that goes on the page but you should be able to figure it out.

What do you mean? Categories? Through the Admin?

I am sure you can find more information if you do a search on

Table Cell Background Colors Change on Mouseover with CSS

or something like that =) Good luck.

Sorry, no. Can't find anything good!

Link to comment
Share on other sites

Ok, I went over all the code and getting the code I said above to work is truly a pain but there are DHTML menu contributions that will do the same kind of look with just some tweeking of 1 file.

 

I have used this one http://www.oscommerce.com/community/contri...arch,DHTML+Menu

on 2 sites and it works well.

 

Once it is installed go to the admin panel and set to the DHTML choice (explains that in the contribution). Then edit the categories_dhtml.php file that came with the contribution. Everything on that page has notes next to it so you can figure out what to change.

 

Someone else may have a better idea but that is the easiest option I could find.

Wendy James

 

Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...