Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

Click to enlarge image...


Recommended Posts

How can i change it so that instead of showing an image it shows a .swf file. Reason is our site sells .mp3's and this is how i want to have samples for peeps to listen to. I have tried playing with the products_info.php file but its not all there.

Link to comment
Share on other sites

This is just a quick and dirty of where I would start. I haven't done it as it would take up too much time with testing and all.


First I would install dynamic mopics contribution because it allows for different image types. For your example it sounds like you want a small image to display on the product info page and when clicked, opens up to another type of file (shockwave) in a new window. Then I would tweak the sql query executed from the contribution and database to accomodate swf extension.


The current OSC code won't allow for swf files because the tep_image function spits out html for image calls (<img src="...") and not objects. So I would create another function in html_output.php (includes/functions) to accomodate objects -- something like tep_object. Try tweaking the currenct tep_image function in the file with the proper formatting for objects and swfs:

<object width="100" height="100">

<embed src="whatever.swf"></embed>



Then I would modify the popup_image.php file from the mopics contribution to call this new function tep_object instead of tep_image.


It's a little bit of work and someone may have an easier way, but that's what I would do.

Link to comment
Share on other sites


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

  • Create New...