Wednesday, 19 October 2011

Week 9

This weeks lecture focused on a few topics related to databases such as

  • File uploading
  • Data Handling (This section was more focused as as a web designer we are bound to work with sensitive information which we need to handle very carefully.)
  • Error Handling. 
Other than that the actions to follow if a website or database hacked were also discussed.

During the workshop we focused on more basic designer aspects of databases such as,

  • Inserting Information (This was discussed last week, but this week we looked deep into this matter and worked with a database and managed to enter data into it)
  • Deleting Information (This was also continuation from last week)
  • Editing Information (During this we learned how to bring the data from the database into the web page so the user only has to edit what they want to and not have to re enter all the data)
One of the important information we came across during the workshop was that a deleted record cannot be retrieved so it is important to make sure that when deleting a record it is made sure that is deleting is actually what you want to do. 

Other than that when inserting a record it is important that the primary key is not played around with as it is set on auto increment. If any force entries are done on this it might lead to complications on the database.   

Wednesday, 12 October 2011

Week 8

Lecture this week was on how & why to use a mySQL in PHP. Also included some basic information of database use and about mySQL.
The reasons to use mySQL with PHP are;

  • mySQL is 100% free
  • It is very easy to use with PHP
  • mySQL is very easy to learn & manage
The next topic on the lecture was on the structures and basic rules when using mySQL. Tables are usually structured into columns which contain data fields and the rows will have data which con-inside with those fields. Also you can view, insert, delete or edit these data using SQL queries. 

There are some basic steps when working with mySQL and PHP.
  1. Connect to the database using database name, username & password
  2. Create a SQL statement
  3. Send a query the database
  4. Hold onto results
  5. Show the results
  6. Close the connection
During the tutorial we learned the use of these areas and we created pages,
  • To connect a data base
  • To insert a record
  • To view record

Wednesday, 5 October 2011

Week 7

This week the lecture was on PHP security measures. What has to be done in order to maintain a secure PHP based website with a SQL server running.

During the workshop we explored the connection between SQL and PHP. Also the the use of email with PHP and the get command used during the PHP was also detailed.

We also learned the basics of SQL statements such as writing a select statement, inserting and deleting a record from a database etc. The email function is is used to send email to a unlimited group if recipients from a email address of the programmers choice. This has its potential privacy and legal issues which were also discussed.

 The get command is simply how PHP used that command to obtain data from a variable.