Text Component and Internal Link issue

Avatar

Avatar
Validate 1
Level 2
victor_toledo_3
Level 2

Likes

14 likes

Total Posts

39 posts

Correct reply

4 solutions
Top badges earned
Validate 1
Ignite 1
Give Back 5
Give Back 3
Give Back
View profile

Avatar
Validate 1
Level 2
victor_toledo_3
Level 2

Likes

14 likes

Total Posts

39 posts

Correct reply

4 solutions
Top badges earned
Validate 1
Ignite 1
Give Back 5
Give Back 3
Give Back
View profile
victor_toledo_3
Level 2

10-04-2019

Hi all,

I have a strange issue with the text component (core/wcm/components/text/v1/text) and a link to an internal page. When I add a link to the internal content, the host name is added to the link and saved in the repository, obviously causing a problem when publishing the page, since the link points to the author.

i'm working with AEM 6.3.0.0, fresh instance (i started the server on port 4505) and We.Retail site

Let me try to explain you the issue with some pics

adding_text_component.png

Then i'm trying to add a text with hyperlink to internal content

creating-hyperlink.pngselecting-internal-content.png

In the image you can see the internal path is correct without hostname

applying-change.png

But when i apply the changes and debug the code

debugging-code1.png

the variable url has the correct value but the when the code save the attributes and get the href value from the child node the hostname is added

debugging-code2.png

And that is the value that is saved to the repository as you can see in the next image

crxde.png

And then when i published that page, obviously the link is pointing to author. So i dont know the why text component (or jquery, or javascipt) is adding the hostname to the url.

Now, if I update the value of the existing link, everything works fine because another javascript flow is executed

any help will be welcome

Thanks in advance

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Validate 1
Level 2
victor_toledo_3
Level 2

Likes

14 likes

Total Posts

39 posts

Correct reply

4 solutions
Top badges earned
Validate 1
Ignite 1
Give Back 5
Give Back 3
Give Back
View profile

Avatar
Validate 1
Level 2
victor_toledo_3
Level 2

Likes

14 likes

Total Posts

39 posts

Correct reply

4 solutions
Top badges earned
Validate 1
Ignite 1
Give Back 5
Give Back 3
Give Back
View profile
victor_toledo_3
Level 2

11-04-2019

Hi all, i found the issue and the solution,

I was testing in aem 6.3.3 and the problem does not occur.

Then, I realized that the problem was in 6.3, comparing the js I see that it has been solved sometime between 6.3 and 6.3.3.

AEM 6.3.0.0

Screen Shot 2019-04-11 at 10.19.52.png

AEM 6.3.3.0

Screen Shot 2019-04-11 at 10.20.05.png

So the solution is to update the instance.

Thanks to all

Answers (5)

Answers (5)

Avatar

Avatar
Boost 5
Employee
hanishb17637780
Employee

Likes

7 likes

Total Posts

23 posts

Correct reply

6 solutions
Top badges earned
Boost 5
Boost 3
Boost 1
Affirm 5
Affirm 3
View profile

Avatar
Boost 5
Employee
hanishb17637780
Employee

Likes

7 likes

Total Posts

23 posts

Correct reply

6 solutions
Top badges earned
Boost 5
Boost 3
Boost 1
Affirm 5
Affirm 3
View profile
hanishb17637780
Employee

12-04-2019

Indeed!

Just to be clear, This issue was fixed in 6.3.0.1. So, an AEM instance upgraded to any CFP/SP would see this issue resolved.

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

11-04-2019

Thxs for posting the solution!

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

10-04-2019

I will test this too

Avatar

Avatar
Validate 1
Level 2
victor_toledo_3
Level 2

Likes

14 likes

Total Posts

39 posts

Correct reply

4 solutions
Top badges earned
Validate 1
Ignite 1
Give Back 5
Give Back 3
Give Back
View profile

Avatar
Validate 1
Level 2
victor_toledo_3
Level 2

Likes

14 likes

Total Posts

39 posts

Correct reply

4 solutions
Top badges earned
Validate 1
Ignite 1
Give Back 5
Give Back 3
Give Back
View profile
victor_toledo_3
Level 2

10-04-2019

Hi JaideepBrar, i'm using a new installation of aem 6.3 I've not changed nothing

Avatar

Avatar
Coach
Employee
jbrar
Employee

Likes

389 likes

Total Posts

869 posts

Correct reply

283 solutions
Top badges earned
Coach
Establish
Give Back 50
Give Back 5
Give Back 3
View profile

Avatar
Coach
Employee
jbrar
Employee

Likes

389 likes

Total Posts

869 posts

Correct reply

283 solutions
Top badges earned
Coach
Establish
Give Back 50
Give Back 5
Give Back 3
View profile
jbrar
Employee

10-04-2019

Tried using we-retail Text component and it does not add the hostname:

Screen Shot 2019-04-10 at 7.29.42 PM.png

Have you customized the component? If not, try comparing linkchecker/sling mapping configuration.