Java script to stop advertisment pop-ups

  • Java
  • Thread starter KLscilevothma
  • Start date
  • Tags
    Java
In summary, the conversation discusses the use of a free web-hosting provider, Angelfire, and the issue of pop-up advertisements that cannot be avoided. The speaker is looking for a solution to stop the pop-ups, whether it be through code or by switching to a different free web hosting service. Another speaker recommends using fortunecity.com for a small website as it offers more benefits such as no pop-ups, more bandwidth, and FTP access for a fee of $5.00 per month.
  • #1
KLscilevothma
322
0
I want to build a website and signed up in a free web-hosting provider, Angelfire. Because it is free of charge, advertisment pop-ups can't be avoided. Is there any code which I can paste in my website so as to stop the pop-ups? (I don't mind if I need to paste the code in every page of my homepage) Or do you have any web hosting service to recommend which is free, good and without the pop-up problem?
 
Technology news on Phys.org
  • #2
any ideeas? I'm interested too...
 
  • #3
Don't know about popups but most the time you can wipe the page clean by putting all of your HTML code on layer, use a high z-order e.g.

<div id="main" style="position:absolute; width:100%; height:300px; z-index:999; left: 0px; top: 0px;">
<table width="100%" height="100%">
<tr>
<td> My Content </td>
</tr>
</table>
</div>

I use fortunecity.com
 
Last edited:
  • #4
It's easy,

pay'em $5.00 a month and you won't have any popups, you'll get more bandwidth plus you get FTP access and can hotlink your files. I highly reccomend Angelfire to any small website builder.
 

What is JavaScript?

JavaScript is a programming language commonly used for creating interactive and dynamic elements on web pages. It is often used in conjunction with HTML and CSS to add functionality and interactivity to websites.

Why do I need to use JavaScript to stop advertisement pop-ups?

JavaScript allows you to control the behavior of your web page, including preventing pop-ups from appearing. It gives you the ability to manipulate the elements of a webpage, such as the pop-up window, in order to stop it from appearing.

How does JavaScript stop pop-ups?

JavaScript can be used to detect when a pop-up is about to open and then cancel the action, preventing the pop-up from appearing. This can be done by using the "onbeforeunload" event, which triggers when a user attempts to navigate away from a page or close the browser window, and then using the "return false;" statement to cancel the action.

Are there any other ways to prevent pop-ups without using JavaScript?

There are other methods, such as using browser extensions or adjusting your browser settings, to prevent pop-ups. However, using JavaScript gives you more control and flexibility in stopping pop-ups on your specific web page.

Can JavaScript completely eliminate all pop-ups on a webpage?

No, JavaScript can only prevent pop-ups that are triggered by actions on your webpage. It cannot stop pop-ups from appearing due to external sources, such as advertisements on other websites or malicious software on the user's computer. It is important to always use caution when browsing the internet and to have proper security measures in place to protect against pop-ups and other potential threats.

Similar threads

  • Programming and Computer Science
Replies
15
Views
1K
  • Programming and Computer Science
Replies
19
Views
2K
  • Programming and Computer Science
Replies
7
Views
471
  • Programming and Computer Science
Replies
1
Views
1K
  • Programming and Computer Science
Replies
3
Views
3K
  • Programming and Computer Science
Replies
23
Views
3K
  • Computing and Technology
Replies
11
Views
1K
  • Programming and Computer Science
Replies
2
Views
2K
  • Programming and Computer Science
Replies
13
Views
1K
  • Programming and Computer Science
Replies
2
Views
2K
Back
Top