Jump to content

LoginRegister module question


Mijo
 Share

Recommended Posts

Hello all, this is the first time I try to implement login or registration in PW, I use the LoginRegister Module. When i try to register (new user) I have a registration form, I fill my information and then I need to enter confirmation code,  but this code did not come to my email and here is my question? What is the next step that I need to do?How to set up a PW so that he can send e-mails?

Thank you

screen.png

Link to comment
Share on other sites

Hi,

  1. Double check that you are not sending the email to a domain out of your control.
  2. Double check your SPAM folder
  3. If you use a Google account, you have to disable a security option on your account
  4. Read this thread and get back to us 

 

  • Like 2
Link to comment
Share on other sites

  • 1 month later...

Hi @flydev,

Is it possible update the user data form other form? I mean, user make the registration with one form, that in the website there are other interaction, like the checkout form, is it possible with this checkout form integrate or update the user information ?

So, I think first I need add all the field in the user page, in the way  there are a place for put the data, but for to populate these fields how I do?

 

Link to comment
Share on other sites

Hi marco,

to populate the profile, just set and save the user information page, eg :

if($input->post->checkout_submit) { // the checkout form submit action
    //instantiate variables taking in the form data
    $cart = $sanitizer->text($input->post->cart);
    // set other profile var...
    // update user details
    $user->of(false);
    $user->cart = $cart; // update the "cart" field
    $user->save();
    $user->of(true);
}

As you said, you will need to add the fields to the user profile.

  • Like 1
Link to comment
Share on other sites

Thank you @flydev!

is it right do this:

if($input->post->customerForm) { // It's the button ID, right?

	//instantiate variables taking in the form data
	// set other profile var...
	$invoice_CF = $sanitizer->text($input->post->Inputfield_invoice_CF);
		
	// update user details
	$user->of(false);
	$user->Inputfield_profile_invoice_CF = $invoice_CF; // is it correct? or use the field name?
	$user->save();
	$user->of(true);
}

but, can I serialize all the data using the from ID and then update the user filed? or I need set all the variables ? (are not a lot I can do...)

I see an error like this:

at line      // update user details      syntax error, unexpected ' ' (T_STRING)

 

Link to comment
Share on other sites

2 hours ago, MarcoPLY said:

// It's the button ID, right?

Nop, you have to use the name of the button. The name attribute is used to send data.

 

2 hours ago, MarcoPLY said:

but, can I serialize all the data using the from ID and then update the user filed?

Not sure I understand, but serialize in JavaScript just take the form data and put them into a string, eg: "var1=val1&var2=val2"

If you pass your params from jQuery, then you can use this function to transform your string into "params" :  http://www.php.net/manual/en/function.parse-str.php

Otherwise In PHP you access data with $_POST, $_GET.

 

Quote

// is it correct? or use the field name?

As I said in my previous post, use the name of the field, the ProcessWire standard way..

 

2 hours ago, MarcoPLY said:

I see an error like this:

Which one ? ?

Edited by flydev
precision
  • Like 2
Link to comment
Share on other sites

  • 3 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...