coppermine-gallery.com/forum

Support => cpg1.4.x Support => Older/other versions => cpg1.4 miscellaneous => Topic started by: SimonH on March 15, 2009, 09:08:20 PM

Title: How do I edit the login page?
Post by: SimonH on March 15, 2009, 09:08:20 PM
I want to place a message on the login page, which will say something like in order to view images you will need to register...

how do I do this please?
Title: Re: How do I edit the login page?
Post by: chzuqi on March 16, 2009, 10:12:41 AM
pageheader($lang_login_php['login']);
$referer = urlencode($referer);


put your code here

echo '<form action="login.php?referer='.$referer.'" method="post" name="loginbox">';
Title: Re: How do I edit the login page?
Post by: SimonH on March 16, 2009, 05:05:05 PM
Do i need to enter code or can I just put my message there?
Title: Re: How do I edit the login page?
Post by: Joachim Müller on March 17, 2009, 09:09:47 AM
Edit login.php, findpageheader($lang_login_php['login']);
$referer = urlencode($referer);
echo '<form action="login.php?referer='.$referer.'" method="post" name="loginbox">';
and replace withpageheader($lang_login_php['login']);
[tt]?>[/tt]
Your custom text goes here
<?php
$referer 
urlencode($referer);
echo 
'<form action="login.php?referer='.$referer.'" method="post" name="loginbox">';
You can replace Your custom text goes herein that example with just text or HTML. No need to write PHP code there, as the line ?> is actually a command that means "parsing of PHP will stop, plain HTML will be read. The line <?php turns the PHP mode back on.

Alternatively, you could replacepageheader($lang_login_php['login']);
$referer = urlencode($referer);
echo '<form action="login.php?referer='.$referer.'" method="post" name="loginbox">';
withpageheader($lang_login_php['login']);
$referer = urlencode($referer);
echo 'Your message here';
echo '<form action="login.php?referer='.$referer.'" method="post" name="loginbox">';
, which would mean that you wouldn't be ending and restarting PHP-processing - your message would be written on the login page using PHP's command "echo".

Either way, I don't think that it's really necessary to write on the login page that you have to register first - that should be pretty self-explanatory, as this is the case on all sites that require authentification. In my opinion, your site visitors will know that they need to register first before they can log in.