Page 1 of 1

[SOLVED] Problems using Anchor Link tags

Posted: Sat Aug 25, 2012 2:07 pm
by CapereSpiritum
Hi

I am trying to add a link to a footer with a named anchor.

The page I'm linking to is called index.php?page=FAQ
The anchor is secure
I have adde this at the appropriate place on the page <a name="#secure"></a>

The link in the footer has the text 'Secure Online Purchase'.

I cannot fathom how to add {anchor anchor='secure' text='Secure Online Purchase'} to the <a> tag...

Looked in the past posts, sorry it escapes me...
???

Re: Problems using Anchor Link tags

Posted: Sun Aug 26, 2012 2:33 pm
by gianpiero

Re: Problems using Anchor Link tags

Posted: Mon Aug 27, 2012 10:56 am
by CapereSpiritum
Hi gianpiero

I'd seen that and inserted the following.

LINK HTML = <a href="/index.php?page=FAQ#secure">Secure Online Purchase</a>

ANCHOR HTML = {anchor anchor='secure' text='Is Your Website Secure'}
Also tried <a name="{anchor anchor='secure' text='Is Your Website Secure'}"></a> 'which does throw up an 'anchor' in WYSIWYG mode but with a visible ">.

None of the above does more than arrive at the FAQ page. They don't find the anchor...!

I know it's just my syntax, but I just can't get it right...

Re: Problems using Anchor Link tags

Posted: Mon Aug 27, 2012 1:09 pm
by Jo Morg
CapereSpiritum wrote:Hi gianpiero

I'd seen that and inserted the following.

LINK HTML = <a href="/index.php?page=FAQ#secure">Secure Online Purchase</a>

ANCHOR HTML = {anchor anchor='secure' text='Is Your Website Secure'}
Also tried <a name="{anchor anchor='secure' text='Is Your Website Secure'}"></a> 'which does throw up an 'anchor' in WYSIWYG mode but with a visible ">.

None of the above does more than arrive at the FAQ page. They don't find the anchor...!

I know it's just my syntax, but I just can't get it right...
You have seen but not read properly ;)
It's not the syntax but how you are using it...
anchor tag
Purpose

The anchor tag makes a proper anchor link to an anchor on the same page
How to use?

Insert the tag into your template/page like:

Code: Select all

    {anchor anchor='here' text='Scroll Down'}
In the pagesource you will get:

Code: Select all

<a href="/path/to/current/page#here">Scroll Down</a>
An anchor is created using the <a> tag.
If you want to create an anchor called here, you simply add this line where you want the anchor to be:

Code: Select all

<a name="here"></a> 
HTH

Re: Problems using Anchor Link tags

Posted: Mon Aug 27, 2012 2:11 pm
by CapereSpiritum
Hmmm, does that mean I can't have a link outside the page containing the anchor?

i.e. the link I'm trying to set up is in the footer global content block and so will appear on every page.

The anchor is on FAQ...

Re: Problems using Anchor Link tags

Posted: Mon Aug 27, 2012 2:13 pm
by gianpiero
jo morg explained well ;)

I put anchors this way:

1) position the mouse where I need the anchor is, and define it

Code: Select all

<a name="name_of_anchor"></a>

text between a and a is not needed

2) Select the text that you want to call the anchor and define link

Code: Select all

<a href="path_and_name_of_page#name_of_anchor">test calling anchor</a>
hi
thanks to jo morg

Re: Problems using Anchor Link tags

Posted: Mon Aug 27, 2012 2:16 pm
by gianpiero
CapereSpiritum wrote:Hmmm, does that mean I can't have a link outside the page containing the anchor?
yes you can, add the path before,

or absolute path that open new window

Re: Problems using Anchor Link tags

Posted: Mon Aug 27, 2012 2:24 pm
by Jo Morg
gianpiero wrote:
CapereSpiritum wrote:Hmmm, does that mean I can't have a link outside the page containing the anchor?
yes you can, add the path before,

or absolute path that open new window
Precisely. You just don't use the tag {anchor anchor='here' text='Scroll Down'} from a different page AFAIK...

Re: [SOLVED] Problems using Anchor Link tags

Posted: Wed Aug 29, 2012 11:11 am
by CapereSpiritum
Thanks for the help guys.
All sorted with:
Link = <a href="index.php?page=FAQ#secure">Secure Online Purchase</a>
Anchor = <a name="secure"></a>