Today's Posts Follow Us On Twitter! TFL Members on Twitter  
Forum search: Advanced Search  
Navigation
Marketplace
  Members Login:
Lost password?
  Forum Statistics:
Forum Members: 24,254
Total Threads: 80,792
Total Posts: 566,472
There are 2035 users currently browsing (tf).
 
  Our Partners:
 
  TalkFreelance     Design and Development     Programming     PHP and MySQL :

PHP automatic emails

Thread title: PHP automatic emails
Closed Thread    
    Thread tools Search this thread Display Modes  
08-23-2005, 02:29 AM
#1
jono1 is offline jono1
jono1's Avatar
Status: Non-conformist
Join date: Jul 2005
Location: Canberra, Australia.
Expertise:
Software:
 
Posts: 1,172
iTrader: 0 / 0%
 

jono1 is on a distinguished road

  Old  PHP automatic emails

for a site I'm doing my client wants an automatic email sent to the user when they register, and a follow-up email sent 3-4 days after a specified time (the client sells meal plans for endurance athletes - he wants to check how the user is doing after their race).

Is there any way possible for PHP to do stuff like send emails without having a browser actually access the script?

Or, PHP isn't the only option, just the preferable one as that's what the rest of the site is being coded in. If you guys know any other methods of accomplishing this I'd be glad to hear it

thanks in advance

08-23-2005, 08:11 AM
#2
Amnezia is offline Amnezia
Status: I'm new around here
Join date: Aug 2005
Location: UK
Expertise:
Software:
 
Posts: 23
iTrader: 0 / 0%
 

Amnezia is on a distinguished road

  Old

I would use cron if you have linux hosting, look on cPanel or plesk if you have it.

The first email should be sent out when the user registers, just tag a mail function onto the register script. Record the date of registration.

Then create a php script which creates a list of all the users who registered 3 days ago, the script will then send the followup email to each of these users.

Finally set cron to run this followup php script everyday.

08-23-2005, 08:15 AM
#3
jono1 is offline jono1
jono1's Avatar
Status: Non-conformist
Join date: Jul 2005
Location: Canberra, Australia.
Expertise:
Software:
 
Posts: 1,172
iTrader: 0 / 0%
 

jono1 is on a distinguished road

  Old

really? cool. I had noticed the cron jobs button but never knew what it was for. Thanks amnezia

08-23-2005, 08:03 PM
#4
Koobi is offline Koobi
Koobi's Avatar
Status: Member
Join date: Apr 2005
Location:
Expertise:
Software:
 
Posts: 312
iTrader: 0 / 0%
 

Koobi is on a distinguished road

  Old

Amnezia said it all, but just to put things in perspective, cron's on *nix are similar the scheduled tasks on windows. the cron simply runs a task at a given time with various options.

PHP has a Command Line Interface (CLI) and the cron just executes your scripts via CLI when called.

08-23-2005, 08:04 PM
#5
Koobi is offline Koobi
Koobi's Avatar
Status: Member
Join date: Apr 2005
Location:
Expertise:
Software:
 
Posts: 312
iTrader: 0 / 0%
 

Koobi is on a distinguished road

  Old

Amnezia said it all, but just to put things in perspective, cron's on *nix are similar the scheduled tasks on windows. the cron simply runs a task at a given time with various options.

PHP has a Command Line Interface (CLI) and the cron just executes your scripts via CLI when called.


by the way, check this out for a thumping list of Ajax uses:
http://www.fiftyfoureleven.com/resou...quest/examples

Closed Thread    


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

  Posting Rules  
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump:
 
  Contains New Posts Forum Contains New Posts   Contains No New Posts Forum Contains No New Posts   A Closed Forum Forum is Closed