Upgrade Concrete versions 9.3.1 and 9.3.2

Sep 10, 2024
By myq for Developers

Problem

When trying to upgrade from Concrete versions 9.3.1 and 9.3.2 through the dashboard, you may encounter the following error message:

The directory /www/public_html/updates/ already exists. Perhaps this item has already been installed.

However, if you delete the updates/ directory, you will get another error about not being able to find the updates/ directory. How can you get past this catch-22?

There are two ways:

  1. patch the relevant code, or
  2. manually download the update

Patch the relevant code

  1. Find the directory holding the currently used Concrete core. If you have ever updated Concrete through the dashboard, the directory is going to be in the updates/ directory and will likely be the most recently modified directory or the directory with the latest version in the name. If you are unsure, check the value of the core key in application/config/update.php which should match the name of one of the directories.

    If you have never updated through the Dashboard, then the directory is probably concrete/.

  2. Within the directory identified in the previous step, find the following file: concrete/controllers/single_page/dashboard/system/update/update.php.
  3. Make the following 3 changes described here:

    Line 120: change $file = uniqid(time(), true) . '.zip'; to
    $file = uniqid(time(), true);
    Line 124: change RequestOptions::SINK => $location . '/' . $file, to RequestOptions::SINK => $location . '/' . $file . '.zip',
    Line 138: change $ar->install($location . '/' . $file); to
    $ar->install($file);

  4. Go to the Dashboard > System & Settings > Update Concrete and select "Install Update".

manually download the update

  1. Download the latest version of the Concrete core here: https://www.concretecms.com/latest.zip.
  2. Unzip the archive into the updates/ directory.
  3. Either delete application/config/update.php or change the value of the core key inside of that file to match the name of the directory that you just decompressed in the updates/ directory.
  4. Go to the Dashboard > System & Settings > Update Concrete and select "Install Update".
Recent Tutorials
Redirect all requests to HTTPS
Oct 9, 2024
By myq.

How to follow best practices for a secure web

Upgrade Concrete versions 9.3.1 and 9.3.2
Sep 10, 2024
By myq.

How to get past a bug in versions 9.3.1 and 9.3.2 that prevents upgrading the Concrete core through the Dashboard

How to use Composer with Marketplace extensions
Aug 22, 2024

Composer can be used to manage third-party extensions from the marketplace

Controlling Google Tag Manager Tags Based on Concrete CMS Edit Toolbar Visibility
Aug 13, 2024

This document provides a step-by-step guide on how to control the firing of Google Tag Manager (GTM) tags based on the visibility of the Concrete CMS edit toolbar. It explains how to create a custom JavaScript variable in GTM to detect whether the edit toolbar is present on a page and how to set up a trigger that ensures GTM tags only fire when the toolbar is not visible. This setup is particularly useful for developers and marketers who want to ensure that tracking and analytics tags are not activated during content editing sessions, thereby preserving the accuracy of data collected.

Upgrading Concrete from 8.5 to 9.x
Jun 21, 2024
By myq.

How to avoid problems upgrading from 8.5 to 9.x

How to change the default date format
May 30, 2024
By myq.

Change the format of the default date

Improvements?

Let us know by posting here.