I have written a content management system (DW8, PHP, mySQL) which allows a user to add, edit and remove content from a mySQL database using php pages. One of the many fields in the table which contains the main page content is a field called "hits". Another field is called "pdf" and contains a link to a specific pdf file for that record.
I want to be able to insert a link or button which when clicked or pressed updates the field "hits" by 1 and then takes the viewer to the pdf in the field "pdf".
Anyone any ideas? It's the updating the "hits" field by 1 part that I'm having bother with.
The code to update the hit counter needs to be actioned after the button/link is actioned. From what you say the link will interrogate the database to find the corresponding PDF file. The hit update will therefore be part of the code that does this operation.