Callback E-mail

For general discussion of the Poker Mavens software
Post Reply
cuervo5150
Posts: 97
Joined: Fri Feb 06, 2009 3:13 pm
Location: California
Contact:

Callback E-mail

Post by cuervo5150 »

Greetings Kent,

Would you please show me how to use the Callback feature at the end of a daily tournament to send a generic congratulatory e-mail to the winner. I know it's sort of redundant because the player knows they won, but I want the player to feel they were recognized for thier accomplishment.

As always, thank you for your assistance,
Kent Briggs
Site Admin
Posts: 5878
Joined: Wed Mar 19, 2008 8:47 pm

Re: Callback E-mail

Post by Kent Briggs »

cuervo5150 wrote: Would you please show me how to use the Callback feature at the end of a daily tournament to send a generic congratulatory e-mail to the winner.
That would require a few hours of coding. I'll give you the outline of it:

The Tournament Finish Event will call your PHP file and include a tournament "Name" and "Number" parameter. Use the Name and the current date to retrieve the tournament results file for that tournament using the TournamentsResult command in the API. Parse through that output looking for the tournament Number. Parse some more looking for the Place1 line. Pull the player's name out of that line. Parse some more looking for the Stop line to make sure it doesn't show "(Abort)" on the end. With the player's name, call the AccountsGet command in the API and fetch the player's email address. Use the PHP mail() command to send the email.
social
Posts: 211
Joined: Fri Nov 20, 2009 12:23 am

Re: Callback E-mail

Post by social »

Kent Briggs wrote:
cuervo5150 wrote: a tournament "Name" and "Number" parameter.
Could you give me an example of how the Number parameter is used?
What is it for?
Kent Briggs
Site Admin
Posts: 5878
Joined: Wed Mar 19, 2008 8:47 pm

Re: Callback E-mail

Post by Kent Briggs »

social wrote: Could you give me an example of how the Number parameter is used?
What is it for?
It's just a sequential number that gets incremented every time a new tournament starts on your site. It gives each one a unique number that you can use for your own purposes.
Post Reply