I am trying to create a link in a Drupal views-view-fields.tpl that links to the original content but for some reason it's not working. The code I have tried:
<a href="<?php $fields['path']->content; ?>">Read more</a>
<?php $link = $fields['path']->content;?> <a href="<?php $link ?>"> Read more</a>
as well as adding single quotes. The above points the rendered link to the current page/ view. When I echo $link_path i get /?q=node/1544 , which is correct.
I have also tried to create the URL by using
$link = $GLOBALS['base_url'] . '/node/' . $node->nid; <a href="<?php $link ?>"> more </a>
The above shows the correct link when I echo it but, again in the rendered link it points to the current page/ drupal view.
What am I missing? I have to add that I only have about 3 months Drupal/PHP experience so still lots to learn.