latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

About: LAFRA Licenses

Sorry, I've not written a description yet. I'll get to it soon!


Topics I'm Subscribed To

Viewing topic 1 (of 1 total)
Topic Count Last Reply
Selections not showing in Drop Down Menu

By:  LAFRA Licenses in: Community Forum

voices: 2
replies: 4

3 years, 6 months ago  Cristián Lávaque

Viewing topic 1 (of 1 total)

Topics I've Started

Viewing 2 topics - 1 through 2 (of 2 total)
Topic Count Last Reply
Admin Notification of profile changes.

By:  LAFRA Licenses in: Community Forum

voices: 2
replies: 3

3 years, 6 months ago  Cristián Lávaque

Selections not showing in Drop Down Menu

By:  LAFRA Licenses in: Community Forum

voices: 2
replies: 4

3 years, 6 months ago  Cristián Lávaque

Viewing 2 topics - 1 through 2 (of 2 total)

My Latest Replies (From Various Topics)

Viewing 3 replies - 1 through 3 (of 3 total)
Author Replies
Author Replies
Posted: Thursday Jun 20th, 2013 at 2:31 pm #52298

Nope. No help.

I think part of the problem here is that you keep referring people to things that they can only understand if they are PHP developers. Honestly, if we were PHP developers, we could have written our own plug in. We wouldn’t have to pay for one.

When you just direct people to a block of code with no explanation, rhyme or reason whether it’s the actual code to use, just a sample, or theory…with no notes if something needs to be changed and no direction on where or what…it’s frustrating. And consequently you keep answering the same question over and over again because people aren’t getting it. We understand some coding is involved when you want special functions. But a little help for people who don’t spend everyday writing PHP code would be well received.

So, not being a PHP developer, the only hope others like me have is to copy and paste what you have given and hope.

So, let me see if I can help you, help me.
Here’s the code that you directed me to. Is there anything I need to add to this (besides my email) ? Am I supposed to replace parts of the other code with it? Because by itself it doesn’t do anything.

add_action ('show_user_profile', 'email_profile_changes');
add_action ('edit_user_profile', 'email_profile_changes');
function email_profile_changes($user_id) {
	if (isset($_GET['updated'])) {
		$user = new WP_User($user_id);
		wp_mail ('support@nhab.it', 'Profile update - ' . $user->user_login, 'testing1');
	}
}

And here is the other code from the other forum thread that I was directed to.

<?php
    add_action ('ws_plugin__s2member_during_handle_profile_modifications', 'email_profile_changes');

    function email_profile_changes($vars = array())
    {
        $user = new WP_User($vars['user_id']);

        wp_mail ('support@codespoke.com', 'Profile update - ' . $user->user_login. '
            First Name: ' . $user->first_name ['First Name'] . '
            Last Name: ' . $user->last_name['Last Name'] . '
            Email: ' . $user->email ['user_email'] . '
            Newsletter Preference: ' . $user->ws_plugin__s2member_custom_reg_field_newsletter['']. '
            Phone Number: ' . $user->ws_plug_s2member_custom_reg_field_phone_number ['phone_number']. '
            Type of Phone: '. $user->ws_plug_s2member_custom_reg_field_type_of_phone ['phone_type'].'
 Please check against your records...');
    }
    ?>

So where are we going wrong here? What do I need to do to get an admin email when someone makes a change to their profile, and alert the admin of what changed?

Thank you in advance for your help here.

Posted: Tuesday Jun 18th, 2013 at 6:49 pm #52154

Never mind. It was spaces. May want to consider adding a few extra words there that say “NO SPACES” since even the example has spaces.

Posted: Tuesday Jun 18th, 2013 at 1:52 pm #52132

Is this what you are looking for?
When I look at the code it shows the values as empty. Maybe I’m misreading the instructions that say to use a pipe between value and label. I’ve tried it every way I can think of and the fields still show as blank because every time I save it, it repeatedly erases it.

Even when I use the example shown, it doesn’t work. They still show up blank using the example.

<option value="Home"></option>
<option value="Mobile"></option>
<option value="Work"></option>

Viewing 3 replies - 1 through 3 (of 3 total)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.