Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

hiklot

Archived
  • Posts

    10
  • Joined

  • Last visited

About hiklot

  • Birthday 07/04/1980

Profile Information

hiklot's Achievements

  1. I've been searching for a way to include tagging for products for some time. I am building a record shop and something like the tagging system on last.fm would be extremely usefull! If somebody has started to implement anything like that please let me know!
  2. Hey, thank you for this simple but very effective contribution! I modified it a little to suit my needs, because 1. I wanted to put a blank image on top of the product image to disable users from copying the file 2. I wanted to put alternative content for users with javascript disabled like in the original product_info.php, because now, if a user has disabled javascript, the product image will be shown twice. Just to share what I did and find possible errors in my code, here are the changes I made: 1. in enlarge.js I replaced: crossobj.innerHTML='<div align="right" id="dragbar"><span id="closetext" onClick="closepreview()">Close Window [x] </span> </div><img src="'+which+'" onClick="closepreview();">' with: crossobj.innerHTML='<div align="right" id="dragbar"><span id="closetext" onClick="closepreview()">[x] </span> </div><div style="background-image:url('+which+')"><img src="images/pixel_blank.gif" width="'+imgwidth+'" height="'+imgheight+'" onClick="closepreview();"></div>' 2. in product_info.php (Step 6 in the Help file) -Instead of the suggested replacement- I replaced: <script language="javascript"><!-- document.write('<?php echo '<a href="java script:popupWindow(\\\'' . tep_href_link(FILENAME_POPUP_IMAGE, 'pID=' . $product_info['products_id']) . '\\\')">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT , 'hspace="5" vspace="5"') . '</a>'; ?>'); //--></script> with: <script language="javascript"><!-- document.write('<?php if (is_file(DIR_WS_IMAGES . $product_info['products_image'])) { list($w, $h) = getimagesize(DIR_WS_IMAGES . $product_info['products_image']); echo '<a href="#" onclick="return enlarge(\\\'' . DIR_WS_IMAGES . $product_info['products_image'] . '\\\',event,\\\'center\\\',' . $w . ',' . $h . ');return false;">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], $product_info['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '</a><br>'; } else { echo tep_image(DIR_WS_PRODUCT_IMAGES . $product_info['products_image'], $product_info['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"'); } ?>'); //--></script> Thanks again for this contribution, Patrick
  3. If you're using the above method, please remove "$$list = array(); " Sorry for posting faulty code.
  4. Just a quick solution for everybody who wants to sort their Songs by title, somehow my playlist always got mixed up and sorted the files in some strange fashion... in both catalog/player_parser.php and admin/player_parser.php REPLACE foreach ($ExpExt as $findExt) { $getFile = @tep_browse_mp3($gDirectory, $findExt); $countFile = count($getFile); if ($countFile != 0) { foreach ($getFile as $myFile) { $list[] = $myFile; } } } WITH foreach ($ExpExt as $findExt) { $getFile = @tep_browse_mp3($gDirectory, $findExt); $countFile = count($getFile); if ($countFile != 0) { foreach ($getFile as $myFile) { $list[] = $myFile; } } } $$list = array(); sort($list); hope that helped.
  5. I had the same problem, thanx for the simple solution! Everything works fine now.
×
×
  • Create New...