Ready to get started?Download WordPress


How do I mass email all my authors? (11 posts)

  1. DHermit
    Posted 9 years ago #

    I searched and didn't see anything. is there a way to do this?

  2. Kafkaesqui

    Posted 9 years ago #

    I have a simple script that displays email addresses for users, authors, or both. You could use it to collect the addresses and then cc or bcc an email message to them:


    Copy to a text file (example: user-emails.php), upload to your blog's root (where wp-blog-header.php resides), and run it in your browser. You may want to move it to a secure directory so it's not open to public access; just make sure to change the include at the top of the script to the correct path for wp-blog-header.php.

  3. Beel
    Posted 9 years ago #

    Wouldn't it be just as good to add something like:
    if ($user_level<10 ) { echo "you don't have access"; exit;}
    else ...

    to your script to prevent public access (and access only to the administrator at level 10)?

  4. Kafkaesqui

    Posted 9 years ago #

    Well Beel, since it is a WordPress-enabled script, that would make perfect sense. :)

    Thanks for the suggestion. Added.

  5. Dgold
    Posted 9 years ago #

    Not to overfluff, but you guys are great. Thanks for providing stuff like this. You make it sound so easy, and make it easy for us.

    Kafkaesq, the next version of your script could include printing the email address list as UserFirstName UserLastName <user@email.com>

    instead of just the email addy

    no big deal tho, this is great as-is.

  6. Kafkaesqui

    Posted 9 years ago #

    "[T]he next version of your script could include printing the email address list as UserFirstName UserLastName <user@email.com>"


  7. Dgold
    Posted 9 years ago #

    That's great Kafka+, except if someone doesn't have a FirstName Lastname, they get labeled same as the person previous. Still very handy.

  8. Kafkaesqui

    Posted 9 years ago #

    Oops. I'd taken care of that in the code, but apparently uploaded the wrong version (!).

    The one online should now label everything correctly.

  9. Dgold
    Posted 9 years ago #

    *Grin* Another great CMS-ish feature. Easy to install as it is, I bet you could make that a popular plugin for those who have a lot of users or authors, and who want to email them. Might want to at least note the script in the Codex.

    Question: can users un-register themselves, or delete their registrations from my site, should they (crazily) want to? i.e. unsubscribe from the email list you just made for me

  10. Kafkaesqui

    Posted 9 years ago #

    Let's just say the script is an obvious prelude to a more robust plugin solution. It would definitely require at least basic email capabilities for that to happen, though. (Just listing email addresses? Bo-ring.)

    I don't see a way to provide users/authors to ability to, on their own, be excluded from the list, unless you have them enter something in say the user profile or an unused field (like say ICQ) that the script looks for. Ugly, though. The more robust user functionality 1.6 will offer (with it's users_meta table) should allow for something like this to added quite easily. Especially as a plugin. But then I'd note at this point you're setting yourself up for a "subscribe to list" solution, and I'd naturally have to suggest looking at what may already be out there, such as:


  11. Drew
    Posted 8 years ago #

    hey man, this is what I get.

    <b>Warning</b>: Invalid argument supplied for foreach() in <b>/home/dpcorg/public_html/massemail.php</b> on line <b>71</b>

    little insight please? using WP version 1.5.3

Topic Closed

This topic has been closed to new replies.

About this Topic