Forums / Bug Reports / Additional images issue when space used in image name

Additional images issue when space used in image name

Started by swguy on 9 Feb 2015, 6:09 PM · Views: 787

Results 1 to 2 of 2
9 Feb 2015, 6:09 PM
#1
swguy avatar

swguy

Administrator

Join Date:
Feb 2006
Location:
Tampa Bay, Florida
Posts:
10,743
Plugin Contributions:
56

Additional images issue when space used in image name

includes/templates/template_default/popup_image_additional/tpl_main_page.php seems to need

  $_GET['products_image_large_additional'] = str_replace('+', ' ', $_GET['products_image_large_additional']);

at the top to remove the '+' which was used to replace ' ' in

includes/modules/pages/popup_image_additional/header_php.php

(Of course this isn't a robust fix because it will fail if the image filename actually does contain '+'.)

Can you do some kind of URL encoding on this passed variable, or perhaps pass it as a POSTed variable?

Sample Image Names:
Raptor Medium.jpg (main image)
Raptor Medium_1.jpg (additional image)

That Software Guy. My Store: Zen Cart Support
Available for hire - See my ad in Services
Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
Do you benefit from Zen Cart? Then please support the project.

20 Feb 2015, 7:31 AM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: Additional images issue when space used in image name

v1.6.0 handles that page's URL parameters differently, for this same reason (and a few others).

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.