| View previous topic :: View next topic |
| Author |
Message |
Timmy
Joined: 10 Feb 2010 Posts: 146
|
Posted: Feb 23, 2010 6:40 pm Post subject: Login box, how? |
|
|
hi friends,
can someone tell me how can I add a login box in my website header?
anyone do It already? |
|
| Back to top |
|
 |
castledracula
Joined: 24 Aug 2009 Posts: 14
|
Posted: Feb 23, 2010 11:41 pm Post subject: |
|
|
| Code: |
<TMPL_IF my_login>
<b>Welcome <TMPL_VAR my_login> - <a href="<TMPL_VAR site_url>/?op=logout" class="logout"><TMPL_VAR lang_logout></a>
<TMPL_ELSE>
<form method="POST" action="<TMPL_VAR site_url>/" name="FL">
<input type="hidden" name="op" value="login">
<input type="hidden" name="redirect" value="<TMPL_VAR redirect>">
<table>
<tr>
<td><input class="username_input" type="text" name="login" value="<TMPL_VAR login>"></td>
<td> <input class="password_input" type="password" name="password"></td>
<td><input type="submit" value="Login" /></td>
</tr>
</table>
</form>
</b>
</TMPL_IF>
|
add this code in the main.html template and edit it however you want it to be display, this code will show the login box in a horizontal line and when the user is logged in the will show the welcome "USER". |
|
| Back to top |
|
 |
Timmy
Joined: 10 Feb 2010 Posts: 146
|
Posted: Feb 24, 2010 3:18 am Post subject: |
|
|
WOW! Many thanks my friend!  |
|
| Back to top |
|
 |
Timmy
Joined: 10 Feb 2010 Posts: 146
|
Posted: Feb 24, 2010 4:14 am Post subject: |
|
|
Last favor
Can you make possible to show also the Premium-Account expire date.
Like you said appears:
| Quote: | Welcome: username
Logout |
I mean to show like that:
| Quote: | Welcome: username
Premium-Account expire: 11 February 2011
Logout |
I tried to add this code from my_account.html into main.html:
| Code: | <TMPL_IF premium>
<TMPL_VAR lang_prem_valid_until>: <b><TMPL_VAR premium_expire></b><input type="button" class="btn2" value="<TMPL_VAR lang_extend_account>" onClick="document.location='?op=payments'">
</TMPL_IF> |
But that info only appears in the My Account page ;(
Any idea how to solve that in order to appear in all pages?  |
|
| Back to top |
|
 |
Timmy
Joined: 10 Feb 2010 Posts: 146
|
Posted: Apr 08, 2010 12:27 pm Post subject: |
|
|
anyone?  |
|
| Back to top |
|
 |
admin Site Admin

Joined: 22 Mar 2006 Posts: 1127
|
Posted: Apr 12, 2010 6:08 pm Post subject: |
|
|
| Impossible without script modification. |
|
| Back to top |
|
 |
|