Re: cvs: phd(PHD_0_4) / build.php /include PhDMediaManager.class.php PhDTheme.class.php PhDThemeXhtml.class.php

From: Date: Wed, 18 Feb 2009 12:32:57 +0000
Subject: Re: cvs: phd(PHD_0_4) / build.php /include PhDMediaManager.class.php PhDTheme.class.php PhDThemeXhtml.class.php
References: 1  Groups: php.doc.cvs 
Request: Send a blank email to doc-cvs+get-3310@lists.php.net to get a copy of this message
Richard, Please revert that commit. It's plain wrong. I'll explain later this evening. On Wed, 18 Feb 2009 12:24:30 -0000 "Richard Quadling" <rquadling@php.net> wrote: > rquadling Wed Feb 18 12:24:30 2009 UTC > > Modified files: (Branch: PHD_0_4) > /phd build.php > /phd/include PhDMediaManager.class.php PhDTheme.class.php > PhDThemeXhtml.class.php > Log: > Images are copied from XML structure to output(s). > > > http://cvs.php.net/viewvc.cgi/phd/build.php?r1=1.54.2.3.2.4&r2=1.54.2..3.2.5&diff_format=u > Index: phd/build.php > diff -u phd/build.php:1.54.2.3.2.4 phd/build.php:1.54.2.3.2.5 > --- phd/build.php:1.54.2.3.2.4 Tue Feb 17 19:04:47 2009 > +++ phd/build.php Wed Feb 18 12:24:30 2009 > @@ -1,6 +1,6 @@ > #!@php_bin@ > <?php > -/* $Id: build.php,v 1.54.2.3.2.4 2009/02/17 19:04:47 cweiske Exp $ */ > +/* $Id: build.php,v 1.54.2.3.2.5 2009/02/18 12:24:30 rquadling Exp $ */ > > /* {{{ Find the $ROOT directory of PhD > @php_dir@ will be replaced by the pear package manager > @@ -116,7 +116,7 @@ > $themes[$themename] = new $themename(array($IDs, $REFS, $CLASSES, $VARS)); > } > > - $themes[$themename]->postConstruct(); > + $themes[$themename]->postConstruct($OPTIONS["xml_root"]); > $themes[$themename]->registerFormat($format); > > > > http://cvs.php.net/viewvc.cgi/phd/include/PhDMediaManager.class.php?r1=1.1.2.2&r2=1.1.2.3&diff_format=u > Index: phd/include/PhDMediaManager.class.php > diff -u phd/include/PhDMediaManager.class.php:1.1.2.2 > phd/include/PhDMediaManager.class.php:1.1.2.3 > --- phd/include/PhDMediaManager.class.php:1.1.2.2 Wed Feb 11 20:30:24 2009 > +++ phd/include/PhDMediaManager.class.php Wed Feb 18 12:24:30 2009 > @@ -1,5 +1,5 @@ > <?php > -/* $Id: PhDMediaManager.class.php,v 1.1.2.2 2009/02/11 20:30:24 cweiske Exp $ */ > +/* $Id: PhDMediaManager.class.php,v 1.1.2.3 2009/02/18 12:24:30 rquadling Exp $ */ > > /** > * Handles images (and other media objects) referenced in the docbook files. > @@ -18,7 +18,7 @@ > public $output_dir = null; > > /** > - * Path the media files are referenced relative to in html. > + * Path the media files are referenced relative to in xml. > * Trailing slash required. > * > * @var string > @@ -48,12 +48,13 @@ > { > $basename = basename($filename); > $newname = md5(substr($filename, 0, -strlen($basename))) . '-' . $basename; > + > //FIXME: make images dynamic according to file type (e.g. video) > $newpath = 'images/' . $newname; > > - $this->copyOver($filename, $newpath); > + $this->copyOver($this->relative_path . $filename, $newpath); > > - return $this->relative_path . $newpath; > + return $newpath; > }//public function handleFile(..) > > > > http://cvs.php.net/viewvc.cgi/phd/include/PhDTheme.class.php?r1=1.1.10.3&r2=1.1.10.4&diff_format=u > Index: phd/include/PhDTheme.class.php > diff -u phd/include/PhDTheme.class.php:1.1.10.3 phd/include/PhDTheme.class.php:1.1.10.4 > --- phd/include/PhDTheme.class.php:1.1.10.3 Tue Feb 17 19:04:47 2009 > +++ phd/include/PhDTheme.class.php Wed Feb 18 12:24:30 2009 > @@ -1,5 +1,5 @@ > <?php > -/* $Id: PhDTheme.class.php,v 1.1.10.3 2009/02/17 19:04:47 cweiske Exp $ */ > +/* $Id: PhDTheme.class.php,v 1.1.10.4 2009/02/18 12:24:30 rquadling Exp $ */ > require $ROOT. "/include/PhDMediaManager.class.php"; > > abstract class PhDTheme extends PhDHelper implements iPhDTheme { > @@ -24,7 +24,7 @@ > * > * @see PhDThemeXhtml::postConstruct() > */ > - public function postConstruct() {} > + public function postConstruct($relative_path) {} > > > > > http://cvs.php.net/viewvc.cgi/phd/include/PhDThemeXhtml.class.php?r1=1.1.2.2&r2=1.1.2.3&diff_format=u > Index: phd/include/PhDThemeXhtml.class.php > diff -u phd/include/PhDThemeXhtml.class.php:1.1.2.2 phd/include/PhDThemeXhtml.class.php:1.1.2.3 > --- phd/include/PhDThemeXhtml.class.php:1.1.2.2 Wed Feb 18 09:36:16 2009 > +++ phd/include/PhDThemeXhtml.class.php Wed Feb 18 12:24:30 2009 > @@ -1,5 +1,5 @@ > <?php > -/* $Id: PhDThemeXhtml.class.php,v 1.1.2.2 2009/02/18 09:36:16 cweiske Exp $ */ > +/* $Id: PhDThemeXhtml.class.php,v 1.1.2.3 2009/02/18 12:24:30 rquadling Exp $ */ > > /** > * Base class for XHTML themes > @@ -37,9 +37,11 @@ > * Each theme needs its own media manager, since the manager contains > * the output path. > * > + * @param string $relative_path Path the media files are referenced relative to in xml. > + * > * @return void > */ > - public function postConstruct() > + public function postConstruct($relative_path) > { > $this->mediamanager = new PhDMediaManager(); > > @@ -47,8 +49,8 @@ > $this->mediamanager->output_dir = $this->outputdir; > } else { > $this->mediamanager->output_dir = $this->outputfile . > '-data/'; > - $this->mediamanager->relative_path = > basename($this->mediamanager->output_dir) . '/'; > } > + $this->mediamanager->relative_path = $relative_path . '/'; > }//public function postConstruct() > > > > > > -- > PHP Documentation Commits Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > -- Regards/Mit freundlichen Grüßen Christian Weiske

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