0

I like using Rules and am trying to create a page redirect, for a certain content type i’ve created. So instead of the user viewing the node, they get redirected to an external website. the site address get’s input via a simple text field in the content type i’ve created. i’ve tried different setting for this field, plain text, full html.

In the action part of the Rule i’v set as System/Page Redirect and the value as [node:field_ext_link_text]. But it’s doing something to the URL (decoding or encoding??) and instead say going to www.somewebsite.com, i get a page not found that reads

"/%3Cp%3E%3Ca%20href%3D%22http%3A//www.somewebsite.com%22%3Ewww.somewebsite.com%3C/a%3E%3C/p%3E%0A" could not be found.

i really don’t understand what it’s doing to this URL.

i also installed the link module and tried using a field type link but got similar results. i've also tried ommitting http://,

i also tried using Rabbit Hole module to accomplish the same thing, but got similar results.

Any help would be greatly appreciated. … have spent way to much time on this…(!)

0

1 Answer 1

1

Use the field redirection module. A great overview was provided by llulabot

https://www.lullabot.com/blog/article/module-monday-field-redirection

Mind you I've used Views with Conditional Fields to allow a single link to be either internal or external using a views template override when clicked (based on a radio button in the content type). Field redirection is easier to use than your custom solution.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.