PHP Classes

File: example3.php

Recommend this page to a friend!
  Classes of Giulio Bai   AcronymIT   example3.php   Download  
File: example3.php
Role: Example script
Content type: text/plain
Description: Example #3
Class: AcronymIT
Locate and process acronyms within text phrases
Author: By
Last change:
Date: 16 years ago
Size: 692 bytes


Class file image Download


$acronymit = new AcronymIT();

$acronymit->add_acronym("LOL", "Lough Out Loud");
$acronymit->list_acronyms(); // Default file with LOL, Laugh Out Loud added

$acronymit->list_acronyms(); // Default file without LOL, Lough Out Loud

$acronymit->add_acronym("LOL", "Lot Of Laughs");
$acronymit->list_acronyms(); // Default file with LOL, Lot Of Laughs added

$acronymit->list_acornyms(); // Changing the file: LOL does not exist now

$acronymit->add_acronym("LOL", "Laugh Out Loud");
$acronymit->list_acronyms(); // So let's add it again to the new file!