saraelba
Forum Replies Created
-
Hello, I have the same problem: I can’t add my Instagram account and I can’t add any feeds. I linked my Instagram Business account to the plugin, but no account/feed is listed. I cleared the cookies and checked the private windows. It didn’t solve anything.
Ok…
I feel stupid ??
The issue was in Mailchimp:
The Merge Tag for country and state was set as an ADRESS field…
But, this fields must be set as a TEXT field to work properly.
At the end the code is
"BCOUNTRY" => $user->bcountry, "BSTATE" => $user->bstate,
I think I found the solution.
I’ll add a NEW MEMBER tomorrow and let you know.+++++++++++
Anyway, IM HAVING THIS ISSUE with the profile edit page:
1) At Edit member profile’s page (or WP-admin’s edit member profile) I change the country and state.
2) Click on save button
3) I see the “Profile updated” message and changes made on the page.
…and then:
4) Refresh the page.
5) Changes not saved. ??Im searching in GitHub and wordpress support forum about this issue but I cannot see anything.
Just this, but this is a STATE issue only:
https://github.com/strangerstudios/pmpro-state-dropdowns/pull/13Maybe I must open a new topic i a proper forum?
THANKS!!!- This reply was modified 3 years, 8 months ago by saraelba.
Hi David,
I had trying diffrent combinations of code and see the log file.
#1
CODE:function add_billing_fields_to_profile() { global $bcountry; global $bstate; //check for register helper if(!function_exists("pmprorh_add_registration_field")) return; //define the fields function add_billing_fields_to_profile() $fields = array(); $fields[] = new PMProRH_Field( "bcountry", "select", array('label'=>'Pais:', "options"=>array ( $bcountry ), "profile"=>true, ) ); // and same code for $bstate here function my_pmpro_mailchimp_listsubscribe_fields( $fields, $user ) { $new_fields = array( "BCOUNTRY" => $user->BCOUNTRY, "BSTATE" => $user->BSTATE, );
LOG RESULTS:
Logged On: 03/18/2021 17:36:23
Processing update for audience AUDIENCE namehere (b12d1146f5): Array
(
[0] => stdClass Object
(
[email_address] => xxxxxxxx
[status] => subscribed
[merge_fields] => Array
(
[FNAME] => Arde
[LNAME] => Ardministrador
[BADDRESS1] =>
[BZIPCODE] =>
[BCOUNTRY] =>
[BSTATE] =>
[PMPLEVELID] => 1
[PMPALLIDS] => {1}
[PMPLEVEL] => Cuota de socio anual
))
)
————-
Logged On: 03/18/2021 17:36:25
Mailchimp Response: No errors detected.
————-********************
#2
CODE:SAME code before except for:
function my_pmpro_mailchimp_listsubscribe_fields( $fields, $user ) { $new_fields = array( "BCOUNTRY" => $user->bcountry, "BSTATE" => $user->bstate, );
LOG RESULTS:
Logged On: 03/18/2021 17:20:56
Mailchimp Response: 1 error(s). Array
(
[0] => stdClass Object
(
[email_address] => [email protected]
[error] => Your merge fields were invalid.
[error_code] => ERROR_GENERIC
))
————-
***************************
#3
CODE:Same code except for:
"bcountry" => $user->BCOUNTRY, "bstate" => $user->BSTATE,
LOG RESULTS:
Logged On: 03/18/2021 17:57:52
Processing update for audience LIST audience (b12d1146f5): Array
(
[0] => stdClass Object
(
[email_address] => xxxxxxxxxx
[status] => subscribed
[merge_fields] => Array
(
[FNAME] => Arde
[LNAME] => Ardministrador
[BADDRESS1] =>
[BZIPCODE] =>
[bcountry] =>
[bstate] =>
[PMPLEVELID] => 1
[PMPALLIDS] => {1}
[PMPLEVEL] => Cuota de socio anual
))
)
————-
Logged On: 03/18/2021 17:57:53
Mailchimp Response: No errors detected.
————-`************************
ABOUT THE PROFILE UPDATE PAGE:
When I change the country and/or state, the page shows the “profile update” message. But when I refresh the page the changes are not saved. (same from WP admin).Any clue?
In order to look further into this issue, we would need to see how your site is set up
What kind of information you would need?
THANKS A LOT!!! ??
- This reply was modified 3 years, 8 months ago by saraelba.
Hi David,Thanks for your help.
I had try with the
"BCOUNTRY" => $user->bcountry, "BSTATE" => $user->bstate,
you recommended me and then add a new user through the checkout page:
Results:
the user is added but the Mailchimp addOn IS NOT adding/synchronizing the following fields:
$baddress1
$bcountry
$bstate
$bzipcodeThe Mailchimp AddOn it’s only synchronizing the following fields (even when a user update their profile):
$bfirstname (merge field set as FNAME in mailchimp)
$blastname (merge field set as LNAME in mailchimp)
$bemail (merge field set as EMAIL or MERGE0 in mailchimp)
(and of course, other custom fields I had created)Here is the recipe I use for the Mailchimp AddOn:
function my_pmpro_mailchimp_listsubscribe_fields( $fields, $user ) { $new_fields = array( "BADDRESS1" => $user->baddress1, "BZIPCODE" => $user->bzipcode, "BCOUNTRY" => $user->bcountry, "BSTATE" => $user->bstate, ); $fields = array_merge( $fields, $new_fields ); return $fields; } add_action( 'pmpro_mailchimp_listsubscribe_fields', 'my_pmpro_mailchimp_listsubscribe_fields', 10, 2 ); /** * Tell PMPro MailChimp to always synchronize user profile updates. By default it only synchronizes if the user's email has changed (optional). * Requires PMPro Mailchimp v2.0.3 or higher. */ add_filter( 'pmpromc_profile_update', '__return_true' );
I REALLY appreciate your help!!! Have a nice day!!!Hello David!
Thanks for your reply…
After several tests, I had found the “bug”:
The bug is in the “State dropdown” plugin.This plugin use $bstate and $country.
So, merge tags for mailchimp must be in lowercase too, I guess (?)
The problem is when I write my merge tags in lowercase on mailchimp site, it becomes UPPERCASE after save.Here is the code I use for “Country and State” custom fields + Mailchimp function:
function add_billing_fields_to_profile() { global $bcountry; global $bstate; //check for register helper if(!function_exists("pmprorh_add_registration_field")) return; //define the fields $fields = array(); $fields[] = new PMProRH_Field( "bcountry", "select", array('label'=>'Country:', "options"=>array ( $bcountry ), "profile"=>true, "required"=>true, ) ); $fields[] = new PMProRH_Field( "bstate", "select", array('label'=>'State:', "options"=>array ( $bstate ), "profile"=>true, "required"=>true, ) ); function my_pmpro_mailchimp_listsubscribe_fields( $fields, $user ) { $new_fields = array( "bcountry" => $user->BCOUNTRY, "bstate" => $user->BSTATE, /*AND MORE CUSTOMS FIELD HERE created by me, that works fine. No bugs.*/ ); $fields = array_merge( $fields, $new_fields ); return $fields; } add_action( 'pmpro_mailchimp_listsubscribe_fields', 'my_pmpro_mailchimp_listsubscribe_fields', 10, 2 ); /** * Tell PMPro MailChimp to always synchronize user profile updates. By default it only synchronizes if the user's email has changed (optional). * Requires PMPro Mailchimp v2.0.3 or higher. */ add_filter( 'pmpromc_profile_update', '__return_true' );
I had change the
“bcountry” => $user->BCOUNTRY,
“bstate” => $user->BSTATE,to
“BCOUNTRY” => $user->BCOUNTRY,
“BSTATE” => $user->BSTATE,to
“bcountry” => $user->bcontry,
“bstate” => $user->bstate,etc…
But No results ??
Testing the AddOn, I see isn’t adding new members!!!
AND only updates the members emails. ??I had updated the AddOn trying to fix this issue. But nothing happened.
Forgot to say:
This custom field (GENERO) is added on mailchimp FOR NEW USERS.
Im having troubles ONLY when a user UPDATE THEIR PROFILE.
(the profile is update ONLY on the WP site. But not in mailchimp)Also I forgot to say: THANKS for your help ??
Hello David!!!
Can you please specify what you mean when you say that you deleted a user? Did you remove their membership level, delete the User object in WordPress, change their status in the Mailchimp audience, or completely delete them from Mailchimp audience?
The membership expired, then I had deleted the user object from WP.
Mailchimp completely delete them too (not me).Are you trying to add them again by completing the PMPro checkout process again, manually changing their membership level from the WP Dashboard, or by manually adding them to your audience in Mailchimp?
Yes, I had add them again by PMPro checkout process.
Hi David,
Thanks for your reply!!!Yes, I had implemented this recipe
(https://gist.github.com/strangerstudios/d473abb787ada311bd777e6ae0f587e6#file-pmpro-mailchimp-merge-with-address-field-php)And its works perfect…
But im trying to add a STATES dropdown list and add this info to my mailchimp.
It is possible do it with the pmpro_mailchimp_listsubscribe_fields filter?Forum: Fixing WordPress
In reply to: I had sidebars set, but it shows fullwidth…Thanks for your reply.
I not sure is a theme issue: i had change my theme and still fullwidht. ??