How to include adverts in your website

Best Practices > Step 1 - Settings > The Advanced section >

How to include adverts in your website

Previous pageReturn to chapter overviewNext page
Show/Hide hidden text

It's normal to visit websites that include lots of advertizing, as well as the actual contents. Adverts are often banners or video-trailers that open in popup windows, and there are many other forms.

Adding adverts to sites, especially those that have a lot of visitors, is an excellent way of earning money because, not only can you publicize your products but, above all, you can publicize those of others and be paid for the space and visibility you give to third parties.  

In WebSite X5 there are a number of ways to advertize your own products: you can, for example, use the Image Object to add banners to a page, or use the options in Step 1 - Advertising Message. If, on the other hand, you adhere to a specific program (for example, Google AdSense) that publishes adverts that you are paid for according to a certain criterion (the number of hits, clicks, and so on) usually you have to add specific HTML code to your page. In these cases, in WebSite X5 you have to use the HTML Code Object.

Click to expand/collapseHow to add a banner to the header or a page

A banner can be handled as a normal image and, as such, is inserted inside the template's header or in a specific website page:

If you want to add a banner to the header, go to Step 2 - Template Content, in the Header  section and insert an Image Object in the position you want it.
If you want to add a banner to a web page, go to Step 3 - Map and select the page you want to work on and, in Step 4 - Pages insert an Image Object in a cell in the page layout table.
In both cases, double-click on the Image Object you insert and import the graphic file for the banner.
Click on the button to open the Link window and add a link to the banner: for example, you can link a specific page which may be in your website or a different one.

A banner may be static or animated, with a series of images, one after the other. An easy solution is to save the banner as an animated .GIF file and follow the above procedure to include it in the template's header or directly in a page, using the Image Object.

An alternative solution is to save the single images and use them to make a Gallery Object. In this case you are advised to select the Classic Slideshow, making sure you deselect the Show Control Bar.

Another possibility is to prepare an animation for the banner and use the HTML5 Animation Object to add it to the header or page.

With WebAnimator you can create animated banners and gifs that are perfect for your website. Try it now at www.webanimator.com.

Click to expand/collapseHow to add a banner as the background of the browser window

Some portals use alternative methods of advertizing, and one of these is to display a large picture directly as the background of the browser window. You can use this feature with WebSite X5: the procedure to follow depends on whether you intend to define this feature for the whole site or only for specific pages.

To set a background image for the whole site:

In Step 2 go to the Template Structure window. Remember that this feature can also be used with default templates: in this case, you need to make a copy of the template first, to keep the original unchanged.
In the Page section list, select the Page Background and import the Image File for the banner you are going to use.
Use the available options to set alignments and margins.

To set a background image for a specific page in the website:

In Step 3 - Map select the page to work on and click on the Properties button to open the Page Properties window.
Go to the Graphic section and, in WebSite Background for this Page only, import the graphic file for the banner you are going to use.
Use the Link option to add a link to the banner's image.
Click to expand/collapseHow to display an advert in a popup window

If you want an advert to be displayed in a popup window when one or more website pages are opened, you need to:

In Step 1 open the Advertising Message section and select the Show the Advertising Message option.
Select the Message Type, choosing between Advert, Show ads in a box, and Cover message.
Import the graphic file for the banner you are going to use and define the settings for it.
Add a link to the banner, choosing the Link.
Specify which pages the banner must appear in.
If necessary, indicate the start and end dates of the period the advert is to be displayed for, and the interval of time between opening the page and displaying the banner.
Click to expand/collapseHow to enter Google AdSense code for an advert

Once you have signed up to Google AdSense, or another similar program, and have received the necessary code to include an advert in your pages, you have to:

In Step 3 - Map select the page to work on and go to Step 4 - Pages where you have to insert an HTML Code Object in a cell in the page layout table.
Double-click in the HTML Code Object you have inserted and copy the HTML code into it.

Following the same procedure, the HTML code for adverts can also be added to the header/foot of the website's template.