Login box, how?

Powerfull XFileSharing version

Moderator: admin

Message
Author
Timmy
Posts: 146
Joined: Feb 10, 2010 8:17 pm

Login box, how?

#1 Postby Timmy » Feb 23, 2010 6:40 pm

hi friends,

can someone tell me how can I add a login box in my website header? :)

anyone do It already?

castledracula
Posts: 14
Joined: Aug 24, 2009 9:51 pm

#2 Postby castledracula » Feb 23, 2010 11:41 pm

Code: Select all

<TMPL_IF my_login>
<b>Welcome &nbsp;&nbsp;<TMPL_VAR my_login> - &nbsp;&nbsp;<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>&nbsp;&nbsp;<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".

Timmy
Posts: 146
Joined: Feb 10, 2010 8:17 pm

#3 Postby Timmy » Feb 24, 2010 3:18 am

WOW! Many thanks my friend! :)

Timmy
Posts: 146
Joined: Feb 10, 2010 8:17 pm

#4 Postby Timmy » Feb 24, 2010 4:14 am

Last favor :)

Can you make possible to show also the Premium-Account expire date.

Like you said appears:
Welcome: username
Logout


I mean to show like that:

Welcome: username
Premium-Account expire: 11 February 2011
Logout


I tried to add this code from my_account.html into main.html:

Code: Select all

<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? :)

Timmy
Posts: 146
Joined: Feb 10, 2010 8:17 pm

#5 Postby Timmy » Apr 08, 2010 12:27 pm

anyone? :)

admin
Site Admin
Posts: 1784
Joined: Mar 22, 2006 12:32 pm

#6 Postby admin » Apr 12, 2010 6:08 pm

Impossible without script modification.


Return to “XFileSharing Pro”

Who is online

Users browsing this forum: No registered users and 0 guests