| https://jaipurrugs.explorug.com/?mode=ecat&initdesign=Design Name | ||
img id=customizeImg
|
Design name Size iFrame src
Customize the design button <-- id=CustomizeIt After customization is done, click on the "Calculate" button. The child (iframe) will throw the message to parent window(main page) with JSON information. |
|
| REQUIRED CODE | ||
CSS |
||
| Jquery Link <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script> |
||
| JavaScript with Listen function <script> //Hiding iframe after data received var customizeData = "PhysicalWidth= " + data.PhysicalWidth + " PhysicalHeight= " + data.PhysicalHeight + " Unit =" + data.Unit + " ImageUrl = " + imgsrc + " DesignId=" + data.designid; if (window.self !== window.top) { //if the page has a parent on top of it |
||
| iFrame placed in a div [place just after <body> tag] <div id="exploRUGiFrame"> <iframe id="iFrameSet" style="border:none; " height="100%" width="100%" scrolling="auto" allow="camera" allowfullscreen="" ></iframe> </div> |
||
| Make sure to add id="website" to main div of your website | ||
| Customize this design code <a id="CustomizeIt" rel="https://jaipurrugs.explorug.com/?mode=ecat&initdesign=Delerague.ctf">Customize the design button</a> |
||
| Jquery command [before </body> tag] <script> $("#exploRUGiFrame").css("display", "block"); //alert(iFrameSrc); }); |
||