TOPIC:

Variation with photo 3 years 3 months ago #208301

  • Topic Author
  • aluminiumtechnik
  • Offline
  • Junior Breezer
  • Junior Breezer
  • Posts: 29
  • Thanks: 1
THX :-)

Please Log in or Create an account to join the conversation.

Variation with photo 3 years 3 months ago #208328

  • helena.dobrovic's Avatar
  • helena.dobrovic
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 1511
  • Karma: 48
  • Thanks: 130
Hi,

you can take a look now. It's functioning. :)

I've adjusted script which is following:
    // ****************BreezingCommerce custom script*********************** //
    
  $('[name="crbcProperties[]"]').change(function() {
  
  if($('[name="crbcProperties[]"]').val() == "893") {
  
  $("#crbc-zoom-thumbnails li:first-child").addClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(2)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(3)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(4)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(5)").removeClass("current-img");
      
  $("#crbc-zoom-thumbnail").attr("src", "/images/breezingcommerce/products/large/rollfix_300_fussplatte-410521383180763378910864968531862245361.png");
  
  }
  
  else if ($('[name="crbcProperties[]"]').val() == "892") {
  
  $("#crbc-zoom-thumbnails li:first-child").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(2)").addClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(3)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(4)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(5)").removeClass("current-img");
      
  $("#crbc-zoom-thumbnail").attr("src", "/images/breezingcommerce/products/large/rollfix_300_150rollemitspindel-121834821221392737397607459261597342772.png");
  
  
  }
  
  else if ($('[name="crbcProperties[]"]').val() == "874") {
  
  $("#crbc-zoom-thumbnails li:first-child").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(2)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(3)").addClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(4)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(5)").removeClass("current-img");
  
    $("#crbc-zoom-thumbnail").attr("src", "/images/breezingcommerce/products/large/rollfix_300_mit_dreieckausleger-1071588253146619429916052290901970664305.png");

  }
  
  else if ($('[name="crbcProperties[]"]').val() == "873") {
  
  $("#crbc-zoom-thumbnails li:first-child").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(2)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(3)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(2)").addClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(3)").removeClass("current-img");
  
    $("#crbc-zoom-thumbnail").attr("src", "/images/breezingcommerce/products/large/rollfix_300_fussplatte-8696984275471887812513234481864908037.png");

  }
  
  else if ($('[name="crbcProperties[]"]').val() == "872") {
  
  $("#crbc-zoom-thumbnails li:first-child").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(2)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(3)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(4)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(5)").addClass("current-img");
  
    $("#crbc-zoom-thumbnail").attr("src", "/images/breezingcommerce/products/large/rollfix_300_teleskoptraverse-149437142681167175317626404021460220268.png");

  }

  else {
  
  $("#crbc-zoom-thumbnails li:first-child").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(2)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(3)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(4)").removeClass("current-img");
  $("#crbc-zoom-thumbnails li:nth-child(5)").removeClass("current-img");
  
  
  }
  
});

// ****************End of BreezingCommerce custom script*********************** //

It's inside main.js file.

Let us know if this works for you.

Kind Regards,
Helena
=========================================
Need to renew Pro Support?
Buy Here!
=========================================
Satisfied?
Consider a membership!
=========================================
Like us on Facebook
=========================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!

Please Log in or Create an account to join the conversation.

Variation with photo 3 years 3 months ago #208335

  • Topic Author
  • aluminiumtechnik
  • Offline
  • Junior Breezer
  • Junior Breezer
  • Posts: 29
  • Thanks: 1
