Jump to content

Consolidating query scripts


markkanning

Recommended Posts

I'm building a site administration backend for a client that will involve multiple insert, update and delete scripts for different tables of a database. I'm trying to avoid having more pages in the admin site than the actual website itself. How does one have one file that includes the database connection, all the variable declarations and all the queries and form processing on one file? It would be nice if I could have the forms involved have an action that references the same processing file and possibly a reference to a function in that file that does the inserting, updating or deleting.

Any thoughts?

Mark
Link to comment
https://forums.phpfreaks.com/topic/26497-consolidating-query-scripts/
Share on other sites

Here's another scenerio on that same idea(and please forgive the somewhat novice smell that's coming off of the screen): could I at least include multiple, say, include queries for different tables in one processing script? It seems to me, as long as they're dealing with differently named variables, one wouldn't accidently insert data into the wrong table. Is that right? Or is it not good to be querying mutliple tables at once?

Mark

Archived

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

×
×
  • 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.