Re: PEAR_PackageUpdate: Strange behaviour of
| From: | Laurent Laville | Date: | Fri, 13 Jun 2008 21:57:51 +0000 |
| Subject: | Re: PEAR_PackageUpdate: Strange behaviour of | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-29008@lists.php.net to get a copy of this message | ||
Hello Jörg,
Did you try to check preferences saved (in your config file ppurc.ini or .ppurc ) and the package you want to update.
<code>
$ppu = PEAR_PackageUpdate::factory('Web', 'DB_DataObject', 'pear');
$prefs = $ppu->getPackagePreferences();
var_dump($prefs);
</code>
For example: If you have installed version 1.8.7 and check with these preferences below, then checkupdate() will return false
because latest version available is 1.8.8 (bug fix type) and your preferences is set to minor type release.
array
3 => string 'stable' (length=6)
2 => string 'minor' (length=5)
Laurent
Hi, i try to get the example script ppuWebExample2.php to work as is, but the only response i get is 'still alive'. It seems that if ( $ppu->checkUpdate() ) { ... } is unable to determine that there is a new version of a package. Replacing the condition by if (1) { ... } shows a nice update dialog. Any ideas? Jörg