Where do I Install the SmartPiXL Code?
To fully utilize SmartPiXL and ensure it captures traffic sitewide, including all subdomains, follow these detailed instructions.
Where to Install the SmartPiXL Code
- Global Head Section: The SmartPiXL code should be installed within the
<head>
section of your website. This placement allows SmartPiXL to capture traffic across your entire site effectively.
Steps to Install the SmartPiXL Code
-
Access Your Website's HTML:
- Open your website’s HTML files using a text editor or through your content management system (CMS).
-
Locate the
<head>
Section:- Find the
<head>
section in your HTML file. This section is typically at the beginning of your HTML document.
- Find the
-
Copy and Paste the SmartPiXL Code:
-
Copy the SmartPiXL code provided to you.
-
Paste the code within the
<head>
section of your website’s HTML. It should look something like this:<head>
<!-- Other head elements like title, meta tags, etc. -->
<script>
// Your SmartPiXL code goes here
</script>
</head>
-
-
Save and Publish:
- Save the changes to your HTML file.
- Publish or upload the updated file to your server.
Installing the SmartPiXL Code on Subdomains
- Same Server Subdomains: If your subdomains are hosted on the same server as your main site, the SmartPiXL code in the global
<head>
section will cover these subdomains automatically. - Different Server Subdomains: For subdomains hosted on different servers, you will need to repeat the above steps for each subdomain to ensure SmartPiXL captures all traffic.
Example Scenario
Here’s an example to illustrate the process:
-
Main Site:
- URL:
www.yourwebsite.com
- HTML file:
index.html
- Insert the SmartPiXL code in the
<head>
section ofindex.html
.
- URL:
-
Subdomain on Same Server:
- URL:
blog.yourwebsite.com
- HTML file:
blog.html
- No additional action needed if it shares the same server and global
<head>
section.
- URL:
-
Subdomain on Different Server:
- URL:
shop.yourwebsite.com
- HTML file:
shop.html
- Insert the SmartPiXL code in the
<head>
section ofshop.html
on the different server.
- URL:
FAQs
Q: What happens if I don’t install the code in the <head>
section? A: Installing the code outside the <head>
section may prevent SmartPiXL from capturing all traffic efficiently, especially for subpage loads.
Q: Do I need to reinstall the code after making updates to my website? A: Generally, you do not need to reinstall the code unless the <head>
section is modified or overwritten during updates.
Q: Can I use a tag manager to install the SmartPiXL code? A: Yes, using a tag manager like Google Tag Manager is an efficient way to manage and deploy tracking codes, including SmartPiXL. Keep in mind, there is a degradation in the URL path returned for each consumer captured through SmartPiXL; however, this is out of our control and due to constraints within Google Tag Manager itself.
By following these steps, you ensure that SmartPiXL is correctly installed and able to capture traffic across your entire site, including subdomains. If you have any issues or need further assistance, please contact Service@SmartPiXL.com.
For more information on SmartPiXL and detailed installation guides, contact our SmartPiXL Support Team at Service@SmartPiXL.com.