| |||||||
| Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics. |
![]() |
| | LinkBack | Thread Tools |
| | #1 (permalink) |
| DNOA Member | Hello, I need a PHP script that goes through all rows in a table and: A) If the field "last_login" is 20 days old or more, it sends an email to the user, email field being "email" notifying that he/she has 10 days to do login to his/her account to keep it from being deleted. B) DELETES the row if the "last_login" field is 30 days old or more. The catch? This must be tested on YOUR OWN SERVER! I want to see a WORKING SAMPLE - this script is for www.VirtualDN.com - and I simply cannot risk a script glitch on my own server. The dates are stored in this PHP date() format: F d, Y That's: February 02, 2005 ...similar to that. Convert it if you must but I need it to be bug-free. Thanks for anybody who can do this... $5 will be sent via PayPal to a working script. -Matt
__________________ codeboards A high-quality community of programmers -- Join today and post! We want new members! |
| |
| | #2 (permalink) |
| NamePros Member | You didn't give enough information (name of the user, mysql type of the date, database type, ...) but you can use this to create your own script: PHP Code:
__________________ Christmas FAQ | Hussein Trial Blog | News for developers | Find your IP address | Anti-Spyware resource | The Interweb | Halloween FAQ | sweetgifts.us | lqfp.com |
| |
| | #3 (permalink) |
| DNOA Member | I told you the type of date - F d, Y which really only fits in VARCHAR... use some logic. Database type... MySQL .... really: What other database system implements w/ PHP so well and is used so commonly? I am not willing to buy a script from somebody that does not know what they're doing. Please write an original script for you to get your $5 - again it must be tested on your own server.
__________________ codeboards A high-quality community of programmers -- Join today and post! We want new members! |
| |
| | #4 (permalink) | |
| NamePros Member | Quote:
Edit: Here, because I'm a nice guy: Look into the MySQL cast operator to create a workaround for your horrible table design. Something like "select cast(last_login as date) from table". Maybe you're lucky and that works.
__________________ Christmas FAQ | Hussein Trial Blog | News for developers | Find your IP address | Anti-Spyware resource | The Interweb | Halloween FAQ | sweetgifts.us | lqfp.com Last edited by sjp; 12-14-2005 at 12:27 PM. | |
| |
| | #5 (permalink) |
| DNOA Member | I'm glad you appreciate the fact that I told you that you don't know what you're doing. Your welcome. And, obviously you don't know what you're doing since I specifically ask that I see a sample of it. Now bug off and I would appreciate it if somebody else could follow my criteria.
__________________ codeboards A high-quality community of programmers -- Join today and post! We want new members! |
| |
| | #7 (permalink) |
| NamePros Regular | Yeah, you need to post the table structure at least. And honestly, if this is such a critical thing for you (and obviously it is and you can't risk screwing up your server/database/site), I think you should offer more. BTW, sjp's solutions looks fine to me (different coding style, though ). |
| |
| | #8 (permalink) |
| DNOA Member | Table structure ... why? I give you the fields that are used ...
__________________ codeboards A high-quality community of programmers -- Join today and post! We want new members! |
| |
| | #10 (permalink) |
| DNOA Member | THANK you! Many thanks again. I look forward to seeing your results
__________________ codeboards A high-quality community of programmers -- Join today and post! We want new members! |
| |
| | #11 (permalink) |
| DNOA Member | Any progress? Btw, jdk, how am I supposed to reply to your PM when you have disabled Private Messages?
__________________ codeboards A high-quality community of programmers -- Join today and post! We want new members! |
| |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Huge Script Pack for $5 with Resale Rights | dsforsaken | Scripts For Sale | 32 | 12-03-2005 08:46 PM |
| [urgent] Help! Mass_Add script not working for olate | WuLabsWuTecH | Programming | 0 | 04-23-2005 02:49 PM |
| Domain Parking Script | ezimedia | Parking & Traffic Monetization | 3 | 03-02-2004 11:17 PM |