Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Product popup image text 2.3.1


ErikMM

Recommended Posts

Posted

Adding this code in the "HTML Content(for popup)" box adds the "title" text below the popup, which is what I want BUT

<img src="images/xxxxxxx_400_color.png" title="MY TEXT HERE">

 

BUT...the image is duplicated, it shows up twice in the thumbs, and when mousing over the duplicate thumb the third thumb (or second "Large Image") appears in the main display block.

 

 

popupquestioncopy.jpg

 

 

so the question is:

 

 

popuphtmlquestion.png

 

Not only text, but to stop an extra thumb from showing up?

Web Developer, Firebug, and Notepad++ are powerful free tools for web design.

Posted

I've literally just run into a similar issue myself.

 

What I did was upload the image as normal and I included an HTML image src reference. This produced more images than required. I then removed the HTML and as a result, everything appears to be fine.

 

Best of luck.

Posted

I've literally just run into a similar issue myself.

 

What I did was upload the image as normal and I included an HTML image src reference. This produced more images than required. I then removed the HTML and as a result, everything appears to be fine.

 

Best of luck.

What code did you put in the HTML content (for popups) box to get text below the "Large Image" upload?

 

a. If only text is entered no image shows.

b. If an image and text are entered it works, but the issue detailed above will occur (1. two duplicate thumb images, 2. mouseover on the the second duplicate thumb causes a false image load in the display block (shown above))

 

I am looking for a solution with no duplicate thumb, and text for that image if someone clicks the main display block. The text doesn't have to appear in the display block on thumb mouseover, only when the display block is clicked, and the image popup window appears.

Web Developer, Firebug, and Notepad++ are powerful free tools for web design.

  • 1 month later...
Posted

this is one of the fixes I want for x-mas...anyone?

santa_smiley.gif

 

 

solved by this comrade: http://www.oscommerce.com/forums/topic/370034-fancybox-problem-on-product-infophp/page__gopid__1562036#entry1562036

Web Developer, Firebug, and Notepad++ are powerful free tools for web design.

  • 2 months later...
Posted

I don't know if anyone has answered this, but I just found a way to fix the problem.

 

In catalog/product_info.php

 

find this:

 

<?php

$pi_counter = 0;

while ($pi = tep_db_fetch_array($pi_query)) {

$pi_counter++;

 

$pi_entry = ' <li><a href="';

 

if (tep_not_null($pi['htmlcontent'])) {

$pi_entry .= '#piGalimg_' . $pi_counter;

} else {

$pi_entry .= tep_href_link(DIR_WS_IMAGES . $pi['image']);

}

 

$pi_entry .= '" target="_blank" rel="fancybox">' . tep_image(DIR_WS_IMAGES . $pi['image']) . '</a>';

 

if (tep_not_null($pi['htmlcontent'])) {

$pi_entry .= '<div style="display: none;"><div id="piGalimg_' . $pi_counter . '">' . $pi['htmlcontent'] . '</div></div>';

}

 

$pi_entry .= '</li>';

 

echo $pi_entry;

}

?>

 

and replace it with this:

 

<?php

$pi_counter = 0;

while ($pi = tep_db_fetch_array($pi_query)) {

$pi_counter++;

 

$pi_entry = ' <li><a href="';

 

$pi_entry .= tep_href_link(DIR_WS_IMAGES . $pi['image']);

 

if (tep_not_null($pi['htmlcontent'])) {

$pi_entry .= '" target="_blank" rel="fancybox"' . $pi['htmlcontent'] . '>' . tep_image(DIR_WS_IMAGES . $pi['image']) . '</a>';

} else {

$pi_entry .= '" target="_blank" rel="fancybox">' . tep_image(DIR_WS_IMAGES . $pi['image']) . '</a>';

}

 

$pi_entry .= '</li>';

 

echo $pi_entry;

}

?>

 

When adding HTML Content for your popup, the content will be inserted into the <a href...> string. If you type title="My Pictures Title" into the HTML Content box, My Pictures Title is the title text that will show up under your popup.

 

Hope that helps.

Posted

I don't know if anyone has answered this, but I just found a way to fix the problem.

 

In catalog/product_info.php

 

find this:

 

<?php

$pi_counter = 0;

while ($pi = tep_db_fetch_array($pi_query)) {

$pi_counter++;

 

$pi_entry = ' <li><a href="';

 

if (tep_not_null($pi['htmlcontent'])) {

$pi_entry .= '#piGalimg_' . $pi_counter;

} else {

$pi_entry .= tep_href_link(DIR_WS_IMAGES . $pi['image']);

}

 

$pi_entry .= '" target="_blank" rel="fancybox">' . tep_image(DIR_WS_IMAGES . $pi['image']) . '</a>';

 

if (tep_not_null($pi['htmlcontent'])) {

$pi_entry .= '<div style="display: none;"><div id="piGalimg_' . $pi_counter . '">' . $pi['htmlcontent'] . '</div></div>';

}

 

$pi_entry .= '</li>';

 

echo $pi_entry;

}

?>

 

and replace it with this:

 

<?php

$pi_counter = 0;

while ($pi = tep_db_fetch_array($pi_query)) {

$pi_counter++;

 

$pi_entry = ' <li><a href="';

 

$pi_entry .= tep_href_link(DIR_WS_IMAGES . $pi['image']);

 

if (tep_not_null($pi['htmlcontent'])) {

$pi_entry .= '" target="_blank" rel="fancybox"' . $pi['htmlcontent'] . '>' . tep_image(DIR_WS_IMAGES . $pi['image']) . '</a>';

} else {

$pi_entry .= '" target="_blank" rel="fancybox">' . tep_image(DIR_WS_IMAGES . $pi['image']) . '</a>';

}

 

$pi_entry .= '</li>';

 

echo $pi_entry;

}

?>

 

When adding HTML Content for your popup, the content will be inserted into the <a href...> string. If you type title="My Pictures Title" into the HTML Content box, My Pictures Title is the title text that will show up under your popup.

 

Hope that helps.

 

It was actually fixed in the link/post right above yours, but thanks nonetheless.

 

Next goal is the magic box that zooms in as you scroll over the image: http://www.magictoolbox.com/magiczoom/

Web Developer, Firebug, and Notepad++ are powerful free tools for web design.

  • 1 year later...
Posted

What code did you put in the HTML content (for popups) box to get text below the "Large Image" upload?

 

a. If only text is entered no image shows.

b. If an image and text are entered it works, but the issue detailed above will occur (1. two duplicate thumb images, 2. mouseover on the the second duplicate thumb causes a false image load in the display block (shown above))

 

I am looking for a solution with no duplicate thumb, and text for that image if someone clicks the main display block. The text doesn't have to appear in the display block on thumb mouseover, only when the display block is clicked, and the image popup window appears.

 

I created a file to explain how to add "Click to Enlarge" to product thumbnails and "Click to Close" plus the HTML description to product image enlargements.

 

To see it in use, go to http://www.mainequiltcompany.com/shop/catalog and click on any product. When the product page opens, click on the main product image that says "Click to Enlarge". HTML description is located under the image.

product_info_changes.txt

Archived

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

×
×
  • Create New...