How to append a script to body tag of all pages in a website and pass values dynamically into the script using extension

This article refers to adding a script with dynamic values inside it. Here is an example: Adding a script for ROI tracking with dynamic values. Sample script structure: Here in the script we need to pass two values product name and total checkout amount of items in the cart, so the number of lines in… Continue reading How to append a script to body tag of all pages in a website and pass values dynamically into the script using extension

How to create an image element dynamically using JavaScript

We can create image element and append it to a document using JavaScript so that when someone clicks on the button the image will be created. We can get this by Approach: Create an empty image instance using new Image(). Then set its attributes like (src, height, width, alt, title, etc). Finally, insert it into the… Continue reading How to create an image element dynamically using JavaScript