All pastes #251248 Raw Edit

Stuff

public text v1 · immutable
#251248 ·published 2006-11-17 22:52 UTC
rendered paste body
<?php

define('SF_ROOT_DIR',      realpath(dirname(__file__).'/..'));
define('SF_APP',           'frontend');
define('SF_ENVIRONMENT',   'dev');
define('SF_DEBUG',          true);
-
require_once(SF_ROOT_DIR.DIRECTORY_SEPARATOR.'apps'.DIRECTORY_SEPARATOR.SF_APP.DIRECTORY_SEPARATOR.'config'.DIRECTORY_SEPARATOR.'config.php');
-
// initialize database manager
sfContext::getInstance(); // $databaseManager = new sfDatabaseManager();
// $databaseManager->initialize();

$conn = sfDoctrine::connection();

$query = new Doctrine_Query();
$query->parseQuery('FROM News');

$pager = new sfDoctrinePager('News');
$pager->setQuery($query);
echo serialize($pager);

-----------------------------------

# php ./batch/test.php

PDOException: You cannot serialize or unserialize PDO instances in /var/www/../batch/test.php on line 21

Call Stack:
    0.0004      50096   1. {main}() /var/www/../batch/test.php:0
    0.1167    5070184   2. serialize() /var/www/../batch/test.php:21

Dump $_SERVER
Dump $_GET
Dump $_POST
Dump $_COOKIE
Dump $_FILES
Dump $_ENV
Dump $_SESSION
Dump $_REQUEST