Hi Helen thank you very much :-)
My question: what means this: if($('[name="crbcProperties[]"]').val() == "893") { the number 893 ? Its an id from product?

I have more than one product to enter in this konfigurator. Indeed a lot of them, how can I give this code to another product with outer images? Need an ID?

And I have to put accessories to every product. Is there an possibility to set an small foto to it? See here: konf.altec-alu.de/rollfix/fahrgeruste/31733-rollfix-300

We don't want display the thumbnails and so I setist display:none;
And finaly how or where can I show the productimage bigger and also the zoom? He is very small in the moment.

THX Roman

Please Log in or Create an account to join the conversation.

Variation with photo 3 years 3 months ago #208344

  • helena.dobrovic's Avatar
  • helena.dobrovic
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 1511
  • Karma: 48
  • Thanks: 130
Hi,

we did some adaptation to make it easier for you :)

Please see following code:
   // ****************BreezingCommerce custom script*********************** //
    
  $('[name="crbcProperties[]"]').change(function() {
  
  if($(this).children("option:first-child").is(":selected")) {
  
  
  $("#crbc-zoom-thumbnails li:first-child").trigger("click");
 
  
  }
  
  else if ($(this).children("option:nth-child(2)").is(":selected")) {
  
 
  $("#crbc-zoom-thumbnails li:nth-child(2)").trigger("click");
  
  
  }
  
  else if ($(this).children("option:nth-child(3)").is(":selected")) {
  
 
  
  $("#crbc-zoom-thumbnails li:nth-child(3)").trigger("click");

  }
  
  else if ($(this).children("option:nth-child(4)").is(":selected")) {
  
 
  
  $("#crbc-zoom-thumbnails li:nth-child(4)").trigger("click");

  }
  
  else if ($(this).children("option:nth-child(5)").is(":selected")) {
  
  
  $("#crbc-zoom-thumbnails li:nth-child(5)").trigger("click");

  }

  
});

// ****************End of BreezingCommerce custom script*********************** //

The principle is when you choose one of the options they are gonna be triggered automatically. That means you don't need to put values and images in your code anymore.

When you want to add new value just add new else if statement with increased nth-child(numberWhichFollows)

Let us know the feedback.

Regards,
Helena
=========================================
Need to renew Pro Support?
Buy Here!
=========================================
Satisfied?
Consider a membership!
=========================================
Like us on Facebook
=========================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!

Please Log in or Create an account to join the conversation.

Variation with photo 3 years 3 months ago #208419

  • helena.dobrovic's Avatar
  • helena.dobrovic
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 1511
  • Karma: 48
  • Thanks: 130
Hi,

I'm just double checking is everything good now :)

Did you test it?

Regards,
Helena
=========================================
Need to renew Pro Support?
Buy Here!
=========================================
Satisfied?
Consider a membership!
=========================================
Like us on Facebook
=========================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!

Please Log in or Create an account to join the conversation.

Variation with photo 3 years 3 months ago #208420

  • Topic Author
  • aluminiumtechnik
  • Offline
  • Junior Breezer
  • Junior Breezer
  • Posts: 29
  • Thanks: 1
Hi still not, I have to make outer things today :-(

Monday I can try ist and will give you feedback.

THX Roman

Please Log in or Create an account to join the conversation.

Time to create page: 0.049 seconds

BreezingForms Pro 1.4.7 for WordPress Released!

Available in the membership section.

September Discount!

Massive discounts on all subscriptions!

Get Your Subscription Here

Quick Links

Downloads

BreezingForms

ContentBuilder

BreezingCommerce

Templates

Documentation

BreezingForms

ContentBuilder

BreezingCommerce

Apprendre BreezingForms (French Community)

Apprendre et maîtriser BreezingForms par des tutoriels et exemples, le tout en français

breezingforms.eddy-vh.com

Questions et réponses sur les forums de l'AFUJ

AFUJ

Special Offer

Summer Sale! All subscriptions at a special price!

Includes prio support, all of our current and future Joomla!® extensions and Joomla!® templates for the duration of your membership.

Get it from here

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our subscription plans.

How to receive the discount:

Send us a quick email to sales@crosstec.org with a proof of purchase (for example a paypal receipt), await payment instructions and enjoy your membership!