Closed (fixed)
Project:
Link
Version:
6.x-2.5
Component:
Miscellaneous
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
14 Apr 2009 at 15:16 UTC
Updated:
17 Apr 2009 at 18:27 UTC
I want to display the raw URL of my link field in my custom node.tpl.php.
I'm using this code but the URL it displays is that of the node and not what's in the field: print $node->content['field_download']['#value']; ">
Comments
Comment #1
DrupalKing commentedAnyone? Again, I just want to know how to manually output the raw URL in my node.tpl.php
Comment #2
jcfiala commentedGenerally to get this sort of thing to display, you really just want to do a print on your $node and see how things are stored - often that's faster than asking for help here.
I don't remember the answer off of the top of my head, so I'll get back to you later, but
print_r($node)ordpm($node)would probably be the fastest way to find it.Comment #3
DrupalKing commentedI figured it out, so hopefully this helps someone:
print $node->field_download[0]['display_url']; ">
Comment #4
DrupalKing commentedComment #5
911 commentedI have a node-mynodetype.tpl.php file and want to render the raw url of my link cck field. I tried this the whole day, but I cant get it to work.
I tried the code you post and I dont get it work too.
Nothing works. The name of my cck field is link.
What am I doing wrong?
[EDIT]
Think I got it, it was related to drupals caching.
admin/settings/performance
clearing cache did it..