Jump to content

attributes name under images


Recommended Posts

Does any one know if its possible that if you select a attribute when it shows the assigned picture it can display the attributes name or the image title under it? I know when you enlarge the image it is in the light box but i would like it under the smaller image.

its on the product page i need it:
http://oscarshb.com/141-grade-c-clip-in-extensions.html

also see screen grab

20208_eRh7SAq5oWptRAvv3JLF_t

Link to comment
Share on other sites

Everything is possible with a little code modification.

You could create a new div under the main image, and than modify the code (in /themes/prestashop/js/product.php) to enter the currently selected attribute name in that div.

The function that gets called when a dropdown value is changed in findCombinations(), so you would want to add your modification there.

Link to comment
Share on other sites

HI,
just wanted to add a quick update to this as I managed to get this to work for me... Jquery to the rescue.

first i added a div where i wanted the text to appear and gave it an ID (in the case altunder) then in the product.js file under function findCombination(firstTime) i added:

$('#altunder').html('' + $("#group_4 option:selected").text() + ' ');

this worked but is a bit of a bodge as it will only work for the one set of attributes,that is hard coded. im sure with a little bit more work it could be modified to look up the group number.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...