Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

Redirect to a place within a page?

Avatar

Level 2

Im using CQ5 and wondering if there is way to redirect to an point (anchor) within a page from a different page or redirect link? THANKS!

1 Accepted Solution

Avatar

Correct answer by
Administrator

georgea85485796 wrote...

Hi. Thanks for your response. I understand how to use an anchor...but how do I create an anchor within an adobe experience manager page? Im in CQ5 and there is no way (I can see) how to get into the code. Thoughts? Suggestions? Regards!

 

Hi 

I am not sure, if this is available in cq5, but RTE/TE might have anchor tag like we have since 5.3

Documentation:- https://docs.adobe.com/docs/en/cq/5-3/administering/configuring_rich_text_editor.html

Please have a look at this community article:- https://www.bc.edu/offices/its/projects/day/docs/adding_a_link/adding_anchors.html

I hope this might help you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

View solution in original post

7 Replies

Avatar

Level 7

I am not sure if I am getting your question correctly, but are you looking for partial refresh?

I do not think this is present there OOTB. You have to write extensive code in javascript to achieve this scenario. 

 

Or if you are looking to redirect to a page from another page through some link, that's straight as an arrow. Have a path field, text field in dialog and use that to render as href in your front-end code. Alternatively you could also author a link in the rich text editor.

Thanks

Tuhin

Avatar

Administrator

Hi 

Please explain the bit more on the use-case you want to achieve.

As i understood it, you can use Anchor Tags to jump to specific location on a page.

Anchor to anchor

Link:- http://help.typepad.com/anchor-tags.html

Create a Anchor tags:

<a name="anchor1"></a>

<a name="anchor2"></a>

<a href="#anchor1"><img src="http://example.typepad.com/raptors.gif" /></a>  [This is jump you to anchor1 position].

 

Anchor to DIV

<a href="#test1" id="back">Test</a> <div id="test1" onclick="window.location.hash='back'; ">

Demo:- http://jsfiddle.net/GP77J/2/

 

I hope this will help you.

Note: You can create a din/Anchor from source code of text editor component, RTE etc.

 

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

Avatar

Level 9

As suggested in previous posts, anchor link (div id of the page) with "#" should work.

for instance <a href="my page.html#MYDIV"> HELLO </a>. When you open this link from different page, it will load "my page.html" and redirect to particular div.

Avatar

Level 2

I have a link from one page pointing to another page with a trailing anchor link in the URL, but it won't take the user down to the div on the new page. For example:

traintracks.html#curved

Won't take user to 

<div id="curved">

However, this same link in the stick nav works.

Avatar

Level 2

I understand how to use an anchor...but how do I create an anchor within an adobe experience manager page? Im in CQ5 and there is no way (I can see) how to get into the code. Thoughts? Suggestions? THANKS!

Avatar

Level 2

Hi. Thanks for your response. I understand how to use an anchor...but how do I create an anchor within an adobe experience manager page? Im in CQ5 and there is no way (I can see) how to get into the code. Thoughts? Suggestions? Regards!

Avatar

Correct answer by
Administrator

georgea85485796 wrote...

Hi. Thanks for your response. I understand how to use an anchor...but how do I create an anchor within an adobe experience manager page? Im in CQ5 and there is no way (I can see) how to get into the code. Thoughts? Suggestions? Regards!

 

Hi 

I am not sure, if this is available in cq5, but RTE/TE might have anchor tag like we have since 5.3

Documentation:- https://docs.adobe.com/docs/en/cq/5-3/administering/configuring_rich_text_editor.html

Please have a look at this community article:- https://www.bc.edu/offices/its/projects/day/docs/adding_a_link/adding_anchors.html

I hope this might help you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni