Jump to content

Creating a PHP/SQL Online Database


jhenrichs
 Share

Recommended Posts

This might be in the wrong forum because I have yet to write any code, but I kind of brainstorming/planning at the moment. 

 

What I am wanting to do, is to make quite an extensive database for work.  I am going to be using php/html to make the actual website and what I am wanting to do is use text boxes to load a query when they go to the respective website, in theory, all I should have to do is have an sql connect statement as well as an sql select statement to select the data that I want, I would then have to map that data to load the data to the text box (if I am correct  :confused: )  I am thinking the correct statements I would be using are this:  http://www.w3schools.com/php/php_mysql_connect.asp  AND this:  http://www.w3schools.com/php/php_mysql_select.asp

 

The second thing that I would like to be able to do, would be to allow users to edit and save information from the queries that they load.  It would be using some kind of update statement like this:  http://www.w3schools.com/php/php_mysql_update.asp  But I am not sure how I would go about doing that, or if that would even be possible.

 

Any help or links to websites would be a great help, I do have "PHP Solutions: Dynamic Web Design Made Easy" by David Powers on order, so I am hoping that will be of some help.

Link to comment
Share on other sites

What I am wanting to do, is to make quite an extensive database for work.  I am going to be using php/html to make the actual website and what I am wanting to do is use text boxes to load a query when they go to the respective website, in theory, all I should have to do is have an sql connect statement as well as an sql select

 

Implies your going to be having more then one website or perhaps be interacting with multiple websites? Not quite sure. You need to clarify your intentions.

 

 

I would then have to map that data to load the data to the text box

 

What the fuck? I think your saying you want to SELECT data from a table and display it in a textbox? Unless its a random message, displaying in a textbox isn't particularly advisable. Elaboration on this is definitely required.

 

 

allow users to edit and save information from the queries that they load

 

By "queries they load" I would assume you mean "data from the database the end user loads"?

 

 

 

From the sounds of it, your database is very simple, not extensive. You need to be far clearer in your descriptions and must stop using "this/that/over there" because we've no idea what your talking about; English may not be your native language and I think we all appreciate that here but we can't help unless your more specific.

 

Finally, what's the problem? I can't really see anywhere you've specified any sort of issue or asked for any sort of help? With regards to the links you've posted you look like your heading the right way but you definitely need to pick up a book and get the basics before attempting anything complex - although this doesn't sound overly complex.

 

  • Be clearer
  • Define your questions clearly so we can help you as much as possible with the route problem
  • Start reading and post questions about things you don't understand in your book

Link to comment
Share on other sites

What I am wanting to do, is to make quite an extensive database for work.  I am going to be using php/html to make the actual website and what I am wanting to do is use text boxes to load a query when they go to the respective website, in theory, all I should have to do is have an sql connect statement as well as an sql select

 

Implies your going to be having more then one website or perhaps be interacting with multiple websites? Not quite sure. You need to clarify your intentions.

 

 

I would then have to map that data to load the data to the text box

 

What the fuck? I think your saying you want to SELECT data from a table and display it in a textbox? Unless its a random message, displaying in a textbox isn't particularly advisable. Elaboration on this is definitely required.

 

 

allow users to edit and save information from the queries that they load

 

By "queries they load" I would assume you mean "data from the database the end user loads"?

 

 

 

From the sounds of it, your database is very simple, not extensive. You need to be far clearer in your descriptions and must stop using "this/that/over there" because we've no idea what your talking about; English may not be your native language and I think we all appreciate that here but we can't help unless your more specific.

 

Finally, what's the problem? I can't really see anywhere you've specified any sort of issue or asked for any sort of help? With regards to the links you've posted you look like your heading the right way but you definitely need to pick up a book and get the basics before attempting anything complex - although this doesn't sound overly complex.

 

  • Be clearer
  • Define your questions clearly so we can help you as much as possible with the route problem
  • Start reading and post questions about things you don't understand in your book

 

I am not so good at explaining things, I am work for a small telecommunications company and we have service in several towns, so what I am wanting to do is create a database that stores settings for each piece of network equipment in each town, so I will be having multiple html pages to load a SQL query for each piece of equipment that we have, so pretty much it will be multiple html pages connecting to one big database.

 

As for your second statement, if you would have fully read my full post, you would have seen in my third paragraph that I want to be able to update the queries and I am no html expert, but in the years I have been doing html, the only way I have found to edit or submit text would be in a text box, thus explaining why I would want to load the query information into text boxes.  Seems logical to me but maybe I am missing something?

 

The main reason for me posting is to see if it is possible, I know its possible to load a SELECT query, what I am unsure of is how to do an UPDATE statement to save any information that they update.  I will try to explain it better.  Say I have a link that says "ACME Router" they click on that and it will load a query that has information about that device such as IP address, subnet, gateway, name, location, firmware version, etc.  Say Johnny updated the firmware and needed to update that field, I want him to be able to update that info in a text box and then hit an update button that will save that updated information back to the database. 

 

Maybe putting it that way would make more sense so you are able to understand it better?

Link to comment
Share on other sites

All of this is very easy.. and just get started!

 

You can have a page to input data into the database

 

You can have a page to show the data inside the database

 

You can have a page to edit the data inside the database

 

To edit the data, all you have to do is get the data from the database by select, output that data inside the right text boxes / areas and have a edit button at the button that links to a script which indeed uses the update function to update the data to the database.

 

Literally you could write this basic script in a day without any previous knowledge so just start, you have already got the right functions to use, all you need to do now is create the database and write the (simple) script! :)

Link to comment
Share on other sites

This thread is more than a year old. Are you sure you have something important to add to it?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.