Solved

setting a Cron job to Email users from database monthly

Posted on 2014-11-13
2
105 Views
Last Modified: 2014-12-18
I'm looking for a way to email users within a database using PHP. I have never had to do this before so I new to this.

Any help would be greatly appreciated.

Ta Adam
0
Comment
Question by:Geektank
2 Comments
 
LVL 11

Expert Comment

by:Radek Baranowski
ID: 40439925
what do you have at hand ? own machine with php and mysql ? rented cloud server? hosting offering giving you access to php and mysql ?

basically what you need to do is to build php app which will contain
- code to query database for emails
- code to invoke sendmail() properly (or other php mailing function, which is available on your server) in some kind of loop going over the email set acquired from the database
- cron job set up accordingly to run your code once a month. if you have your own machine you can set up standard cron/windows scheduler job, if you are using some kind of hosting, you also should have access to cron setup, ehre you will give the name of the function or URL to invoke once a month to trigger your above function

that's a rought sketch, I know, but I'm not sure what do you have and whagt you can use, also what is you php level :)

cheers, hope this helps!
0
 
LVL 108

Accepted Solution

by:
Ray Paseur earned 500 total points
ID: 40444428
This article has some "getting started" resources for anyone new to PHP and MySQL.
http://www.experts-exchange.com/Programming/Languages/Scripting/PHP/A_11769-And-by-the-way-I-am-new-to-PHP.html
0

Featured Post

Zoho SalesIQ

Hassle-free live chat software re-imagined for business growth. 2 users, always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I made this because I wanted to get e-mail with a attached csv file so I'd would be able to import user input into a MS Excel template, but I also wanted to register/save all inputs from each day in a file on the server. 1st - It creates a temp C…
Does the idea of dealing with bits scare or confuse you? Does it seem like a waste of time in an age where we all have terabytes of storage? If so, you're missing out on one of the core tools in every professional programmer's toolbox. Learn how to …
The viewer will learn how to count occurrences of each item in an array.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now