2.1.* - 2.2.2 upgrade - gallery now completely garbled !

jsnielsen

Joined: 2006-06-02
Posts: 7
Posted: Tue, 2007-07-10 10:29

Hello,

I wanted to upgrade from 2.1.* to 2.2.2, and downloaded the recommended full package. Unzipped it,
uploaded it to overwrite the existing files, and wanted to go to http://www.fantastisk.net/gallery2
to start the upgrade process, as stated at the upgrade section of the gallery site.

But - when I do that, I get this:

Quote:
h = $months[gmstrftime('%m', $time)]; $out = gmstrftime('%%s, %d %%s %Y %H:%M:%S GMT', $time); return sprintf($out, $dow, $month); } /** * Check if Gallery is in embedded mode * * @return boolean true if Gallery is in embedded mode, false otherwise */ function isEmbedded() { return GalleryDataCache::containsKey('G2_EMBED') && GalleryDataCache::get('G2_EMBED'); } /** * Add an action to be performed at the end of the request. * * @param callback $callback * @param array $parameters */ function addShutdownAction($callback, $parameters) { if (!isset($this->_shutdownActions)) { $this->_shutdownActions = array(); } $action = array($callback, $parameters); /* Skip duplicate actions */ foreach ($this->_shutdownActions as $item) { if ($item == $action) { $duplicate = true; break; } } if (!isset($duplicate)) { $this->_shutdownActions[] = $action; } } /** * Process registered shutdown actions. */ function performShutdownActions() { if (isset($this->_shutdownActions)) { foreach ($this->_shutdownActions as $action) { $ret = @call_user_func_array($action[0], $action[1]); if ($this->getDebug() || class_exists('GalleryTestCase')) { /* Ignore errors unless debug is on */ if (is_array($ret) && GalleryUtilities::isA($ret[0], 'GalleryStatus')) { $ret = $ret[0]; } else if (!GalleryUtilities::isA($ret, 'GalleryStatus')) { $ret = null; } if (isset($ret) && $ret) { $this->debug('Error from shutdown action:'); $this->debug_r($action); $this->debug_r($ret); } } } } } /** * Return our PHP virtual machine abstraction * * @return object GalleryPhpVm */ function getPhpVm() { if (!isset($this->_phpVm)) { GalleryCoreApi::requireOnce('modules/core/classes/GalleryPhpVm.class'); $this->_phpVm = new GalleryPhpVm(); } return $this->_phpVm; } } ?> anonymousUser'); if ($ret) { return $ret; } list ($ret, $acceleration) = GalleryCoreApi::getPluginParameter('module', 'core', 'acceleration'); if ($ret) { return $ret; } $acceleration = unserialize($acceleration); list ($ret, $isAnonymous) = GalleryCoreApi::isAnonymousUser(); if ($ret) { return $ret; } $expiration = $acceleration[$isAnonymous ? 'guest' : 'user']['expiration']; $phpVm = $gallery->getPhpVm(); $cutoff = $phpVm->time() - $expiration; /* Use UPDATE instead of DELETE since UPDATE is faster and we reuse the rows. */ $storage =& $gallery->getStorage(); if ($isAnonymous) { $userIdForSql = (int)$anonymousUserId; } else { $userIdForSql = new GallerySqlFragment('<> ?', (int)$anonymousUserId); } list ($ret, $results) = GalleryCoreApi::updateMapEntry('GalleryCacheMap', array('userId' => $userIdForSql, 'timestamp' => new GallerySqlFragment('< ?', (int)$cutoff), 'isEmpty' => 0), array('value' => null, 'isEmpty' => 1)); if ($ret) { return $ret; } return null; } } ?> * * PHP versions before PHP 4.4.2 / PHP 5.1.2 allowed for HTTP header injection (HTTP RS). * This function ensures that servers running older PHP versions are protected as well. * * @param string $header * @return bool true if the given header is safe */ function isSafeHttpHeader($header) { if (!is_string($header)) { return false; } /* Don't allow plain occurrences of CR or LF */ if (strpos($header, chr(13)) !== false || strpos($header, chr(10)) !== false) { return false; } /* Don't allow (x times) url encoded versions of CR or LF */ if (preg_match('/%(25)*(0a|0d)/i', $header)) { return false; } return true; } } ?> on.use_trans_sid to mitigate performance-penalty * (do it before any output is started) */ if (!defined('SID')) { @ini_set('session.use_trans_sid', 0); } ?> on =& $gallery->getSession(); $navData = $session->getNavigation($this->_navId); return (count($navData) > 0); } /** * Get a list of navigation links to go back to where we came from. * * @param int $depth set this to get links back to a certain depth * @return array ( object GalleryStatus a status code, * array of navigational links: array('url' => ..., * 'name' => 'Back to ...')) */ function getNavigationLinks($depth=null) { global $gallery; if (empty($this->_navId)) { return array(null, array()); } list ($ret, $core) = GalleryCoreApi::loadPlugin('module', 'core'); if ($ret) { return array($ret, null); } $session =& $gallery->getSession(); $navData = $session->getNavigation($this->_navId); $links = array(); $i = 0; foreach ($navData as $navItem) { $i++; if (isset($depth) && $i > $depth) { break; } $url = $navItem['returnUrl']; $params = array('fromNavId' => $this->_navId); if (isset($navItem['returnNavId'])) { $params['navId'] = $navItem['returnNavId']; } if (!empty($navItem['returnName'])) { $name = $core->translate(array('text' => 'Back to %s', 'arg1' => $navItem['returnName'])); } else { $name = $core->translate('Back'); } $url = GalleryUrlGenerator::appendParamsToUrl($url, $params); $links[] = array('url' => $url, 'name' => $name); } return array(null, $links); } /** * Decide whether to include session id in the URL. * * Force the session id in the URL for embedded DownloadItem URLs if the cookie.path plugin * parameter is not set. See GallerySession::init for details * * @param array $params (string param) * @return boolean forceSessionId * @access protected */ function embedForceSessionId($params) { if (isset($params['view']) && $params['view'] == 'core.DownloadItem' && GalleryUtilities::isEmbedded() && empty($this->_isCookiePathConfigured)) { /* * It is assumed that the Gallery session is initiated before generateUrl() is called * for the first time */ return true; } else { return false; } } } ?>
Warning: Cannot modify header information - headers already sent by (output started at /usr/home/dan13478/public_html/gallery2/modules/core/classes/Gallery.class:979) in /usr/home/dan13478/public_html/gallery2/index.php on line 50
Location: ' . $urlGenerator->makeUrl($path)); ?>

