Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > simple html question about anchors

Reply
Thread Tools

simple html question about anchors

 
 
cronoklee@hotmail.com
Guest
Posts: n/a
 
      06-17-2006
Is it possible to set an anchor to jump to the middle of the screen
rather then the top when it is called? Needless to say I cannot just
move the anchor higher up the page ;c)

cheers,
Ciaran

 
Reply With Quote
 
 
 
 
tbar
Guest
Posts: n/a
 
      06-17-2006
> Is it possible to set an anchor to jump to the middle of the screen
> rather then the top when it is called? Needless to say I cannot just
> move the anchor higher up the page ;c)
>
> cheers,
> Ciaran
>


Not that I've heard of.
 
Reply With Quote
 
 
 
 
code_wrong
Guest
Posts: n/a
 
      06-17-2006

<(E-Mail Removed)> wrote in message
news:(E-Mail Removed) oups.com...
> Is it possible to set an anchor to jump to the middle of the screen
> rather then the top when it is called? Needless to say I cannot just
> move the anchor higher up the page ;c)
>




Do you mean something like this:
<a href="#tips">Jump to the Useful Tips Section</a>
blah
blah
blah
blah
blah
blah
blah
blah
blah
<a name="tips"></a>
blah
blah
blah
blah
blah
blah
blah
blah
blah
Useful Tips Section
blah
blah
blah
blah
blah
blah
blah
blah
blah


 
Reply With Quote
 
tbar
Guest
Posts: n/a
 
      06-17-2006
>> Is it possible to set an anchor to jump to the middle of the screen
>> rather then the top when it is called? Needless to say I cannot just
>> move the anchor higher up the page ;c)
>>
>> cheers,
>> Ciaran
>>

>
> Not that I've heard of.


css: center-this-thing, ignore all others
 
Reply With Quote
 
dorayme
Guest
Posts: n/a
 
      06-17-2006
In article <4494875d$(E-Mail Removed)>,
"code_wrong" <(E-Mail Removed)> wrote:

> <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed) oups.com...
> > Is it possible to set an anchor to jump to the middle of the screen
> > rather then the top when it is called? Needless to say I cannot just
> > move the anchor higher up the page ;c)
> >

>
>
>
> Do you mean something like this:
> <a href="#tips">Jump to the Useful Tips Section</a>
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> <a name="tips"></a>
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> Useful Tips Section
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah


Its hard enough to understand what OP wants without supposing he
wants to jump to the useful tips section well before that
section?

--
dorayme
 
Reply With Quote
 
code_wrong
Guest
Posts: n/a
 
      06-17-2006

"dorayme" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> In article <4494875d$(E-Mail Removed)>,
> "code_wrong" <(E-Mail Removed)> wrote:
>
>> <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed) oups.com...
>> > Is it possible to set an anchor to jump to the middle of the screen
>> > rather then the top when it is called? Needless to say I cannot just
>> > move the anchor higher up the page ;c)
>> >

>>
>>
>>
>> Do you mean something like this:
>> <a href="#tips">Jump to the Useful Tips Section</a>
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> <a name="tips"></a>
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> Useful Tips Section
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah
>> blah

>
> Its hard enough to understand what OP wants without supposing he
> wants to jump to the useful tips section well before that
> section?


yes it is a bit of a stab in the dark


 
Reply With Quote
 
CRON
Guest
Posts: n/a
 
      06-17-2006
Hi, Thanks for the replies: regarding code_wrong's post (quoted below).
I am looking for the this exact effect but the line:
<a name="tips"></a>
MUST be next to or beside the line:
Useful Tips Section

I cannot simply move the anchor up the page because it is generated as
part of a database list from PHP. So I need a way for the anchor to
find the centre of the screen rather then the top when called.

Any ideas?
Thanks
Ciaran


code_wrong wrote:

> <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed) oups.com...
> > Is it possible to set an anchor to jump to the middle of the screen
> > rather then the top when it is called? Needless to say I cannot just
> > move the anchor higher up the page ;c)
> >

>
>
>
> Do you mean something like this:
> <a href="#tips">Jump to the Useful Tips Section</a>
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> <a name="tips"></a>
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> Useful Tips Section
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah
> blah


 
Reply With Quote
 
tbar
Guest
Posts: n/a
 
      06-18-2006
It's commonly known as "tables are good"
 
Reply With Quote
 
CRON
Guest
Posts: n/a
 
      06-18-2006

tbar wrote:

> It's commonly known as "tables are good"


.....Yeah.... So has anyone got any ideas please?

 
Reply With Quote
 
Jonathan N. Little
Guest
Posts: n/a
 
      06-18-2006
Ciaran, please don't top post.

CRON wrote:
> Hi, Thanks for the replies: regarding code_wrong's post (quoted below).
> I am looking for the this exact effect but the line:
> <a name="tips"></a>
> MUST be next to or beside the line:
> Useful Tips Section
>
> I cannot simply move the anchor up the page because it is generated as
> part of a database list from PHP. So I need a way for the anchor to
> find the centre of the screen rather then the top when called.


Long ago I once experiment to do the very same thin in order to clear an
absolute positioned header at the top of the page. The bottom line was
it required JavaScript. The JavaScript got very complicated and results
was hardly satisfactory. Cross browser differences problem, trapping the
scroll via a link using a hash vs. just a page scroll, determining the
proper offset and then not triggering page scroll adjustment....it goes
on and on... There just is no really good way to accomplish what you
wish. The best solution is to adjust your php that outputs the db
results to make the anchor at the very top of the output and maybe tweak
your CSS to provide extra space to push the output into view.

A[name] { display: block; margin-bottom: 2em; }


<snipping the rest>

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
HTML forms & anchors psycho_joe88 HTML 2 07-31-2006 11:41 PM
newbie - HTML Anchors Mark Oliver ASP .Net 4 11-20-2004 05:50 AM
What about Anchors (#) and ASP.NET? Lars Netzel ASP .Net 5 07-27-2004 12:57 PM
Identifying calls from anchors =?Utf-8?B?UGF1bCBL?= ASP .Net 2 06-18-2004 03:39 AM
Bookmark Anchors and VB.NET Chris M ASP .Net 1 10-24-2003 12:31 PM



Advertisments