I built a calendar based on two different content type, let's call them A and B. For each type I output the Title field and, along with it, I'd like to have a link to the node if the Title field belongs to type A and just plain text if it belongs to type B. Is there a way to do this?

1 Answer 1


You could use the Views PHP module.

Then add the content type to the view. You can exclude both content type and title from the the view only display the title through the Global PHP field. With in that you can place a condition to display the complete link if it is of Type A and only the Title if it is of Type B. You could also add the path to the node as a views fields if you prefer so that it can be used in the as href for the link in php field.

  • Thank you very much, I managed to make it work with your method. I'm gonna wait to mark it as answer for one day in case someone else shows up with a "cleaner" solution. Thank you again!
    – Geeo
    Commented Jan 27, 2013 at 22:23

Your Answer

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

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