Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: fix_persistanc…
Fetching contributors…

Cannot retrieve contributors at this time

25 lines (20 sloc) 0.609 kb
<?php
require_once "bootstrap.php";
$article1 = new Documents\Article();
$article1->setTitle("Who is John Galt?");
$article1->setBody("Find out!");
$article1->addTag("Philosophy");
$article2 = new Documents\Article();
$article2->setTitle("Human Action");
$article2->setBody("Find out!");
$article2->addTag("Philosophy");
$article2->addTag("Economics");
$article3 = new Documents\Article();
$article3->setTitle("Design Patterns");
$article3->setBody("Find out!");
$article3->addTag("Computer Science");
$dm->persist($article1);
$dm->persist($article2);
$dm->persist($article3);
$dm->flush();
$dm->clear();
Jump to Line
Something went wrong with that request. Please try again.