Re: cvs: livedocs / livedoc.php

From: Date: Sun, 18 Apr 2004 16:37:03 +0000
Subject: Re: cvs: livedocs / livedoc.php
References: 1 2  Groups: php.doc 
Request: Send a blank email to phpdoc+get-969360172@lists.php.net to get a copy of this message
> > +/* Checks if translated file is updated */ > > +if ($lang != 'en' && !isset($using_fallback)) { > > + > > + if (preg_match('$Revision: 1.88 $', $file_revision, $matches)) { > > $Revision 1.88 exactly? Fixed in the source. CVS has replaced my rexesp automatically. > > + $lang_rev = $matches[1]; > > + } else { > > + $lang_rev = 0; > > + } > > + > > + /* get english file revision */ > > + $data = @file_get_contents(FALLBACK_BASE . $filename); > > + if (preg_match('/<!-- .Revision: \d+\.(\d+) . -->/', $data, $matches)) { > > + $en_rev = $matches[1]; > > + } else { > > + $en_rev = 0; > > + } > > The English file revision should be extracted from the $Revision value. > The English revision corresponding to the translated file should be > extracted from the EN-Revision header in the translated file. Your > extractions are not really doing this. > > Goba I think there is no $Revision var. livedocs has a variable, $file_revision that is the language revision. Then I open the english file and fetch the en revision. Whats wrong here? Nuno

« previous php.doc (#969360172) next »