How can I add a variable in a template?
3 posters
Page 1 of 1
How can I add a variable in a template?
Hello,
How can I add the username variable in index_box template. I am trying this code
but its not working. Can you help me please?
My forum version is PunBB.
How can I add the username variable in index_box template. I am trying this code
- Code:
<li id="user_content"><a href="/st/{USERNAME}" title="">Οι δημοσιεύσεις μου</a>
but its not working. Can you help me please?
My forum version is PunBB.
Last edited by Black-Shadow on October 12th 2014, 8:11 am; edited 1 time in total
Re: How can I add a variable in a template?
think you have to devide it like this
- Code:
<li id="user_content"><a href="'/st/' + '{USERNAME}'" title="">Οι δημοσιεύσεις μου</a>
Re: How can I add a variable in a template?
Hello,thetwistedkilla wrote:think you have to devide it like this
- Code:
<li id="user_content"><a href="'/st/' + '{USERNAME}'" title="">Οι δημοσιεύσεις μου</a>
Its not working it returns white page http://prntscr.com/4v73cw as you can see here now it adds the characters ' ' in url address http://prntscr.com/4v73wi normally it must goes to the link <forumurl>/st/username but its not adds the username at the end of the link.
Re: How can I add a variable in a template?
Hello Black-Shadow,
From what I recall, you cannot use this variable in the templates. You could try this :
From what I recall, you cannot use this variable in the templates. You could try this :
- Code:
<a id="search-t" href="/st/" title="">Οι δημοσιεύσεις μου</a><script type="text/javascript">$(function(){document.getElementById('search-t').href = '/st/' + _userdata.username});</script>
Re: How can I add a variable in a template?
Hello Ange,
The /spa/ is for member's replies and /st/ is for member's topics?
The /spa/ is for member's replies and /st/ is for member's topics?
Re: How can I add a variable in a template?
st = member's topics
sta = topics member has posted in
spa = member's replies
sta = topics member has posted in
spa = member's replies
Similar topics
» Change Variable Text
» Load input's content into a variable
» Variable's codes
» Variable for the Avatar
» _userdata variable modification
» Load input's content into a variable
» Variable's codes
» Variable for the Avatar
» _userdata variable modification
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum