Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unsubscribe link #29

Closed
p380 opened this issue May 11, 2020 · 8 comments
Closed

Unsubscribe link #29

p380 opened this issue May 11, 2020 · 8 comments
Labels
question Further information is requested

Comments

@p380
Copy link

p380 commented May 11, 2020

hello,

I have a question about generating a unsubscribe link to the newsletter.
We use TYPO3 where the URL to BE and FE is at different URLs. As a result, the unsubscribe link does not work.

Is it possible to edit a template where a domain constant could be used in the newsletter unsubscribe link?

ex.
<f:link.external uri="{luxletter:configuration.getDomain()}{luxletter:mail.getUnsubscribeUrl(newsletter:newsletter,user:user)}" additionalAttributes="{data-luxletter-parselink:'false'}" style="color:#fff; font-weight: normal;">Unsubscribe</f:link.external>

Regards

@einpraegsam
Copy link
Collaborator

I don't understand it at the moment. The defined domain, that you have stored in extension configuration is different from the Frontend Domain? So you have a different domain for parsing the newsletter then from unsubscribing?

@agendartobias
Copy link

Hey, we have also simmilar problem. We also use different domains like that:

editor.globalhostingdomain.si/sitename (is domain for BE editing and for FE prewiev),
test.sitename.si (is domain only for FE testing and preview)

So url deifnition in lux settings is set to test.sitename.si (for generating links...), also we define this url to fetch newsletter page when newsletter is generated.

But when newsletter is send out, unsubscribe link be like:

http://test.sitename.si/**sitename**/odjava-od-novic/?tx_luxletter_fe%5Bhash%5D=&tx_luxletter_fe%5Bnewsletter%5D=0&tx_luxletter_fe%5Buser%5D=0&cHash=6fd499e9cf90e399992a95565edf7fc8

So if you see /sitename/ shudnt be in this unsubscribe url.

@p380
Copy link
Author

p380 commented May 11, 2020

we use the same system of domains or URLs

@einpraegsam
Copy link
Collaborator

ok, if there is a different domain for backend as for frontend (e.g. for security reasons), why did you not use the frontend-domain in extension configuration?

@agendartobias
Copy link

Hey, we did. FE domain is test.sitename.si, but if u look at unsubscribe link that i posted, you see that i get /sitename/ attached to test.sitename.si domain. So i think

http://test.sitename.si/**sitename**/odjava-od-novic/?tx_luxletter_fe%5Bhash%5D=&tx_luxletter_fe%5Bnewsletter%5D=0&tx_luxletter_fe%5Buser%5D=0&cHash=6fd499e9cf90e399992a95565edf7fc8

Correct way shoud be (wihtout sitename which is used only in be editing link):

http://test.sitename.si/odjava-od-novic/?tx_luxletter_fe%5Bhash%5D=&tx_luxletter_fe%5Bnewsletter%5D=0&tx_luxletter_fe%5Buser%5D=0&cHash=6fd499e9cf90e399992a95565edf7fc8

@einpraegsam
Copy link
Collaborator

I think that this are two different problems. While @agendartobias has a folder that's wrong in his configuration, @p380 has a wrong domain? Am I right?

@p380
Copy link
Author

p380 commented May 11, 2020

I have the same as @agendartobias. A folder is inserted in the domain.

I think the problem is in the 'getTypolinkUrlFromParameter' function where the URL is generated by the domain. The function is called in viewhelper 'GetUnsubscribeUrlViewHelper'.
However, if the constant was called from luxletter for the domain there would be no problem.

@einpraegsam einpraegsam added the question Further information is requested label Sep 22, 2020
@einpraegsam
Copy link
Collaborator

The linkgeneration completely changed in luxletter 4.0 and is now based on the siteconfiguration. This problem should be fixed now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants