By halloffame on
Ok. I feel so silly asking this... but what the heck...
The node link field for views is supposed to display the link to the node. But I want to display the actual URL of the node not the link with some anchored text. Am I just missing something here or is this functionality not available at all? When I leave the 'text to display' field blank the anchor 'view' appears as a default. I want the actual URL of the node.
Comments
If you are using the Token
If you are using the Token module then you should be able to edit the field and select to modify the output. Then you can use a token to display the actual URL.
There is no token available
There is no token available for the actual URL. Only the [Title] is available and I don't know what possible manipulation we can do with that other than using it with
<a>tag (which doesn't make sense by the way because we can already link the title to its node).The '[view_node] == Node: Link' token is available though. But again it displays the anchor text not the actual URL.
Are there any other available tokens that I can use that is not being shown to me in the replacement pattern? Is that what you're trying to tell me?
I was originally thinking the
I was originally thinking the node:link would work but it sounds like that won't. I know there are actual tokens available for node URLs, but it doesn't sound like they're available in views.
Apparently they aren't.
Apparently they aren't. Thanks for trying though!
You might be able to try the
You might be able to try the Views Computed Field and write some PHP to display the URL.
Here's an issue related to
Here's an issue related to this discussion #548292: Field: Path to node
quick hack: use nid
Just ran into this same issue, one quick hack you can use instead of Node:Link is to use the Node:NID Field, exclude it from the display and build the URL with sitename.com/node/[nid]. Of course this isn't elegant, especially if you use aliased paths, but it can do the trick in a pinch.
Also just realized you can
Also just realized you can expose Node:Path if you're using aliased paths.
just use node:title ==> link
just use node:title ==> link to node :)
Hi, I'm too precious to answer right now. Please email me later.
quick hack: use nid
Hi dillonm, your suggestion really works. Much appreciated. The only thing in my case is that you have to move the nid field to the first position, using the rearrange button.
Cheers!