coppermine-gallery.com/forum

Support => cpg1.4.x Support => Older/other versions => cpg1.4 miscellaneous => Topic started by: OzButcher on February 15, 2007, 06:20:39 AM

Title: need "register" link for private gallery on main page
Post by: OzButcher on February 15, 2007, 06:20:39 AM
I am running a private gallery for friends, family and relatives. Because its set to private the main page loads asking for login details but there is no 'Register Here' link under it where it would be easy to see.

I have a small register link in my menus but some of my family aren't very good with computers and probably wont be able to find it. Could someone please show me how to put a text link in this place... screen shot:

(https://coppermine-gallery.com/forum/proxy.php?request=http%3A%2F%2Fburnt-clan.com%2Fimages%2Fregister.jpg&hash=fe9c00f417666cf9acaf8152dae970adbdd46f66)
Title: Re: need "register" link for private gallery on main page
Post by: Joachim Müller on February 15, 2007, 07:28:35 AM
Edit login.php, findpageheader($lang_login_php['login']);
$referer = urlencode($referer);
echo '<form action="login.php?referer='.$referer.'" method="post" name="loginbox">';

starttable('-1', $lang_login_php['enter_login_pswd'], 2);
echo <<< EOT
                  $login_failed
                  $cookie_warning
                  <tr>
                        <td class="tableb" width="40%">{$lang_login_php['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">{$lang_login_php['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">{$lang_login_php['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">{$lang_login_php['forgot_password_link']}</a></td>
                    <td align="left" class="tablef"><input name="submitted" type="submit" class="button" value="{$lang_login_php['login']}" tabindex="4" /></td>
                  </tr>

EOT;
and add your custom link into a new line beforeEOT;, e.g.                  <tr>
                    <td align="center" class="tablef" colspan="2"><a href="register.php">Register</a></td>
                  </tr>
Title: Re: need "register" link for private gallery on main page
Post by: OzButcher on February 15, 2007, 10:22:53 AM
That works like a charm! Thanks :)
Title: Re: need "register" link for private gallery on main page
Post by: SmithsMedia on January 30, 2008, 11:48:45 AM
I am having a simialr issue i can not seem to give people the option to register the system just advises them 'You do not have permission to access this page'

Have traided adding this link though still the same error will go see what I need to do re the private settings though I am sure the site is public :(
Title: Re: need "register" link for private gallery on main page
Post by: Nibbler on January 30, 2008, 12:38:56 PM
You need to enable registration in config.