Developer forum

Forum » Swift » DW10 Swift - Links in rich text editor

DW10 Swift - Links in rich text editor

Martin Ottesen
Martin Ottesen
Reply

Hi DW, 

So after (i suppose) the rich text editor has been changed to Quill, it seems that you can no longer control if a link opens in a new window or not?

We have on this solution/page https://tandlaegen.dk/behandlinger/loese-taender created anchor links for sections on the page for users to use.

But it seems that now all the links open in a new tab which is really not what we want.

It seems that the only thing you can now do is edit the link and save.

Is there any way for these links to just scroll to the section defined in the link?

I have tried to disable this:

But it does not seem to change anything.

Kind Regards
Martin

 


Replies

 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply

Hi Martin

It seems to be because of how we have implemented our link handlers. Will look at it.

To insert an anchor, there is a specific button for that. Currently you have to enter an ID of a paragraph for that to work. Should be a paragraph selector...

When you use anchor links, ensure to remove base href in header:

 

If not, the link will be understood as domain.com/#123 and will jump to the frontpage.

 
Martin Ottesen
Martin Ottesen
Reply

Hi Nicolai, 

Yeah im aware that there is an element/button that can handle anchor links, but some of these pages have 7-8 sections that we want to link to, and in that scenario the buttons dont really do the job. It was working with the old rich editor, and the links just scrolled down to the section.

The setting highlighted above is disabled. 

It is disabled aswell on this solution, which i thought might have been the issue, because i do hit the frontpage when adding the # even to a button.

https://bluevent.test002.webtester.dk/piping-systems/galvanised-pipe-system/assembly/standard-assembly-ring

Both of these hit the frontpage but only have the ID in the link, where its supposed to scroll down to the variant selector.

I might be missunderstanding something?

 
Oleg Rodionov Dynamicweb Employee
Oleg Rodionov
Reply
This post has been marked as an answer

Hi,

the appropriate behaviour of link and anchor will be fixed by new tasks created: #20526 and 20527.

BR, Oleg QA  

Votes for this answer: 1
 
Martin Ottesen
Martin Ottesen
Reply

Hi Oleg, That sounds great thank you :)

 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply

Hi Martin

The button I reffered to is in the RTE. Looks like a favorite icon.

On the linked solution you have base href - you need to set the checkbox to avoid the problem with linking to the frontpage:

 

You must be logged in to post in the forum