When I go to http://www.fantastisk.net/gallery2/upgrade, I get this:

Quote:
'gallery2_upgrade'); } } function _startDebugLog($header) { global $gallery; $gallery->setDebug('logged'); if (!isset($_SESSION['debugLogFile'])) { $dataBase = $gallery->getConfig('data.gallery.base'); $tag = substr(md5(microtime() . rand(1, 32767)), 0, 10); $_SESSION['debugLogFile'] = $dataBase . '/upgrade_' . $tag . '.log'; } $gallery->setDebugLogFile($_SESSION['debugLogFile']); $gallery->debug("\n\n--------------------------------------------------------\n\t$header\n" . "--------------------------------------------------------\n\n"); } } ?> h = $months[gmstrftime('%m', $time)]; $out = gmstrftime('%%s, %d %%s %Y %H:%M:%S GMT', $time); return sprintf($out, $dow, $month); } /** * Check if Gallery is in embedded mode * * @return boolean true if Gallery is in embedded mode, false otherwise */ function isEmbedded() { return GalleryDataCache::containsKey('G2_EMBED') && GalleryDataCache::get('G2_EMBED'); } /** * Add an action to be performed at the end of the request. * * @param callback $callback * @param array $parameters */ function addShutdownAction($callback, $parameters) { if (!isset($this->_shutdownActions)) { $this->_shutdownActions = array(); } $action = array($callback, $parameters); /* Skip duplicate actions */ foreach ($this->_shutdownActions as $item) { if ($item == $action) { $duplicate = true; break; } } if (!isset($duplicate)) { $this->_shutdownActions[] = $action; } } /** * Process registered shutdown actions. */ function performShutdownActions() { if (isset($this->_shutdownActions)) { foreach ($this->_shutdownActions as $action) { $ret = @call_user_func_array($action[0], $action[1]); if ($this->getDebug() || class_exists('GalleryTestCase')) { /* Ignore errors unless debug is on */ if (is_array($ret) && GalleryUtilities::isA($ret[0], 'GalleryStatus')) { $ret = $ret[0]; } else if (!GalleryUtilities::isA($ret, 'GalleryStatus')) { $ret = null; } if (isset($ret) && $ret) { $this->debug('Error from shutdown action:'); $this->debug_r($action); $this->debug_r($ret); } } } } } /** * Return our PHP virtual machine abstraction * * @return object GalleryPhpVm */ function getPhpVm() { if (!isset($this->_phpVm)) { GalleryCoreApi::requireOnce('modules/core/classes/GalleryPhpVm.class'); $this->_phpVm = new GalleryPhpVm(); } return $this->_phpVm; } } ?> anonymousUser'); if ($ret) { return $ret; } list ($ret, $acceleration) = GalleryCoreApi::getPluginParameter('module', 'core', 'acceleration'); if ($ret) { return $ret; } $acceleration = unserialize($acceleration); list ($ret, $isAnonymous) = GalleryCoreApi::isAnonymousUser(); if ($ret) { return $ret; } $expiration = $acceleration[$isAnonymous ? 'guest' : 'user']['expiration']; $phpVm = $gallery->getPhpVm(); $cutoff = $phpVm->time() - $expiration; /* Use UPDATE instead of DELETE since UPDATE is faster and we reuse the rows. */ $storage =& $gallery->getStorage(); if ($isAnonymous) { $userIdForSql = (int)$anonymousUserId; } else { $userIdForSql = new GallerySqlFragment('<> ?', (int)$anonymousUserId); } list ($ret, $results) = GalleryCoreApi::updateMapEntry('GalleryCacheMap', array('userId' => $userIdForSql, 'timestamp' => new GallerySqlFragment('< ?', (int)$cutoff), 'isEmpty' => 0), array('value' => null, 'isEmpty' => 1)); if ($ret) { return $ret; } return null; } } ?> * * PHP versions before PHP 4.4.2 / PHP 5.1.2 allowed for HTTP header injection (HTTP RS). * This function ensures that servers running older PHP versions are protected as well. * * @param string $header * @return bool true if the given header is safe */ function isSafeHttpHeader($header) { if (!is_string($header)) { return false; } /* Don't allow plain occurrences of CR or LF */ if (strpos($header, chr(13)) !== false || strpos($header, chr(10)) !== false) { return false; } /* Don't allow (x times) url encoded versions of CR or LF */ if (preg_match('/%(25)*(0a|0d)/i', $header)) { return false; } return true; } } ?> on.use_trans_sid to mitigate performance-penalty * (do it before any output is started) */ if (!defined('SID')) { @ini_set('session.use_trans_sid', 0); } ?> ssion; } /** * Returns the authentication token associated with this session. * @return string the authentication token */ function getAuthToken() { $authToken = $this->get('core.authToken'); if (empty($authToken)) { global $gallery; $phpVm = $gallery->getPhpVm(); $authToken = substr($phpVm->md5(uniqid(microtime() . mt_rand())), 0, 12); $this->put('core.authToken', $authToken); } return $authToken; } /** * Checks the given authentication token and resets the internal token on failure. * @param string $authToken Authentication token to be verified * @return bool true if the given */ function isCorrectAuthToken($authToken) { $internalAuthToken = $this->get('core.authToken'); if (empty($authToken) || empty($internalAuthToken) || strcmp($internalAuthToken, $authToken)) { $this->put('core.authToken', null); return false; } else { return true; } } } /** * Get the active user from the session's user id. * @package GalleryCore * @subpackage Classes */ class SessionAuthPlugin /* extends GalleryAuthPlugin */ { /** * @see GalleryAuthPlugin::getUser */ function getUser() { global $gallery; $session =& $gallery->getSession(); $userId = $session->getUserId(); if (!empty($userId)) { list ($ret, $user) = GalleryCoreApi::loadEntitiesById($userId); /* ERROR_MISSING_OBJECT check to suppress error if user id doesn't exist */ if ($ret && !($ret->getErrorCode() & ERROR_MISSING_OBJECT)) { return array($ret, null); } return array(null, $user); } } } ?> } } ?> ata['authFileErrors']['missing'] = 1; } else if (!is_readable($authFile)) { $templateData['authFileErrors']['unreadable'] = 1; } else { $authKeyFromFile = trim(join('', file($authFile))); if ($authKeyFromFile == $templateData['authKey']) { GallerySetupUtilities::authenticateThisSession(); } else { $templateData['authFileErrors']['mismatch'] = 1; } } $templateData['renderType'] = 'loginTxtForm'; } else { if (isset($_POST['password_sent'])) { if (empty($_POST['password'])) { $templateData['error']['password'] = _('Error: missing password.'); } else if ($_POST['password'] != $gallery->getConfig('setup.password')) { $templateData['error']['password'] = _('Error: invalid password.'); GallerySetupUtilities::setLoginAttempts(++$attempts); if ($attempts > G2_SUPPORT_MAX_LOGIN_ATTEMPTS) { GallerySetupUtilities::notifySiteAdministrator(); } } else { GallerySetupUtilities::authenticateThisSession(); } } $templateData['renderType'] = 'password'; } if (GallerySetupUtilities::isSessionAuthenticated()) { $this->setComplete(true); } } if ($this->isComplete()) { $templateData['bodyFile'] = 'AuthenticateSuccessful.html'; } else { $templateData['bodyFile'] = 'AuthenticateRequest.html'; } } } ?> eturn boolean success */ function _checkStorageSubDirectory($dirname, &$tested, $max) { global $gallery; $platform =& $gallery->getPlatform(); if (!($fd = $platform->opendir($dirname))) { return false; } while (($filename = $platform->readdir($fd)) !== false && $tested < $max) { if (!strcmp($filename, '.') || !strcmp($filename, '..')) { continue; } $tested++; $path = $dirname . $platform->getDirectorySeparator() . $filename; if (!$platform->is_link($path) && (!$platform->is_writeable($path) || !$platform->is_readable($path))) { return false; } if ($platform->is_dir($path) && $tested < $max) { /* Threshold not yet reached, check subdirectory tree */ if (!SystemChecksStep::_checkStorageSubDirectory($path, $tested, $max)) { return false; } } } $platform->closedir($fd); return true; } function CheckManifest(&$statusMonitor, $useSetTimeLimit) { $base = realpath(dirname(__FILE__) . '/../..') . '/'; if ($useSetTimeLimit) { set_time_limit(180); } $manifest = GalleryUtilities::readManifest(); if (empty($manifest)) { return null; } if (isset($statusMonitor)) { $statusMonitor->renderStatusMessage(_('Performing system checks'), '', 0.1); } if ($useSetTimeLimit) { set_time_limit(180); } $missing = $modified = $shouldRemove = array(); $stepSize = max((int)(count($manifest) / 22), 1); $i = 0; foreach ($manifest as $file => $info) { $i++; if ($file == 'MANIFEST') { continue; } $path = $base . $file; if ($i % $stepSize == 0) { if (isset($statusMonitor)) { $statusMonitor->renderStatusMessage(_('Performing system checks'), '', 0.12 + $i / $stepSize * 0.04); } if ($useSetTimeLimit) { set_time_limit(180); } } if (!empty($info['removed'])) { if (file_exists($path)) { $shouldRemove[] = $file; } } else if (!file_exists($path)) { $missing[] = $file; } else { /* * Use size comparison instead of checksum for speed. We have * two sizes, one calculated with unix eols, one with windows eols. */ $actualSize = filesize($path); if ($actualSize != $info['size'] && $actualSize != $info['size_crlf']) { /* This can be useful debug info */ if (false) { printf("%s (expected: %s/%s, actual: %s)
", $file, $info['size'], $info['size_crlf'], $actualSize); } $modified[] = $file; } } } return array('missing' => $missing, 'modified' => $modified, 'shouldRemove' => $shouldRemove); } } ?> uginId) { $this->_pluginId = $pluginId; } function getId() { return $this->_pluginId; } } class MockModule extends GalleryModule { function MockModule($pluginId) { $this->_pluginId = $pluginId; } function getId() { return $this->_pluginId; } } '); foreach (array('theme' => 'MockTheme', 'module' => 'MockModule') as $type => $className) { if (empty($deactivatedPlugins[$type])) { continue; } foreach ($deactivatedPlugins[$type] as $pluginId) { $plugin = new $className($pluginId); list ($ret, $ignored) = $plugin->deactivate(false); if ($ret) { $this->resetL10Domain(); if ($type == 'theme') { $templateData['errors'][] = sprintf(_('Unable to deactivate the %s theme'), $pluginId); } else { $templateData['errors'][] = sprintf(_('Unable to deactivate the %s module'), $pluginId); } $templateData['stackTrace'] .= $ret->getAsHtml(); } } } $templateData['groupedModules'] =& $groupedModules; $templateData['groupLabel'] = $groupLabel; $templateData['groupType'] = $groupType; $templateData['pluginIsUpgradeable'] = $pluginIsUpgradeable; $templateData['currentVersion'] = $currentVersion; $templateData['bodyFile'] = 'UpgradeOtherModulesRequest.html'; $templateData['anyUpgradeable'] = false; $templateData['deactivatedPlugins'] = $deactivatedPlugins; $templateData['pluginIsCompatible'] = $pluginIsCompatible; if (!empty($templateData['errors'])) { $templateData['debug'] = $gallery->getDebugBuffer(); } else if (!empty($pluginIsUpgradeable)) { foreach ($pluginIsUpgradeable as $pluginType) { foreach ($pluginType as $tmp) { if ($tmp) { $templateData['anyUpgradeable'] = true; break; } } } if (!$templateData['anyUpgradeable']) { $this->setComplete(true); } } } function isRedoable() { return false; } function isOptional() { return true; } /** * Put GD at the end of the list so that it's the lowest priority toolkit. This is a hack, * that we should replace with a more sophisticated system in the future. * * Note: we do the same in the installer */ function _sortModules($a, $b) { if ($a == 'gd' && $b == 'gd') { return 0; } else if ($a == 'gd') { return 1; } else if ($b == 'gd') { return -1; } else { return strcmp($a, $b); } } } ?> $templateData['stackTrace'] .= $ret->getAsHtml(); } /* * Delete the install.log file that's left over from 2.0 and 2.0.1 installs * since it's in a known location and contains potential information leaks. */ $dataBase = $gallery->getConfig('data.gallery.base'); $legacyInstallLogPath = sprintf('%s/install.log', $dataBase); if ($platform->file_exists($legacyInstallLogPath)) { $platform->unlink($legacyInstallLogPath); } $templateData['bodyFile'] = 'CleanCache.html'; $this->setComplete(true); } } ?> } } ?>
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /usr/home/dan13478/public_html/gallery2/upgrade/UpgradeStep.class:122) in /usr/home/dan13478/public_html/gallery2/lib/support/GallerySetupUtilities.class on line 348

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /usr/home/dan13478/public_html/gallery2/upgrade/UpgradeStep.class:122) in /usr/home/dan13478/public_html/gallery2/lib/support/GallerySetupUtilities.class on line 348

Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /usr/home/dan13478/public_html/gallery2/upgrade/UpgradeStep.class:122) in /usr/home/dan13478/public_html/gallery2/lib/support/GallerySetupUtilities.class on line 75

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /usr/home/dan13478/public_html/gallery2/upgrade/UpgradeStep.class:122) in /usr/home/dan13478/public_html/gallery2/lib/support/GallerySetupUtilities.class on line 75
emplatedEmail($file, $data, $from, $to, $subject, $headers='') { GalleryCoreApi::requireOnce('modules/core/classes/helpers/MailHelper_simple.class'); return MailHelper_simple::sendTemplatedEmail($file, $data, $from, $to, $subject, $headers); } /** * Return an error status. * * Starting in GalleryCoreApi 7.4 we ignore the filename and line number. You still need to * provide them if you want to provide an error message. Next major API bump we'll remove the * fileName and lineNumber arguments. * * @param int $errorCode * @param string $fileName deprecated * @param string $lineNumber deprecated * @param string $errorMessage * @return object GalleryStatus an error status */ function error($errorCode, $fileName='ignored', $lineNumber='ignored', $errorMessage=null) { GalleryCoreApi::requireOnce('modules/core/classes/GalleryStatus.class'); $status = new GalleryStatus(GALLERY_ERROR | $errorCode, $errorMessage); $status->setStackTrace(debug_backtrace()); return $status; } /** * Update entries in a map * * @param string $mapName the map we're working on * @param array $match the entries to match * @param array $change the values to change * @return object GalleryStatus a status code */ function updateMapEntry($mapName, $match, $change) { global $gallery; if (sizeof($match) == 0 || sizeof($change) == 0) { return GalleryCoreApi::error(ERROR_BAD_PARAMETER); } $storage =& $gallery->getStorage(); $ret = $storage->updateMapEntry($mapName, $match, $change); if ($ret) { return $ret; } return null; } /** * Get entries in a map that match a criteria and return selected fields * * @param string $mapName the map we're working on * @param array $select the columns to return * @param array $match the entries to match * @param array $optional optional arguments (eg. limit, orderBy) * array('limit' => array('count' => #, 'offset' => #), * 'orderBy' => array(columnName => ORDER_ASCENDING|ORDER_DESCENDING, ...)) * @return array object GalleryStatus a status code * array the results */ function getMapEntry($mapName, $select, $match=array(), $optional=array()) { global $gallery; if (empty($mapName) || empty($select) || !is_array($match) || !is_array($optional)) { return array(GalleryCoreApi::error(ERROR_BAD_PARAMETER), null); } $storage =& $gallery->getStorage(); list ($ret, $searchResults) = $storage->getMapEntry($mapName, $select, $match, $optional); if ($ret) { return array($ret, null); } return array(null, $searchResults); } /** * Remove entries from a map * * @param string $mapName the map we're working on * @param array $data an associative array of data about the entries to match * @return object GalleryStatus a status code */ function removeMapEntry($mapName, $data) { global $gallery; if (sizeof($data) == 0) { return GalleryCoreApi::error(ERROR_BAD_PARAMETER); } $storage =& $gallery->getStorage(); $ret = $storage->removeMapEntry($mapName, $data); if ($ret) { return $ret; } return null; } /** * Add a new entry to a map * * @param string $mapName the map we're working on * @param array $data an associative array of the entry data * @return object GalleryStatus a status code */ function addMapEntry($mapName, $data) { global $gallery; $storage =& $gallery->getStorage(); $ret = $storage->addMapEntry($mapName, $data); if ($ret) { return $ret; } return null; } /** * Remove ALL entries from this map.. use with caution! * * @param string $mapName * @return object GalleryStatus a status code */ function removeAllMapEntries($mapName) { global $gallery; $storage =& $gallery->getStorage(); $ret = $storage->removeAllMapEntries($mapName); if ($ret) { return $ret; } return null; } /** * Describe all the members of a map * * @param string $mapName * @param boolean $tryAllModules true if we should scan all modules, not just the active ones * @return array GalleryStatus a status code, * array member name => member type */ function describeMap($mapName, $tryAllModules=false) { global $gallery; $storage =& $gallery->getStorage(); list ($ret, $entityInfo) = $storage->describeMap($mapName, $tryAllModules); if ($ret) { return array($ret, null); } return array(null, $entityInfo); } /** * Describe the members, modules and parent of an entity * * @param string $entityName a class name * @param boolean $tryAllModules true if we should scan all modules, not just the active ones * @return array object GalleryStatus a status code * entity associative array */ function describeEntity($entityName, $tryAllModules=false) { global $gallery; $storage =& $gallery->getStorage(); list ($ret, $entityInfo) = $storage->describeEntity($entityName, $tryAllModules); if ($ret) { return array($ret, null); } return array(null, $entityInfo); } /** * Delete the fast download file for a specific entity * * @param int $entityId */ function deleteFastDownloadFileById($entityId) { GalleryCoreApi::requireOnce( 'modules/core/classes/helpers/GalleryEntityHelper_medium.class'); return GalleryEntityHelper_medium::deleteFastDownloadFileById($entityId); } /** * Create a small PHP file containing all the information we need to send a data item or * derivative to the browser. * Note that fast-downloads are only created for items with public permissions * * @param object $entity GalleryDataItem or GalleryDerivative object * @param bool $runEvenInUnitTest (optional) force this to run, even in the unit test framework * @return object GalleryStatus a status code */ function createFastDownloadFile($entity, $runEvenInUnitTest=false) { GalleryCoreApi::requireOnce( 'modules/core/classes/helpers/GalleryEntityHelper_medium.class'); return GalleryEntityHelper_medium::createFastDownloadFile($entity, $runEvenInUnitTest); } /** * Get id of the album to display by default. * @return array object GalleryStatus a status code * int album id */ function getDefaultAlbumId() { global $gallery; $defaultId = $gallery->getConfig('defaultAlbumId'); if (empty($defaultId)) { list ($ret, $defaultId) = GalleryCoreApi::getPluginParameter( 'module', 'core', 'id.rootAlbum'); if ($ret) { return array($ret, null); } } return array(null, (int)$defaultId); } /** * Get id of the guest user. * * @return array object GalleryStatus a status code * int user id */ function getAnonymousUserId() { global $gallery; $id = $gallery->getConfig('anonymousUserId'); if (empty($id)) { list ($ret, $id) = GalleryCoreApi::getPluginParameter('module', 'core', 'id.anonymousUser'); if ($ret) { return array($ret, null); } } return array(null, $id); } /** * Is the user a guest? * * @param int $userId id of user (default is current user) * @return array object GalleryStatus a status code * boolean true if anonymous */ function isAnonymousUser($userId=null) { if (empty($userId)) { global $gallery; $userId = $gallery->getActiveUserId(); } list ($ret, $anonymousId) = GalleryCoreApi::getAnonymousUserId(); if ($ret) { return array($ret, null); } return array(null, $userId == $anonymousId); } /** * Remove the given sort order from any thing in the framework that uses it * (albums and the default sort order). * * @param string $sortOrder * @return object GalleryStatus a status code */ function deleteSortOrder($sortOrder) { GalleryCoreApi::requireOnce( 'modules/core/classes/helpers/GalleryItemHelper_advanced.class'); return GalleryItemHelper_advanced::deleteSortOrder($sortOrder); } /** * Remove the given renderer from all items that are using it. * * @param string $rendererClassName * @return object GalleryStatus a status code */ function deleteRenderer($rendererClassName) { GalleryCoreApi::requireOnce( 'modules/core/classes/helpers/GalleryItemHelper_advanced.class'); return GalleryItemHelper_advanced::deleteRenderer($rendererClassName); } /** * Load template data for a theme settings form * * @param string $themeId if empty, site default theme is used * @param int $itemId * @param object GalleryTemplate $template * @param array $form * @return object GalleryStatus a status code */ function loadThemeSettingsForm($themeId, $itemId, &$template, &$form) { GalleryCoreApi::requireOnce('modules/core/classes/helpers/GalleryThemeHelper_medium.class'); return GalleryThemeHelper_medium::loadThemeSettingsForm( $themeId, $itemId, $template, $form); } /** * Load the block configuration files from every module * * @return array object GalleryStatus a status code * array block configurations */ function loadAvailableBlocks() { GalleryCoreApi::requireOnce('modules/core/classes/helpers/GalleryThemeHelper_medium.class'); return GalleryThemeHelper_medium::loadAvailableBlocks(); } /** * Handle theme settings form submission * * @param string $themeId if empty, site default theme is used * @param int $itemId * @param array $form form values * @return array object GalleryStatus a status code * array error messages * string localized status message */ function handleThemeSettingsRequest($themeId, $itemId, $form) { GalleryCoreApi::requireOnce('modules/core/classes/helpers/GalleryThemeHelper_medium.class'); return GalleryThemeHelper_medium::handleThemeSettingsRequest($themeId, $itemId, $form); } /** * Return true if this username is not allowed to log in (generally due to automated abuse). * The username doesn't have to correspond to a real user in the system. * * @param string $userName a username * @return array object GalleryStatus a status code * bool true if the account is disabled */ function isDisabledUsername($userName) { GalleryCoreApi::requireOnce('modules/core/classes/helpers/GalleryUserHelper_medium.class'); return GalleryUserHelper_medium::isDisabledUsername($userName); } /** * Get a list of entity members which are allowed to be shown / set by external systems (e.g. * via remote protocols like WebDAV, XML-RPC, etc). * This does not include any permission checking. * @param string $entityName name of the entity * @return array object GalleryStatus a status code * array(string memberName => * array('read' => boolean true if it's ok to show, * 'write' => boolean true if it's ok to set)) */ function getExternalAccessMemberList($entityName) { GalleryCoreApi::requireOnce( 'modules/core/classes/helpers/GalleryEntityHelper_medium.class'); return GalleryEntityHelper_medium::getExternalAccessMemberList($entityName); } } ?>
Fatal error: Call to undefined function: getpluginbasedir() in /usr/home/dan13478/public_html/gallery2/modules/core/classes/GalleryCoreApi.class on line 2762

Can you point me in the right direction, or possibly provide a solution ? :)


Gallery version (not just "2"): 2.2.2
PHP version (e.g. 4.3.11): 4.4.4
PHPInfo Link (see FAQ): http://www.fantastisk.net/gallery2/test.php
Webserver (e.g. Apache 1.3.33): Apache 1.3.37
Database (e.g. MySql 4.0.11): MySQL 4.0.26 Protocol 10
Activated toolkits (e.g. NetPbm, GD):
Operating system (e.g. Linux): Unix
Browser (e.g. Firefox 1.0): Firefox 2.0.0.4

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Tue, 2007-07-10 13:55

please upload your gallery2 folder again.
one or more files are obviously corrupt.

--------------
Documentation: Support / Troubleshooting | Installation, Upgrade, Configuration and Usage

 
jsnielsen

Joined: 2006-06-02
Posts: 7
Posted: Tue, 2007-07-10 14:00

I just remembered - I think I took the "light" version when I first installed the gallery. This time I uploaded the "Full" version. Can this error be a result of this ?

Will try to re-upload.

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Tue, 2007-07-10 14:55

no.

please reupload the full version. some of the gallery2 files on your webspace are corrupt.

--------------
Documentation: Support / Troubleshooting | Installation, Upgrade, Configuration and Usage