Login   Register  
PHP Classes
elePHPant
Icontem

File: AdvATE/example2data.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Andrew Sullivan  >  Ajax Table Edit  >  AdvATE/example2data.php  >  Download  
File: AdvATE/example2data.php
Role: Auxiliary data
Content type: text/plain
Description: Used by example2 to create sample data
Class: Ajax Table Edit
Edit data in an HTML table using AJAX
Author: By
Last change:
Date: 8 years ago
Size: 1,040 bytes
 

Contents

Class file image Download
<?php

/* 
	you do not need to run this page seperately, it will create
	the data for you if it doesn't exist.
*/

$data = array();
$data[] = array(
	'name' => "Some Guy",
	'address' => "123 Some Street",
	'phone' => "111-111-1111",
	'phonetype' => "Work",
	'sex' => 'Male'
);
$data[] = array(
	'name' => "Some Girl",
	'address' => "123 Some Drive",
	'phone' => "111-111-2222",
	'phonetype' => "Home",
	'sex' => 'Female'
);
$data[] = array(
	'name' => "Another Some Guy",
	'address' => "123 Another Street",
	'phone' => "111-111-3333",
	'phonetype' => "Cell",
	'sex' => 'Male'
);
$data[] = array(
	'name' => "Another Girl",
	'address' => "123 Some Street, Apt B",
	'phone' => "111-111-4444",
	'phonetype' => "Home",
	'sex' => 'Female'
);
$data[] = array(
	'name' => "Grandma",
	'address' => "123 Old Street",
	'phone' => "111-111-5555",
	'phonetype' => "Home",
	'sex' => 'Female'
);

$example2 = serialize($data);
$open = fopen("test2.txt", 'w');
fwrite($open, $example2);
fclose($open);

?>