Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By mxd on
I was wondering if there is any quick way to obtain information from the optional registration field without having to code an entire PHP Application.
Comments
Could you please be a little
Could you please be a little more informative for the dense people like me? :)
works at bekandloz | plays at technonaturalist
I apologize. However when I
I apologize. However when I set up my site I made the user submit a bunch of additional information, using the Profile module. Now I am wondering if there is any simple way I could use that information in a node. For example the user had to submit their real name. The node would say "Welcome Some Name". I was wondering if there is any easy way to obtain that information without having to code an entire page of PHP. Like when inserting a username you insert (whatever it actually is) and it displays the Username. I was wondering if I could do the same. For example and it would display "Field Contents".
Mario Dell'Osso
m.dellosso@yahoo.ca
Getting variables isn't that
Getting variables isn't that hard.
echo $user->name;
gives you the username andecho $user->profile_realname;
or whatever you called your realname field, that will spit out the real name, etc.Am I completely off the bat here? :)
If you were looking for something drag'n'drop like, thre might be a project somewhere that allows you to do stuff like that, I've been okay with coding so never really looked into it.
works at bekandloz | plays at technonaturalist
profile_realname
i'm having this exact same issue, and tried this solution, however it is not displaying the information from the profile_realname field
What are you trying to do? I
Sorry I was running under the assumpion you were making custom profiles. If you're using D5 try adding global $user; somewhere at the top of the page. I know it works for a block but not so certain for a node :|
works at bekandloz | plays at technonaturalist
subscribing
lets see what others say :)
subscribing
looking forward to it