Larry
Administrators-
Posts
5413 -
Joined
-
Last visited
-
Days Won
155
Everything posted by Larry
-
loading html file in url
Larry replied to possowski's topic in PHP for the Web: Visual QuickStart Guide (5th Edition)
Glad it's working and thanks for letting us know! -
According to your logic: if (!isset($_POST['agent']) ) { // Print the results if Agent: echo "<p>Thank you <b>$agent</b> for your request for <b>$guest</b>.</p> <p>We will reply to you at <i>$email</i>.</p>\n"; The conditional checks if agent *is not* set. But the following comment suggests the message is printed if there is an agent. One of these two seems to be wrong.
-
Okay, that's helpful! I would click on the Apache "Logs" button to view the error logs. At the end of them there should be an error message indicating why it didn't start. It's likely it's a port issue (e.g., if you've also installed Skype). If you search Google for that, you'll come up with likely solutions, such as: https://www.geckoandfly.com/7491/xampp-apache-wont-start-change-port-to-listen-85/ And could you please turn off the caps lock? Thanks!
-
Hmm... I don't really know! I'll investigate and see if I can turn up anything (a quick search wasn't helpful).
-
I learned HTML originally from http://www.peachpit.com/store/html-and-css-visual-quickstart-guide-9780321928832 but it's 5 years old now, so that's probably not the best choice. Maybe someone else has other recommendations?
-
Your internet provider does not give you an SSL connection. You should be using the Terminal on your Mac to connect to MySQL on your Mac, so it should be okay that it's not SSL. Nothing happens. The files are all on your computer. When you go to create a website *on a hosted server*, you'll export the database from your local MAMP installation and then import it (using phpMyAdmin or whatever) on the hosted server. I'm not familiar with upgrading the MySQL database, but that error would suggest you're using the wrong password.
-
Hey Julien! So long as you're never storing anything sensitive in your local MySQL database, I don't think it's a problem to leave the password unchanged. And, if you change the root password in MySQL, you'll need to change your phpMyAdmin config, too. So that's another argument against. That being said, what you're doing wrong is not using the correct current password! According to Google searches (and I thought I said this in the book), the default root user password should be "root".
-
Okay, good. So SHA2() with a length of 512 should return a string with a length of 128, so VARCHAR(128) or VARCHAR(256) should be fine. I imagine something was just missed along the way which is why a match isn't made. I'd start by registering a new users and logging in that user. Use a simple and obvious password, like "password" (without the quotes). Or you can just run an UPDATE query, updating all the registered users to a new password of "password" (I assume this is all in a test environment with no actual users). You can also do SELECT SHA2('password', 512) in phpMyAdmin to see what that string's value should be. Then if you look at the stored passwords you could see if there's a problem such as the stored value being cut off b/c the database column is too short.
-
So it really depends upon what method is being used for encrypting and decrypting the password. You've done some great debugging in determining that the email address is fine but the password doesn't match. What code is being used to encrypt and store the password? What code is being used to fetch and check for a password match?