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

caschbre’s picture

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.

halloffame’s picture

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?

caschbre’s picture

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.

halloffame’s picture

Apparently they aren't. Thanks for trying though!

caschbre’s picture

You might be able to try the Views Computed Field and write some PHP to display the URL.

ao2’s picture

Here's an issue related to this discussion #548292: Field: Path to node

dillonm’s picture

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.

dillonm’s picture

Also just realized you can expose Node:Path if you're using aliased paths.

aspilicious’s picture

just use node:title ==> link to node :)

Hi, I'm too precious to answer right now. Please email me later.

Anonymous’s picture

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!