The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Looking for member name variable
4.1.2 full suite
Treavor over at vb com said to post this here. I found this really neat script on a site another member there mentioned in a thread. It's a javascript goody that puts a digital clock, full blown day and date, with a time of day greeting. I parked it in the Welcome to the blah blah phrase translation box and after adding a br to the welcome, it works fine. Well, it needs some apperance tweaking. http://animeappeal.com/forum.php?styleid=93 My idea is to edit the welcome to the blah blah to welcome, member. But got snagged on what to put in to call the member by screen name. Would one of you coder types please point me to what I need to add to the phrase to make it work like I want it to? Treavor also suggeted using this variable {vb:raw bbuserinfo.username} but all it does is print the var itself. How do I compose the phrase so that it shows Welcome, membername? |
#2
|
|||
|
|||
So if I understand correctly, you want to modify some javascript that currently display "Welcome to the blah blah" to display "Welcome, member" like the vbulletin welcome message? Probably what you want to do is edit a template to insert some code that defines a javascript string variable with the message you want to display. You can steal the phrase out of the header template and use something like this:
Code:
<script type="text/javascript"> var welcome_message = '{vb:rawphrase welcome_x_link_y, {vb:raw bbuserinfo.username}, {vb:link member, {vb:raw bbuserinfo}}}'; </script> then of course in the javascript you'd use welcome_message where you want the message. |
#3
|
|||
|
|||
Close but no cigar. I want to edit the built in welcome to the blah blah phrase. The JS for the clock and all is independant of that.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|