Log In · Register

 
Need to find a script, ...
Melissa
post May 7 2008, 02:27 PM
Post #1


;)
******

Group: Duplicate
Posts: 2,374
Joined: Feb 2004
Member No: 3,760



I need to find a script that'll jump to different sections of a page. like, if you click a link, it'll take you to 1/4th down the page, another link'll take you 1/2 down the page, etc.

I can't seem to find it anywhere and I'm pretty sure it exists. ><
 
 
Start new topic
Replies
Christy
post May 7 2008, 03:07 PM
Post #2


Senior Member
******

Group: Design Staff
Posts: 2,244
Joined: Dec 2007
Member No: 596,992



alright; i'm not completely sure but i think it's this

CODE
<head>
<script language="JavaScript">
function X(){
onClick (window.location = "#something");
}
</script>
</head>
<body>
<a href="" onClick="X">Text</a>
 
mipadi
post May 7 2008, 03:31 PM
Post #3


Senior Member
******

Group: Administrator
Posts: 2,648
Joined: Apr 2008
Member No: 639,265



QUOTE(highwayto4355 @ May 7 2008, 04:07 PM) *
alright; i'm not completely sure but i think it's this

CODE
<head>
<script language="JavaScript">
function X(){
onClick (window.location = "#something");
}
</script>
</head>
<body>
<a href="" onClick="X">Text</a>

Why use JavaScript when you can just do this:

CODE
<a href="#something">Text</a>
 

Posts in this topic


Closed TopicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members: