About Mysql Database

So you want to know what is mysql ? Or already now it and want to learn how to use it with php ? In all cases we are here to help you !

Mysql is useful when you want to store data, infos... Yes you can save your data in a text file, but will not be easy to read details, to search, or any other task...

For example, let's say you want to store details of users of your website, every user will have an username, password, and email , you can so create a database, with a table "users", and that table has 3 columns: username; password; email, and each user occupies one line. It's exactly like Excel documents...
In that example, you can store data in a text file, each user per line, his details seperated with ";" , but that will make a big file if you have many users, so script will be slow in reading and writing, and the most important thing: searching.
Mysql is known as a fast database, and very smart one.

You can use many tables in the same mysql database, and with relations between them, which make it the best database.

Mysql is used with php, but has its own language, so php functions will send mysql scripts to mysql server, then the server do the tasks, and send back results to php where you can manipulate them.
You can for example read all details from a mysql table, or insert a new entry, update one, or delete another, or search in the table and get the matching entries, or sort data, or create a new table ...

We will see step by step how to do all that,
Will see you again, bye !

Do you need a php programmer ?

Find programmers and grapic design experts at ScriptLance.com

The best solution to hire a programmer for a project you have, is to look for a freelancer.
But where ?

Ok, I know, there are many freelance websites and you are confused, or maybe you don't know any one, in all cases I advice you to take a look at scriptlance .

Yes, I like it, and I'm already a programmer there, you can register and post your project for free, so nothing to lose to take a look at :)

Why ?
There are many excellent programmers there, and they can do their job very quickly and very cheap !

It's also secure, as the money will be keept in an escrow account, and the programmer can't take it unless he complete his job and release the money to him. You can also pay with any method you like .

So, just go to scriptlance and, you will see a message in the home page: "Describe what you need and submit a project free and quickly"
Post there your project !

If you don't have a project yet, register for free, and post whenever you need.

. . . . . . . . . . . . . . . . . . . . . . .

Oups, I forget, if you are a programmer and want to become freelancer and get paid, just register as programmer, it's also free ..

Outsource your projects to thousands of programmers at ScriptLance.com

php Loop statements

Loops are used in programming to do the same tasks many times, while a condition is true...
That means, same script will be executed and repeated, until that condition becomes false.

The loop statements used in php are:
do ... while

while and do ... while are similar, the only difference is that, the first one will execute the script if and as long as the condition is true, but the second one, will execute the script, then repeat it as long as the condition is true. In brief, when condition is false while will not do the tasks and exit, but do ... while will do them and exit.

For is to repeat tasks a specific number of times, like you want to execute a script 10 times ....

Foreach to repeat tasks for each element in an array.

Next posts will show how to use these statements.

If you have any questions, post them.