0

ローカル サーバーをリモートに移行した後、上記のエラーが発生します。joomla を最新の 2.5.10 にアップグレードしましたが、まだ同じエラーが発生します。どうすればこれを解決できますか? 以下は71行目のコードです

public function write($id, $data)
{
    // Get the database connection object and verify its connected.
    $db = JFactory::getDbo();//Line 71
    if (!$db->connected())
    {
        return false;
    }

    try
    {
        $query = $db->getQuery(true);
        $query->update($db->quoteName('#__session'))
        ->set($db->quoteName('data') . ' = ' . $db->quote($data))
        ->set($db->quoteName('time') . ' = ' . $db->quote((int) time()))
        ->where($db->quoteName('session_id') . ' = ' . $db->quote($id));

        // Try to update the session data in the database table.
        $db->setQuery($query);
        if (!$db->execute())
        {
            return false;
        }
        /* Since $db->execute did not throw an exception, so the query was successful.
        Either the data changed, or the data was identical.
        In either case we are done.
        */
        return true;
    }
    catch (Exception $e)
    {
        return false;
    }
}
4

1 に答える 1

1

この問題の唯一の解決策は、新しい joomla をインストールして再起動することです。その時点で私の古い joomla はまだ 2.5.9 だったので、新しい 2.5.10 アップグレード ファイルをダウンロードして、アップグレードしようとしました。

私がしたことは、新しいデータベースを作成し、joomla を新たにインストールすることだけでした。

于 2013-04-25T10:58:58.607 に答える