Sign in on homepage? Sign in on homepage?
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Sign in on homepage?

Started by Mez, May 25, 2007, 11:09:51 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Mez

Hi guys.
Is it possible for me to put a username/password login for the my galley on my homepage? when they are signed in it obviously takes them to the gallery...not sure the best way to go about it though.
Any help is great.
James

Mez

Anyone?
I have searched the forums but there only seems to be posts relevant to loggig in from another coppermine gallery page, not one that is nothing to do with it, ie my homepage..
James :)

Joachim Müller

So you want a login form on a non-coppermine driven page? The problem is that the non-coppermine page doesn't "know" wether a user is already logged in or not. However, if you don't care about that, just copy the html output of coppermine's login page (the stuff starting from <form...> untill </form>) into your non-coppermine page and you're done. Has been asked and answered before, search the board for detailed instructions.

Mez

I have searched the forums, i got the post i think you are talking about? you answered it, but i think that was a coppermine page?
Anyhoo, i searched login.php for the form and cant find it, neither can i on index.php?
Thanks again,
James

Joachim Müller

I suggested looking at the HTML output. Use the code snippet below and modify it as you see fit:<form action="login.php?referer=foobar.htm" method="post" name="loginbox">
  <table align="center" width="600" cellspacing="1" cellpadding="0" class="maintable">
    <tr>
      <td class="tableh1" colspan="2">Enter your username and password to login</td>
    </tr>
    <tr>
      <td class="tableb" width="40%">Username</td>
      <td class="tableb" width="60%"><input type="text" class="textinput" name="username" style="width: 100%" tabindex="1" /></td>
    </tr>
    <tr>
      <td class="tableb">Password</td>
      <td class="tableb"><input type="password" class="textinput" name="password" style="width: 100%" tabindex="2" /></td>
    </tr>
    <tr>
      <td colspan="2" align="center" class="tableb">Remember me <input name="remember_me" type="checkbox" class="checkbox" value="1" tabindex="3" /></td>
    </tr>
    <tr>
      <td align="center" class="tablef"><a href="forgot_passwd.php" class="topmenu">I forgot my password</a></td>
      <td align="left" class="tablef"><input name="submitted" type="submit" class="button" value="Login" tabindex="4" /></td>
    </tr>
  </table>
</form>
<script language="javascript" type="text/javascript">
<!--
document.loginbox.username.focus();
-->
</script>


Lines that need changing:<form action="login.php?referer=foobar.htm" method="post" name="loginbox">and<td align="center" class="tablef"><a href="forgot_passwd.php" class="topmenu">I forgot my password</a></td>

Not related to bridging, moving accordingly.