svn: /phd/trunk/ render.php

From: Date: Tue, 08 Dec 2009 19:01:07 +0000
Subject: svn: /phd/trunk/ render.php
Groups: php.doc.cvs 
Request: Send a blank email to doc-cvs+get-5634@lists.php.net to get a copy of this message
bjori Tue, 08 Dec 2009 19:01:07 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=291892 Log: - Kill double slashes in paths - Use DIRECTORAKLÆDJFA for consistency - no point in having a instance of BOP arround Changed paths: U phd/trunk/render.php Modified: phd/trunk/render.php =================================================================== --- phd/trunk/render.php 2009-12-08 18:59:39 UTC (rev 291891) +++ phd/trunk/render.php 2009-12-08 19:01:07 UTC (rev 291892) @@ -5,23 +5,22 @@ // @php_dir@ gets replaced by pear with the install dir. use __DIR__ when // running from SVN -define("__INSTALLDIR__", "@php_dir@" == "@"."php_dir@" ? __DIR__ : "@php_dir@/"); +define("__INSTALLDIR__", "@php_dir@" == "@"."php_dir@" ? __DIR__ : "@php_dir@"); function autoload($name) { - $file = __INSTALLDIR__ . DIRECTORY_SEPARATOR . str_replace(array('\\', '_'), '/', $name) . '.php'; + $file = __INSTALLDIR__ . DIRECTORY_SEPARATOR . str_replace(array('\\', '_'), DIRECTORY_SEPARATOR, $name) . '.php'; // Using fopen() because it has use_include_path parameter. if (!$fp = @fopen($file, 'r', true)) { v('Cannot find file for %s: %s', $name, $file, E_USER_ERROR); - } + } fclose($fp); require $file; } spl_autoload_register(__NAMESPACE__ . '\\autoload'); require_once __INSTALLDIR__ . '/phpdotnet/phd/functions.php'; -$optparser = new BuildOptionsParser(); -$optparser->getopt(); +BuildOptionsParser::getopt(); /* If no docbook file was passed, die */ if (!is_dir(Config::xml_root()) || !is_file(Config::xml_file())) {

« previous php.doc.cvs (#5634) next »