How to make a php article counter?

Need Help With Mysql and Php for videos!?

  • i have a website i want thumbnails of videos in a row and when clicked it takes the visitor to a page where the video is played, is there a a away to store video info and thumbnails in a Mysql Database so that when i add a new video it will update automatically and i dont have to move everything to make room for it ? also I use jw player to play the videos but it doesnt come with a View counter, is there a away to add a View counter underneath each thumbnail so people can see how many views a video has ? i know a little php and Mysql but if someone could explain in simple steps i would be grateful.

  • Answer:

    Scenario: Add A New Video - user: upload video with video info - system: retrieve then store the file - system: generate a thumbnail (you can use a third party php library, or a third party software installed on your server[security risks]) - system: save into the database- > video info, video view count(as 0), video thumbnails(as blob), video pathname Scenario: List videos - user: open video list page - system: retrieve all the videos data - system: display thumbnails and link it to the watch page Scenario: Watch video - user: click on a thumbnails - system: use the given video info then retrieve the matching video information from the database - system: build the watch page(jw + link to video file + view count + ..) Use MVC: model(VideoClass), controller(querying the database), and view(page generator: watch, video list) This is how I would do it, it is not very sophisticated but it might works.

Mark at Yahoo! Answers Visit the source

Was this solution helpful to you?

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.