Use jQuery to dynamically add small ads and jquery to dynamically add

Source: Internet
Author: User

Use jQuery to dynamically add small ads and jquery to dynamically add

When you browse a website, some websites always place advertisements in the lower right corner, upper left corner, or other places.

I tried to create one by myself using jQuery. The Code is as follows. If something is wrong, please kindly advise.

1 <! DOCTYPE html> 2 

As follows:

 

I have the following thoughts on this effect:

1. you can add a timer, countdown to '5 s shutdown ', and '4s shutdown' to tell the user that the ad is only temporarily placed and automatically closed after 5 S, which enhances user experience, we all know that when Browsing some websites, advertisements are always wandering in front of you, and the user experience is definitely not very good, which can strike a good balance between advertising customers and user experience;

2. The reason for choosing orange as the background color is because orange is warm and personal experience. If the background color of an advertisement is warm, you are more willing to let him stay for some time. The background color is cooler than the background color;

3. Of course, this is just a small code. After the contents are completed, they can be encapsulated and used more conveniently.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.