cancel
Showing results for 
Search instead for 
Did you mean: 

IS CGI the right place

N/A

IS CGI the right place

I want to place a database on my website that can be accessed by people visiting the site - is CGI the right place to do this - to be honest I havn't got a clue what CGI is or does - what I do know is that I have read most of the letters in the forum and most of it is written in double dutch to me - so where should a simpleton start to get the best advice on SQL [whatever that is] and CGI

Thanks

Barrie
2 REPLIES
N/A

IS CGI the right place

Barrie: Yes, the CGI machine is the right place to be doing what you want.

Although this won't help you one jot, "CGI" stands for "Common Gateway Interface". Let's just say it provides a common ("standard") mechanisim for interfacing between the web world and other systems (computer programs, which can therefore obtain and manipulate web data, place it in a data base; retrieve data from a database and in turn present that to the web). So, in short, CGI provides for programmable (and therefore "dynamic") web content: what one user gets when he request a web page can be different from what another user gets.

SQL stands for "Structured Query Language" and has its origins in IBM, where it was devised as a language for manipulating data in their early relational databases. These days, the language has become standardised (although with variations between database vendors) and is used by pretty much any database that has pretensions to be "relational". It is really a "database query language" used to create and delete ("drop") databases and database tables and other entities; to retrieve and manipulate data. In short, if you want to do anything with a database, SQL comes into the picture.

For your own application, you will need to go to Website settings and activate both your CGI use and MySQL, if you haven't already. The CGI machine provides you with the facilites for programs -- you can use scripting ranging from shell scripts to Perl to PHP; you can compile C (and, presumably C++) programs, and I believe there's also a Java compiler/runtime system. MySQL gives you the database facilites (MySQL being an open source relational database management system). How you then tie together the programming facilities with the database facilities and tie them to the web is up to you!

How best to proceed once you've activated the facilities for you account is difficult to say, since it depends on exactly what you have in mind. The easiset thing is always to find an existing "package" which already does what you want, rather than write your own from scratch.

Many people find PHP to be a convenient language for both web and database work, being straightforward to learn, easy to deploy, and giving reasonable performance for small applications. If you decide you are going to write your application yourself, PHP would be a good thing to look at. Try searching for PHP tutorials on the web, or search out a decent book. On the database side, you won't be able to get away from SQL, so you'll need at least a working knowledge of basic SQL statements, which will be embedded into your PHP code. Any decent book on PHP will show this, and will probably do so in relation to MySQL (because of its popularity); the PHP book will also have chapters which deal with web interfacing.

That takes care of the programming side, but there's one more thing, and that relates to the database: you need to do some sort of analysis of the data you wish to store in the database to discover the relationships and dependencies between different data; this is a huge subject in its own right, and could take a lot of time if your application is anything other than trivial. If you have no experience of this, I'd be inclined to enlist some help -- find a friendly database administrator (DBA) at work or something! Understanding your data and getting your data structures right is absolutely key to a successful application.
N/A

Clear as mud

Whow!!! thanks task - that makes it as clear as mud - not your fault, I'm a bit of a dunce with this computer, you know the old saying 'a little knowledge' well that's me. I understand how to set up a database on a spreadsheet [lotus 123 or excel - I can use also lotus approach so the database side is not to bad - however, I use a little known programme called Web Studio to create my web site - this is one of those programs that virtually does everything for you, you need no knowledge what so ever of web programming [Well a little] it makes it difficult to set up your own outside links - or your own program details [though I believe it can be done - but it does not, as far as I know, allow you to mix normal programming with its own web pages.
But thanks for the PHP thing I will try to find a book on the subject

Regards

Barrie