[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Hide link until page is loaded

Posted on 2005-04-13
6
Medium Priority
?
390 Views
Last Modified: 2008-02-26
Hi,

How do I hide a link until the page is fully loaded?
0
Comment
Question by:kgp43
6 Comments
 
LVL 25

Expert Comment

by:archrajan
ID: 13774455
<a href = "mypage.html" id = "link1" style = "display:none">This link will show only on page loaded </a>

<script>
document.getElementById('link1').style.display = "";
</script>
</body>

put that before ur </body> tag
0
 

Author Comment

by:kgp43
ID: 13774477
Is there a way to include the JS script in the link instead?
0
 
LVL 25

Accepted Solution

by:
archrajan earned 375 total points
ID: 13774491
try this then. i doubt this wud work

 <a href = "mypage.html" id = "link1" style = "display:none" onload = "this.style.display = ''">This link will show only on page loaded </a>
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
LVL 13

Expert Comment

by:davidlars99
ID: 13778744
I can do that for you but it will work only for Internet Explorer, is this ok..?
0
 
LVL 1

Expert Comment

by:udilipkumar
ID: 13790556
Hi

Hope this should work


<a href = "mypage.html" id = "link1" style = "display:none">This link will show only on page loaded </a>

<body onLoad="document.getElementById('link1').style.display='block' ">



0
 

Author Comment

by:kgp43
ID: 13810645
working, thanks.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my daily work (mainly using ASP.net), I need to write a lot of JavaScript code. One of the most repetitive tasks I do are the jQuery Ajax calls. You know: (CODE) I don't know if for you it's the same, but for me is soooo tedious to write the …
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Suggested Courses

873 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question