Preparing for your first script
Before we start creating scripts we must first set up our document correctly. This is important as it will prevent any frustrations later.
The video below will demonstrate how to do this.
Use the above video to help you create the html template.
Debugging - the internal server error
Debugging scripts that are running on a server can be difficult but if you follow the steps outlined below you will minimise the number of times you see the following in your browser:
- Ensure that you have set-up your server-side script properly using the above video
Check for syntax errors in Idle before transferring the script to the server using the Run -> Check Module option in the menu
If you are on a Unix based system (Mac OS X for example) ensure that your script is executable. The video below show you how to do this.
Use the above video to make the script executable if you are on a Unix based system e.g. Mac OS X.
Writing your first script
Now that you have set-up the server-side script template and have some understanding of the problems we can encounter it is time to write our first script.
- 1. Introduction to server-side scripting
- 2. Getting ready for server-side scripting
- 3. Preparing for your first script
- 4. Create your first server-side script
- 5. Capturing and processing data
- 6. Processing the form data
- 7. Server-side scripting and databases
- 8. Adding data to a database
- 9. Displaying data from the database
- 10. More on HTML forms
- 11. Pizza Kitchen
- 12. Administration Forms
- 13. Customer Account Form
- 14. Customer Order Form
- 15. Current Orders