Javascript Image Slider / Posts /

Multiple Licenses for the same slider?

Are you able to include multiple licenses on a single .js file?  I have multiple URL's of the same website and use Intuit to build the site.  If so, how would i do that?
Matt  4 years ago   viewed: 22313    

1 Answer

Yes you can add a piece of code just after the var sliderOptions block to handle the different domains. Below is a sample for four domains:
var sliderOptions = { ...... license: "license1" }; if(document.domain.indexOf("")!=-1) sliderOptions.license = "license2"; else if (document.domain.indexOf("")!=-1) sliderOptions.license = "license3"; else if (document.domain.indexOf("")!=-1) sliderOptions.license = "license4"; var imageSlider=new mcImgSlider(sliderOptions); /* Menucool Javascript Image Slider ... (the follows are remain unchanged)
  4 years ago


Your name*
(Optional. Used to modify this post afterwords)
+ =  

Ask your Own Question

  • If your question is related to the topic of this post, you can post your question to this page by clicking the "Post a reply" button at left;

  • When you want to start a new page for your question: