How to get started on a diet logging script in php/mysql/jquery

Question!

Hey guys, hope this isn't too much of a n00b question

I'm mainly a front end developer that has recently started to do some back end programming. The script I'm working on is pretty simple (in theory). I just don't know where to begin and was hoping for some advice that will lead me in the right direction.

-The script is essentially a simple data logger.
-Everyday the user logs into the website, where it brings them to a single page. -The user then checks an input box and enters a value into another input box -That number is stored in the database

That's pretty much it. It seems pretty simple, but the problem is that there needs to be one administrator account that can read all the inputs of all other users.

My Question: What is the BEST way to start this project? I have absolutely no clue on how to start it. Should I create classes for each of the functions (user logging in, user inputting value)? Should I use a framework? What would be the first steps you would take as a programmer.

I know this isn't a specific question, but like I said, I'm new to writing scripts that involve dealing with the backend and all that fun stuff. Thanks in advance.



Answers

In my experience - start with the front end. It's fantastic that you're a UI developer and you should absolutely start there. If a value should be dynamically inserted put in a placeholder.

At this stage I think a framework is inviting a pile of work to land on your desk. PHP documentation is great and will serve you better than any framework in my opinion.

Here's what I'd do, maybe you can roll with it too:

  • Create the UI in simple HTML/CSS/jQuery
  • Insert placeholders for dynamically created content
  • Remove common elements (header/footer/sidebar boxes/etc) and create PHP includes
  • Hunt down each "dynamic data" placeholder and create a PHP function to output placeholder data
  • Once you know what data you need, create the database
  • Create example records in the database
  • Adjust the PHP files to pull out example records
  • Now create the forms to insert data into the database (because you know what few fields are needed)
  • Test, test and test

I have always worked this way because I believe the user comes first. Many programmers are too involved in the architecture or database structure or complex forms. Most people at work hate me because I start with the UI. You sir are privileged!

By : Al.


This video can help you solving your question :)
By: admin