<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.1-alpha-2475" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
		>
	<channel>
		<title>Post Topic &#187; Topic: PHP Login Script</title>
		<link>http://posttopic.com/topic/php-login-script</link>
		<description>Open For Discussion</description>
		<language>en-US</language>
		<pubDate>Sat, 31 Jul 2010 15:29:44 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.1-alpha-2475</generator>
				<atom:link href="http://posttopic.com/rss/topic/php-login-script" rel="self" type="application/rss+xml" />

		<item>
			<title>gibsongk55 on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-233</link>
			<pubDate>Fri, 15 Jan 2010 15:02:59 +0000</pubDate>
			<dc:creator>gibsongk55</dc:creator>
			<guid isPermaLink="false">233@http://posttopic.com/</guid>
			<description><![CDATA[<p>Hi</p>
<p>Just installed the script.  I receive an email that a new user signed up.  But the activation email is never received.  Tried it many times.  I don't see anymore in your config or setup to provide a path for the send mail or whatever function you use.</p>
<p>Thanks,</p>
<p>Gibs
</p>]]></description>
					</item>
		<item>
			<title>gibsongk55 on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-232</link>
			<pubDate>Thu, 14 Jan 2010 08:53:08 +0000</pubDate>
			<dc:creator>gibsongk55</dc:creator>
			<guid isPermaLink="false">232@http://posttopic.com/</guid>
			<description><![CDATA[<p>What about databases?  Do you suggest using a separate database for login and passwords or combine it with the sites database just different tables?</p>
<p>Thanks,</p>
<p>Gibs
</p>]]></description>
					</item>
		<item>
			<title>Chad Smith on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-123</link>
			<pubDate>Sun, 02 Aug 2009 09:05:04 +0000</pubDate>
			<dc:creator>Chad Smith</dc:creator>
			<guid isPermaLink="false">123@http://posttopic.com/</guid>
			<description><![CDATA[<p>The example HTML files were hardcoded to /style.css and so on, which goes back to the root directory rather than a subfolder.  You will have to remove the / if you use it in a subdirectory.</p>
<p>As for the .htaccess file, Apache and mod_rewrite are required to run the script as is.</p>
<p>If you are on a Linux shared hosting account (that's what I use) it will work just fine. Otherwise if you are on GoDaddy's Windows hosting, you will have to change the activation page in the config from /activate to index.php?activate=
</p>]]></description>
					</item>
		<item>
			<title>macCesar on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-122</link>
			<pubDate>Fri, 31 Jul 2009 01:49:53 +0000</pubDate>
			<dc:creator>macCesar</dc:creator>
			<guid isPermaLink="false">122@http://posttopic.com/</guid>
			<description><![CDATA[<p>The only way to activate the account was by manually putting " .php?activate= " between the name of the page (activate) and the activation key, replacing the / symbol.</p>
<p>That means that my server configuration is wrong to handle URLs???</p>
<p>I don't have access to the file .htaccess, well I don't know!!!!.. I'm hosting my pages on GoDaddy Shared Servers.
</p>]]></description>
					</item>
		<item>
			<title>macCesar on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-121</link>
			<pubDate>Fri, 31 Jul 2009 01:21:40 +0000</pubDate>
			<dc:creator>macCesar</dc:creator>
			<guid isPermaLink="false">121@http://posttopic.com/</guid>
			<description><![CDATA[<p>Hi there, very nice and useful script!!!</p>
<p>But I'm having problems with the Change Password example.  &lt;img src=&quot;http://posttopic.com/my-plugins/pb--bb-smilies/default/icon_sad.gif&quot; title=&quot;:(&quot; class=&quot;bb_smilies&quot; /&gt; </p>
<p>I've received the email with the 'instructions' to change the password, but if I click the link to change it, the 'change' page comes up asking me again for the user but the form is plain with no css formating, and no way to change any password.</p>
<p>the link is something like this:</p>
<p><a href="http://www.myowndomain.com/example/change/6596b5851eb88b8d735eaaf5be88eb9c" rel="nofollow">http://www.myowndomain.com/example/change/6596b5851eb88b8d735eaaf5be88eb9c</a></p>
<p>Also...There is no 'activate' sample... So What do I need to do to activate the account???</p>
<p>I've created the page with a call to the activate() function, but the account is not activated!!!!!</p>
<p>Thanks!!!!! and sorry for my english.  &lt;img src=&quot;http://posttopic.com/my-plugins/pb--bb-smilies/default/icon_sad.gif&quot; title=&quot;:(&quot; class=&quot;bb_smilies&quot; /&gt; 
</p>]]></description>
					</item>
		<item>
			<title>Chad Smith on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-100</link>
			<pubDate>Fri, 05 Jun 2009 18:30:09 +0000</pubDate>
			<dc:creator>Chad Smith</dc:creator>
			<guid isPermaLink="false">100@http://posttopic.com/</guid>
			<description><![CDATA[<p>Most likely your IP is changing.  It does the same thing when I'm on my laptop and go from work to home.  The script does that to make sure the remember me session isn't hijacked.
</p>]]></description>
					</item>
		<item>
			<title>jurry on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-99</link>
			<pubDate>Fri, 05 Jun 2009 16:00:47 +0000</pubDate>
			<dc:creator>jurry</dc:creator>
			<guid isPermaLink="false">99@http://posttopic.com/</guid>
			<description><![CDATA[<p>Hi there, thanks for the nice script.<br />
There is only 1 problem i'm struggling with.<br />
When i log in with the &#34;remember&#34; button, sometimes it's loggod out by itsself.<br />
At line 120 i've replaced the line in &#34;setcookie($config['site']['remember'],time()+12604800);&#34; but sometimes it stay logged in for 1 day and another day it stay's for 3 days.
</p>]]></description>
					</item>
		<item>
			<title>Chad Smith on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-90</link>
			<pubDate>Thu, 30 Apr 2009 10:26:52 +0000</pubDate>
			<dc:creator>Chad Smith</dc:creator>
			<guid isPermaLink="false">90@http://posttopic.com/</guid>
			<description><![CDATA[<p>The MySQL version of the script was just uploaded which includes a near complete rewrite, a templating system for notification e-mails and the login forms, enhanced plugin capabilities, &#34;remember me&#34; functionality, usermeta for custom plugins and profiles, and a whole bunch of other things I can't remember right now.</p>
<p><strong>New in Build 20090430000000</strong></p>
<ul>
<li>Initial MySQL release</li>
<li>Code rewrite</li>
<li>Added template system for e-mails and forms</li>
<li>Enhanced plugin capabilities</li>
</ul>
<p><code></code><br />
Documentation on the changes and plugin system will be added over the next few days. You can see the script in action on <a href="http://nocart.com/">nocart.com</a>, <a href="http://imagepng.com/">imagepng.com</a>, <a href="http://nsfw.it/">nsfw.it</a>, and a very large client project I am about to complete.
</p>]]></description>
					</item>
		<item>
			<title>martin on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-85</link>
			<pubDate>Wed, 15 Apr 2009 21:12:05 +0000</pubDate>
			<dc:creator>martin</dc:creator>
			<guid isPermaLink="false">85@http://posttopic.com/</guid>
			<description><![CDATA[<p>it's also considerate to put focus on the login form on load:</p>
<p>you have to add name=&#34;loginform&#34; to the 2nd line of the login_form() function</p>
<p>&#34;\t\t&#34;.'&#60;script language=&#34;JavaScript&#34;&#62;'.&#34;\n&#34;.<br />
&#34;\t\t&#34;.'document.loginform.name.focus();'.&#34;\n&#34;.<br />
&#34;\t\t&#34;.'&#60;/script&#62;'.&#34;\n&#34;;
</p>]]></description>
					</item>
		<item>
			<title>martin on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-84</link>
			<pubDate>Wed, 15 Apr 2009 20:19:08 +0000</pubDate>
			<dc:creator>martin</dc:creator>
			<guid isPermaLink="false">84@http://posttopic.com/</guid>
			<description><![CDATA[<p>Chad, thanks</p>
<p>I needed the additional code, and I am removing the email changing as well. I also added a field to users table for last login, and I might add another for IP address recording. otherwise thanks for the code.
</p>]]></description>
					</item>
		<item>
			<title>Chad Smith on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-83</link>
			<pubDate>Wed, 15 Apr 2009 09:14:58 +0000</pubDate>
			<dc:creator>Chad Smith</dc:creator>
			<guid isPermaLink="false">83@http://posttopic.com/</guid>
			<description><![CDATA[<p>Sorry Martin, it appears the OpenID plugin I use isn't working properly.  I am hoping bbPress releases an update soon.</p>
<p>The initial version of the login script was set to check for duplicate e-mails, but removed it after running into an issue where it still allowed you to change your e-mail, register and activate a new account using the same one, and then confirm the e-mail on the first account.</p>
<p>I debated for a while adding additional checks in the code, but essentially it came down to either removing it or creating an entirely new system where forgotten or unactivated accounts are automatically removed.</p>
<p>I will be packaging up the MySQL version for release when I get the chance. It still has the URL issues in the CSS, but fixes it where the database is locked on certain actions (when using plugins) and when write access is not allowed to the folder.
</p>]]></description>
					</item>
		<item>
			<title>martin on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-81</link>
			<pubDate>Tue, 14 Apr 2009 04:24:00 +0000</pubDate>
			<dc:creator>martin</dc:creator>
			<guid isPermaLink="false">81@http://posttopic.com/</guid>
			<description><![CDATA[<p>wow took me too much effort to sign in here (openID didn't work, registering everywhere sucks)</p>
<p>anyways:</p>
<p>2 things:<br />
you might want to add that you need to make sure that the directory containing the users.db file is writable; even if the file is writable, PDO will complain that it can't open the database if the directory is not writable</p>
<p>you didn't have any checks for people making duplicate accounts: </p>
<p>   $q=$db-&#62;prepare(&#34;SELECT id FROM users WHERE email=?&#34;);<br />
                $q-&#62;execute(array($email));<br />
                if ($q-&#62;fetchColumn()!=0)<br />
                        $this-&#62;fail(&#34;There is already an account registered to &#34;.$email);</p>
<p>if you put that in signup function wherever you want it will keep people from registering for multiple accounts with the same email address;</p>
<p>you also might want to change the php files so they don't have absolute addresses; I was not in the root folder of my site and had to fix it so css pointed to &#34;./&#34; instead of &#34;/&#34; just a small thing
</p>]]></description>
					</item>
		<item>
			<title>sull on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-78</link>
			<pubDate>Thu, 09 Apr 2009 21:36:58 +0000</pubDate>
			<dc:creator>sull</dc:creator>
			<guid isPermaLink="false">78@http://posttopic.com/</guid>
			<description><![CDATA[<p>i'd like to try out the latest mysql version.  is their an url avail? thanks.
</p>]]></description>
					</item>
		<item>
			<title>Chad Smith on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-20</link>
			<pubDate>Mon, 09 Mar 2009 22:03:29 +0000</pubDate>
			<dc:creator>Chad Smith</dc:creator>
			<guid isPermaLink="false">20@http://posttopic.com/</guid>
			<description><![CDATA[<p>A trial of the remember me feature has been added to the script currently running on <a href="http://phpmylogin.com">phpMyLogin</a>. I am hoping to release the MySQL version and an update to the SQLite version later this week.
</p>]]></description>
					</item>
		<item>
			<title>Chad Smith on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-19</link>
			<pubDate>Wed, 04 Mar 2009 03:39:37 +0000</pubDate>
			<dc:creator>Chad Smith</dc:creator>
			<guid isPermaLink="false">19@http://posttopic.com/</guid>
			<description><![CDATA[<p>I am just about finished with the MySQL version of the script, but need a few people to test it. Check it out on <a href="http://phpmylogin.com/">phpMyLogin</a> if you are interested.
</p>]]></description>
					</item>
		<item>
			<title>rizzy on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-16</link>
			<pubDate>Wed, 04 Feb 2009 01:57:30 +0000</pubDate>
			<dc:creator>rizzy</dc:creator>
			<guid isPermaLink="false">16@http://posttopic.com/</guid>
			<description><![CDATA[<p>That is what I thought. I probably won't mess with it at all because of those security reasons. Thanks for the response. I look forward to the future updates to your class.
</p>]]></description>
					</item>
		<item>
			<title>Chad Smith on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-15</link>
			<pubDate>Tue, 03 Feb 2009 21:28:10 +0000</pubDate>
			<dc:creator>Chad Smith</dc:creator>
			<guid isPermaLink="false">15@http://posttopic.com/</guid>
			<description><![CDATA[<p>I plan on adding it to a future version, but I'm not sure when. &#34;Remember Me&#34; sessions tend to be easy to hijack and need a little extra security which is why it was not included in this version.
</p>]]></description>
					</item>
		<item>
			<title>rizzy on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-14</link>
			<pubDate>Tue, 03 Feb 2009 20:28:33 +0000</pubDate>
			<dc:creator>rizzy</dc:creator>
			<guid isPermaLink="false">14@http://posttopic.com/</guid>
			<description><![CDATA[<p>Will a future version have a &#34;remember me&#34; feature when logging in? </p>
<p>If not I am going to try and hack at the code to see if I can get it. If you are going to have a feature like this I am just going to wait because I know your implementation of it will be a lot better than what I can come up with.
</p>]]></description>
					</item>
		<item>
			<title>Chad Smith on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-9</link>
			<pubDate>Thu, 08 Jan 2009 04:55:41 +0000</pubDate>
			<dc:creator>Chad Smith</dc:creator>
			<guid isPermaLink="false">9@http://posttopic.com/</guid>
			<description><![CDATA[<p>The script just received it's first update which includes additional features.</p>
<p><strong>New in Build 20090107211851</strong></p>
<ul>
<li>The name of the session cookie can now be customized (was PHPSESSID)</li>
<li>Added action hooks to enable basic plugin capabilities and callbacks when an action takes place</li>
</ul>
<p><code></code><br />
Most people probably have no idea what either of these are, but they are fairly important to the future of the script.</p>
<p>The user session now has a distinct name, which separates it from other scripts on your server and customizes the cookie name, just in case anyone should look at what you called it.</p>
<p>Action hooks are something Wordpress uses to allow plugins and filters to fire when a particular action takes place, such as a new blog post, comment, or pingback.  On this script they do the same thing, but fire when a user registers, logs in, and logs out.</p>
<p>Additional hooks can be added manually for now, and eventually will be set to register when a file is placed in the plugin folder.
</p>]]></description>
					</item>
		<item>
			<title>Chad Smith on "PHP Login Script"</title>
			<link>http://posttopic.com/topic/php-login-script#post-8</link>
			<pubDate>Wed, 07 Jan 2009 02:23:08 +0000</pubDate>
			<dc:creator>Chad Smith</dc:creator>
			<guid isPermaLink="false">8@http://posttopic.com/</guid>
			<description><![CDATA[<p><strong>phpMyLogin</strong></p>
<p>Several sites I made required some kind of authentication using PHP, but since the sites were entirely custom coded - and needed to be to serve their purpose - I was unable to use a CMS just to have user registration and sign-ins.</p>
<p>The <a href="http://phpmylogin.com/download">enclosed code</a> is a PHP script I came up with to enable secure logins on any site it's dropped into. Some configuration is required, but as you will see, it's fast, secure, easy to set up, and most of all gets the job done.</p>
<p>This version uses MySQL to read and write user information. If you ask nicely, I might add the same functionality back into the initial SQLite version.</p>
<p><strong>Requirements</strong><br />
<pre><code>- PHP5+
- MySQL Database
- Apache
    - mod_rewrite enabled</code></pre>
<p>View the README file (it's in the zip) for instructions on installing and configuring the script for your site.</p>
<p><strong>Contents</strong></p>
<pre><code>example
    .htaccess - .htaccess file (place in root or add contents to your own)
    auth.php - example page that requires authentication
    change.php - example change/recover password page
    index.php - example index page
    login.css - example stylesheet (place in root or add to your own stylesheet)
    login.php - example login page
    manage.php - example change email page (requires authentication)
    signup.php - example registration page
root
    config.php - configuration file
    includes
        templates
            email
                activation.php - activation/welcome e-mail sent to new users
                change-password.php - change password e-mail sent to users
                html-dtd.php - valid xhtml 1.0 for html e-mails (can be modified
                to effect all emails)
                login-notification.php - user login notification sent to the site admin
                signup-notification.php - new user notification sent to the site admin
            forms
                change-email.php - the change e-mail form
                change-password.php - the new password form (used after e-mail link is
                clicked)
                login.php - the login form
                recover-password.php - the password recovery form
                signup.php - exactly what you think it is
    common.php - common functions, edit this code first
    db.functions.php - the database class, standalone at ezdb.org
    extend.php - set of plugin &#38; notification functions, edit this code second
    functions.php - the main functions for the login system
    plugin.functions.php - functions for action handling and plugins (borrowed from
    wordpress)
CHANGELOG - list of version changes
COPYING - license details
README - the thing you&#39;re reading</code></pre>
<p><strong>Features</strong></p>
<ul>
<li>Authentication using PHP and MySQL</li>
<li>Expiring nonces to deter spam and session hijacking</li>
<li>Salted passwords and sessions</li>
<li>Secured against SQL Injection</li>
<li>Built in change password, e-mail address, &#38; password recovery</li>
<li>Account activation &#38; user registration notification</li>
<li>User meta for profiles or additional data</li>
<li>Extendable using plugins</li>
<li>Easily integrates into other services</li>
<li>Easy to use templating system for customizing forms and e-mails</li>
<li>Valid XHTML 1.0 Strict</li>
</ul>
<p><code></code><br />
<strong><a href="http://phpmylogin.com/">Demo</a></strong></p>
<p><strong><a href="http://phpmylogin.com/download">Download</a></strong></p>
<p><strong><a href="http://phpmylogin.com/donate">Donate</a></strong></p>
<p><strong>Summary</strong></p>
<p>I initially wrote my own login script so I could fix all the bugs and security flaws of the scripts that already exist, and so there would be something that can easily be extended using plugins.</p>
<p>If you find any bugs or have any questions, let me know.  The next things I am working on for this include plugns for profiles and analytics, and OAuth and OpenID versions. The script as is provides a secure system of login, registration, and account management.
</p>]]></description>
					</item>

	</channel>
</rss>
