Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

On signup, handleSignUp.php doesn't redirect anywhere, just has a blank screen. #1

Closed
Aerospace35 opened this issue May 11, 2021 · 10 comments

Comments

@Aerospace35
Copy link

Aerospace35 commented May 11, 2021

I found some inconsistencies with the spelling of "Validator" and "validation" and also in Validator.php "Requireimage.php" was different than the actual filename

@Aerospace35
Copy link
Author

2021-05-11-082018_1440x900_scrot

aminyasser added a commit that referenced this issue May 12, 2021
@aminyasser
Copy link
Owner

Hey there!
Thank you for opening this issue, the problem was in my xampp localhost environment is not case sensitive with file names.
I change it right now you can try again and tell me if everything works fine.
Also, i change the validation file spelling mistake.

@Aerospace35
Copy link
Author

That was quick! Thanks for the update. Unfortunately, based on my diagnostics and testing, the handleSignUp.php still fails, leading to the white screen. I probably have an issue with my configuration or my mySQL settings, somewhere. If you have any other ideas I'd be happy to try them!

Have a nice day.

@aminyasser
Copy link
Owner

aminyasser commented May 12, 2021

I am using XAMPP environment and unfortunately and not familiar with other environments.
Can you try adding this to the .httaccses file.

php_value display_errors 1

i think it will show the specific error happen with you but i am not sure.

@Aerospace35
Copy link
Author

The error finding worked! Does this help in any way?

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 1364 Field 'following' doesn't have a default value in /var/www/html/Social/Chitter2/core/classes/User.php:66 Stack trace: #0 /var/www/html/Social/Chitter2/core/classes/User.php(66): PDOStatement->execute() #1 /var/www/html/Social/Chitter2/handle/handleSignUp.php(43): User::register('brodiefriesen77...', '653c6617e0399aa...', 'Brodie Friesen', 'brodiefriesen') #2 {main} thrown in /var/www/html/Social/Chitter2/core/classes/User.php on line 66

@aminyasser
Copy link
Owner

aminyasser commented May 12, 2021

Yes, it helps.
The problem was i add following/followers fields when development and don't use it. my XMAPP environment assume the default value of this fields is 0.
I think other environments must make default values.
I commit a new SQL file to solve this error.
If you don't want to delete DB and import new
Just type this in your SQL

ALTER TABLE `users`
  DROP `following`,
  DROP `followers`;  

I hope this solve the problem.

@Aerospace35
Copy link
Author

It solved that one, but revealed another…
Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 1364 Field 'bio' doesn't have a default value in /var/www/html/Social/Chitter2/core/classes/User.php:66 Stack trace: #0 /var/www/html/Social/Chitter2/core/classes/User.php(66): PDOStatement->execute() #1 /var/www/html/Social/Chitter2/handle/handleSignUp.php(43): User::register('brodiefriesen77...', '36366b49b73cc1e...', 'Brodie Friesen', 'Brodiefriesen') #2 {main} thrown in /var/www/html/Social/Chitter2/core/classes/User.php on line 66

I will poke around and see if there is a solution online rather than bother you!

@aminyasser
Copy link
Owner

Don't worry. you aren't bother me.
Sorry for late i just saw the comment now.
It's the same default type problem but in another way, thank you for notifying me.
I will commit changes in SQL file. and you can type this in your SQL.

ALTER TABLE `users` 
CHANGE `bio` `bio` VARCHAR(140) CHARACTER SET utf16 COLLATE utf16_unicode_ci NOT NULL DEFAULT '', 
CHANGE `location` `location` VARCHAR(255) CHARACTER SET utf16 COLLATE utf16_unicode_ci NOT NULL DEFAULT '',
CHANGE `website` `website` VARCHAR(255) CHARACTER SET utf16 COLLATE utf16_unicode_ci NOT NULL DEFAULT ''; 

I hope everything work fine.

@aminyasser
Copy link
Owner

I commit a new change in ajax files also check it before trying.
because it will make ajax buttons don't work in other environments. it was just a file path error.
so, pull the recent changes or download the project again and try.
i think it will work fine.

@Aerospace35
Copy link
Author

It worked!! Thank you so much, this is awesome. Have a great day, and thanks again! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants