Hello, i have a grid application with a field upload(filename), also another field that shows small image to download the file {download_file}
I want to keep count of number of downloads of each file in the grid that shows the files…
- I added a new field to mysql database table name: dl_times
- tried to make an ajax event that onClick of the field updates the table something like
on Ajax event onClick of field:
sc_lookup(current_times, "SELECT dl_times FROM myTable where file_id={file_id}");
sc_exec_sql("UPDATE myTable SET dl_times={current_times[0][0]} WHERE file_id={fileid}", "myConnection");
also tried the code sample that updates the database with certain fields set
nothing work,
anybody can explain why or how to do this download_times trick?
thanks in advance