In the future, please create a separate ticket for different topics. It's easier for me to track it that way.
As for the OAuth login settings, I'm not sure if you are referring to Google or Facebook. For Facebook you should use
And for Google
Hi again. For whatever reason I can get this to work on localhost but not
on a live demo.
URL Blocked: This redirect failed because the redirect URI is not
whitelisted in the app’s Client OAuth Settings. Make sure Client and Web
OAuth Login are on and add all your app domains as Valid OAuth Redirect
What can I do to fix this? What would the Valid OAuth Redirect URIs be?
https://demo4.netwizarddesign.com.au/michael/mega-anchor/ is the demo
No problem, I'm glad it's working as expected now! :)
Thanks Milos I got it working. Nice system by the way.
The email sending configuration looks good. Are you able to send emails using these SMTP credentials from some other app or some other email client?
If you are 100% sure that everything is configured properly, can you please send me a link to your website so I can check? Make sure that you have DEBUG set to true in your ASConfig.php file.
// EMAIL SENDING CONFIGURATION
// Available MAILER options are 'mail' for php mail() and 'smtp' for using
SMTP server for sending emails
define('SMTP_ENCRYPTION', "TLS"); ///Is this right?
define('MAIL_FROM_NAME', "Mega Anchor");
What could be the problem? I am not seeing anything obvious in DEBUG.
The problem is most likely with the confirmation email, probably because your server is either not configured to send emails or, if you are using an external SMTP server, the app is unable to connect to it.
I'll recommend you to check the Developer Guide to see how you can debug AJAX requests and then use that technique to see what is wrong with the registration.
Hi Again. I am experiencing an issue. See attached. After registering the
user is added to the DB but the button just says creating account.. and
nothing happens. What could be the problem?
Thanks Milos for the detailed explanation. I will try and sort it out now.
Here is the high-level overview of what you need to do, and I will suggest you to go through the code for existing fields to see how it works:
1) You need to add the HTML for that new input field that you want to add.
The HTML for the user details form is within the profile.php file, so just edit that file and add one more text input field there. Make sure that you set the "name" attribute for it since you will use that in the next step. For our example, let's say that you added "date_of_birth" as a name attribute for this field
The file that you need to edit is "assets/js/app/profile.js" and you'll need to extend the handler for "#update_details" button click which starts on line 44. All you need to do is to add one more item into the "details" object. The key there should be the name of your database column (let's say you also named it "date_of_birth") and the value is the value for your newly added form element.
Here is an example:
date_of_birth: form['date_of_birth'].value, // <-- this is what we added
And that's really it, it will then be sent to the ASAjax.php file and trigger the "updateDetails" method from ASUser class, which will then update the data in the database.
Could you explain how I could add additional user_details fields. For example: Date of Birth. I cannot work out how to save that to the database. I have created the necessary column in the DB.
the changes you propose for "adding new fields" are not enough. Can you elaborate more and tell us what are the files that need to change ? thanx