Jump to content
Washington Football Team Logo
Extremeskins

MySQL and PHP


Devastate

Recommended Posts

Ok let me really pick at the experts here on this one..

My job is supervisor of a rather large NOC in the DC metro area.. Every day I have a morning tech and an evening tech do a walkthrough. Up till now we use paper and walk around with a clipboard and physically look and then check a box when we do something.. I'd like to eliminate the paper and do this with a form.. So I've done up a form which has check boxes.

My question is when I setup the query page how will it know if a box has been checked or not and how to display a checkbox?

right now I have teh sql entries as tinybit(1)

simplifying this of course but would the query read something like this?

if back_dooralm_dca = 1 show check.jpg

if back_dooralm_dca = 0 die

Link to comment
Share on other sites

Been a long time since I've messed around with that, but it sounds like you're a bit confused.

The checkbox is entirely client side. The PHP code is server side. You would have to write a javascript onSubmit() to include the values in the form when you hit the submit button (or whatever you call it)

Alternatively i believe you could do something every time a box is checked.

Edit: check out this example

http://www.w3schools.com/html/html_forms.asp

Actually you don't need javascript, and I'm not sure why you would need MySQL. The PHP code can extract the values for each checkbox. I'm a bit too lazy at the moment to look up how exactly you do that.

Link to comment
Share on other sites

All I see in your OP some chick that needs to be checked. ;)

So are you now going to walk around with a laptop in your hand?

Or you are going to still use a clipboard with a printed form on a piece of paper?

Check is a bit in SQL by the way. And in a query you can say if true or yes. This is from MS SQL so might be a little different in my SQL.

Why not just do it in Access database. It is alot easier and simpler.

Link to comment
Share on other sites

All I see in your OP some chick that needs to be checked. ;)

So are you now going to walk around with a laptop in your hand?

Or you are going to still use a clipboard with a printed form on a piece of paper?

Check is a bit in SQL by the way. And in a query you can say if true or yes. This is from MS SQL so might be a little different in my SQL.

Why not just do it in Access database. It is alot easier and simpler.

Because when they get full they get slow and stupid.

Link to comment
Share on other sites

Because when they get full they get slow and stupid.

You won't "fill" up an Access database that easy. Plus if you were to put enough data in it to get bloated (which you wont from what you describe) there are means to fix it.

I would rather my employee build this in Access which would take me all of a day, then try and right a customer coded app in PHP/MySQL.

As per the thread, the above post regarding javascript is the correct answer.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...