[FX.php List] Export Records to Excel/CSV - with limitation

Joel Shapiro jsfmp at earthlink.net
Fri Mar 30 11:26:39 MDT 2007


Hiya John

I'm not sure if this is what you're asking...

$currMonth=(date("m/Y"));

and then compare $currMonth to your FM month.year field(s)

-Joel


On Mar 29, 2007, at 4:18 PM, John Moed wrote:

> I would like to give my users the ability to download records in my  
> database
> to Excel or CSV but also limit them to 200 records a month (so they  
> don't
> download my entire database). I have a working Export to csv, and I  
> know how
> to limit the downloads, but I can't figure out how to set up the DB to
> record the number downloaded and calculate how many downloads  
> remaining for
> this month and then, at the beginning of the new month, have the  
> downloads
> available reset to 200.
>
> I could have 3 fields in a downloads table, one being month.year  
> and create
> a new record for each download date. The program could then add up the
> number of downloads this month and subtract that number from 200 to  
> see what
> is available.
>
> My major point of confusion is how to tell if "today" is part of  
> this month.
>
> Any suggestions?
>
> Thanks,
> John Moed
> www.technames.com
>
>
>
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list



More information about the FX.php_List mailing list