1<?php
2// Example 1
3$pizza = "piece1 piece2 piece3 piece4 piece5 piece6";
4$pieces = explode(" ", $pizza);
5echo $pieces[0]; // piece1
6echo $pieces[1]; // piece2
7
8// Example 2
9$data = "foo:*:1023:1000::/home/foo:/bin/sh";
10list($user, $pass, $uid, $gid, $gecos, $home, $shell) = explode(":", $data);
11echo $user; // foo
12echo $pass; // *
13
14?>