Select Category
Sitemap Help Contact
print article

Integrate Scripts or Custom HTML to a MyWebsite Package

For MyWebsite packages.

Follow the steps below to integrate custom HTML code and scripts into your MyWebsite.

There are two possible places where it is possible for you to include custom HTML or scripts such as Javascript in a MyWebsite package:

  • Within the <head> tag or header.
  • In one of the MyWebsite pages directly.

The <head> tag is normally used to define javascript functions for use in multiple pages or javascript that should be run on every page load.

It is also possible to add your own custom HTML or javascript within a page directly if only one page requires a script or custom HTML.

Adding HTML to the Header

Step 2
Click the Settings icon from the Main Menu on the right-hand side. MyWebsite editor
MyWebsite editor
Step 3
Click the Edit header section icon. Settings section
Settings section
Step 4
Enter the HTML necessary for the <head> tag and then click the Save button at the bottom of the pop-out window. Edit Header screen
Edit Header screen
Step 5
A message should be displayed that the code has been saved. Edit Header screen
Edit Header screen

Adding HTML to a page

Step 2
Click the Insert Elements button from the menu on the right-hand side.
Click the Insert Elements button
Click the Insert Elements button
Step 3
Click and hold the Widget/HTML icon from the Basics category and... Click and hold the Widget/HTML icon
Click and hold the Widget/HTML icon

Drag the icon over to the page where you want the HTML code to appear. When it is positioned correctly, release the mouse button.

Drag the icon over to the page and release the mouse button
Drag the icon over to the page and release the mouse button
Step 4
Enter your HTML or script into the text box and then click the Save button to save your changes. Enter the HTML and then click the Save button
Enter the HTML and then click the Save button
Step 5
You will receive a message that states The widget is only displayed in the page view, not in the editing mode. A message is displayed
A message is displayed
Step 6
Click the Preview button at the top of the page to test the functionality of the widget/HTML. Click the Page View link
Click the Page View link
Step 7
You should now see the widget/HTML on your page and can make sure it is functioning properly. The widget is added
The widget is added

To return to the editing mode, scroll down again and click the Edit page link this time.

For additional information, you may want to reference: