osCommerce and osCMax shopping cart software forums

Shopping Cart Software

osCommerce with teeth!

 

Would Like to Make the Link Buttons Rollover Images

This is a discussion on Would Like to Make the Link Buttons Rollover Images within the osCMax v2 Customization/Mods forums, part of the osCMax v2.0 Forums category; I Have remade the buttons included with the new version to match my site but I would like them to ...


Go Back   osCommerce and osCMax shopping cart software forums > osCMax v2.0 Forums > osCMax v2 Customization/Mods

Register FAQ Members List Calendar Mark Forums Read


Free community membership! Fast easy FREE membership
Closed Thread

 

LinkBack Thread Tools
  #1  
Old 07-24-2005, 09:11 PM
New Member
 
Join Date: Mar 2005
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
prs444
Default Would Like to Make the Link Buttons Rollover Images

I Have remade the buttons included with the new version to match my site but I would like them to be rollover images. I can create the second set of images for the rollover buttons but I don't know the code or where to put it to get the rollovers to work. Is there an easy way to find where all the buttons are referenced to change the code?
I would have no problem posting all the buttons for the rollovers as a contribution so anyone can use them if I can get them to work.
Any help would be great!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #2  
Old 07-25-2005, 05:20 AM
jpf's Avatar
jpf jpf is offline
Moderator

 
Join Date: Sep 2003
Posts: 1,521
Thanks: 1
Thanked 81 Times in 68 Posts
Rep Power: 10
jpf is just really nicejpf is just really nicejpf is just really nicejpf is just really nicejpf is just really nice
Default RE: Would Like to Make the Link Buttons Rollover Images

Easy Rollovers
http://www.oscommerce.com/community/contributions,2054

Which sounds like it might be easy to add into oscMax. But I have not tried.

Good Luck
__________________
JPF - osCMax Fourm Moderator
Try out our osCMax at: Live Catalog Demo
Limited access Admin: Live Admin Demo
Feel free to add products they way you want and then purchase them -=+=- Sorry nothing will be billed or shipped!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #3  
Old 07-25-2005, 09:48 PM
New Member
 
Join Date: Mar 2005
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
prs444
Default Can't get Easy Rollovers contrib to work

I tried to follow the instructions with the Easy Rollover contribution but I cant seem to get it going.
Maybe someone can help walk me through.
I tried following the instructions exactly as printed.

Step 1: Place the included javascript file (rollovers.js) into your site wherever you'd you like.
I installed it in the catalog folder.

Step 2: Then add the link to the javascript in each page on your site. For those running any contributions that give your site some templating abilities this will be pretty quick but those who aren't you need to go in every page on your site to add this link. Please add the link inside the <head></head> area, an example is below:
Before:
</head>
Add
<script type="text/javascript" language="javascript" src="rollovers.js"></script>
</head>

I added the above link as written above into my mainpage.tpl.php file since I though that page controlled the template.

QUESTION- If the javascript file is in the catalog folder do I need to change the src="rollovers.js"> part of the link to src="catalog/rollovers.js">
Or better yet, can I put the javascript file (rollovers.js) into the catalog/includes/javascript folder with the rest of the javascript files.
If I do that, how does that change the link?

ALSO: Where should I add the link? I tried it on the mainpage.tpl.php file and it didn't work. The contribution talks about adding the link to each page but I'm not sure how the template system pulls up the pages so I'm kinda lost where to add the link.

Step 3: Modify html_output.php located in includes/functions/ so that each image button and image form submit will have class="rollover"

I did a file compare between the html_output.php included with the contribution and the on in the osMax RC1 and replaced line271:

$image_submit = '<input type="image" src="' . tep_output_string(DIR_WS_LANGUAGES . $language . '/images/buttons/' . $image) . '" border="0" alt="' . tep_output_string($alt) . '"';

with:

$image_submit = '<input type="image" class="rollover" src="' . tep_output_string(DIR_WS_LANGUAGES . $language . '/images/buttons/' . $image) . '" border="0" alt="' . tep_output_string($alt) . '"';

Then I added:

if (tep_not_null($parameters)) {
$parameters .= ' class="rollover"';
} else {
$parameters .= 'class="rollover"';
}
on line 286

I then added a rollover image to my sign in button to test if it worked and it did not.
The site is up at:
http://www.fukkenwax.com/catalog

If anyone needs more info to help just post what you need to know and I'll do my best.
Thanks from a total newbie!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #4  
Old 07-25-2005, 11:42 PM
New Member
 
Join Date: Mar 2005
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
prs444
Default UPDATE: Can't get Easy Rollovers contrib to work

OK now we are getting somewhere! I added the javascript link:

<script type="text/javascript" language="javascript" src="rollovers.js"></script>

into the catalog/templates/aabox/popup.tpl.php file and now the rollover buttons have started to work.
BUT.... there is a glitch, sometimes the rollovers work and sometimes they don't. Just reloading the page will sometimes get the ones that don't work to all of the sudden work.
And here is what bugs me... if there are several buttons on a page some might rollover and some might not. I can't use the rollover contribution if I can't get it to work correctly. I'll keep plugging away.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #5  
Old 10-21-2005, 12:19 PM
Lurker
 
Join Date: Oct 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
young77478
Default RE: UPDATE: Can

Hi - I just started to implement the same thing for a project. Did you ever fully solve this issue? Can you give me some guidelines?
Thanks
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Closed Thread



Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
how do i set a link active, if the link links to actual page poschiman osCommerce 2.2 Modification Help 0 06-03-2006 04:10 PM
Rollover thumbnail goes big adamr415 osCMax v2 Customization/Mods 0 11-29-2005 04:53 PM
Make us your homepage link - Does anyone know how to make? markymrk22 osCommerce 2.2 Modification Help 1 06-05-2005 08:49 AM
How to make a link available after purchase for audio tam283 osCommerce 2.2 Modification Help 10 02-15-2005 12:40 PM
Link to larger images Anonymous osCommerce 2.2 Installation Help 1 11-24-2002 09:58 PM


All times are GMT -8. The time now is 01:53 PM.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO
Copyright 2008 osCMax