Installing an old version

Permalink
Hi,
I need to install on my computer an old version of concrete5 (5.6.3) to recreate an old site (I've got the files and the database backup).
During the installation of Concrete5, I get some warnings like this one :
Warning: Declaration of Concrete5_Model_AddBlockBlockTypePermissionAccess::save($args) should be compatible with Concrete5_Model_PermissionAccess::save() in /var/www/html/site/concrete/core/models/permission/access/categories/custom/add_block.php on line 3
And I can't go further in the installation process.
Could it be a problem of php version (on my lamp server it's php 7) ?
Is it possible to fix this problem ?
Thanks,
Vincent

 
JohntheFish replied on at Permalink Reply
JohntheFish
This is almost certainly what you suggest, that your new system is running php7.

You have a couple of choices:

1. Use the latest 5.6.x core from GitHub, which is php7 compatible and import the old site. You may have to fix some php incompatibilities in code other than the core. You may also need to patch some data. So only try this if you are happy doing code fixes.

2. Find a way of running the site under php5.6. How you do that depends a lot on your system and whether you will also need to run php7 for the latest c5 core. Safest would be to setup a virtual machine for running and working on the old site.
vlemieux replied on at Permalink Reply
Hi,
In a Windows 7 virtualized, I installed again a wamp server who didn't want to change the php version. After reinstallation I could choose php 5.6.
A database was created with phpmyadmin (utf8-general-ci)
I've copied the files of concrete 5.6.3.1 into www/site/ and started the installation of concrete5. But it hangs and I've got this message :

Unable to install database: Valeur par défaut invalide pour 'avDateAdded'

(Valeur par défaut invalide = "the default value is not valide)

An idea about this new problem ?
Thanks
Vincent
JohntheFish replied on at Permalink Best Answer Reply
JohntheFish
Your new VM wamp MySQL could be set strict, when the old database was not strict.
vlemieux replied on at Permalink Reply
Thanks a lot !
For other readers, the solution :
Edit the my.ini file and search for the line
sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,
NO_ENGINE_SUBSTITUTION"

and remove the first argument (STRICT_TRANS_TABLES) :

sql-mode="NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"

Save the file.
Create a new database.

I'm gonna save the whole VirtualMachine before going on (moving the lod site files and importing it's database)

Vincent
vlemieux replied on at Permalink Reply 3 Attachments
Hi,
A new problem : when I try to import the old database in the new one I've got error listed in the three screenshots. Between the second and the third picture there is a lot of data...

Picture "error1.png" :
"1 erreur trouvée lors de l'analyse" means "one error found during analysis"
"expression manquante" means "missing expresion"

When importing the database I have to set the codage of the improrted file : is the backup file created inside Concrete (dbu_xx...xx.sql) coded in utf8 ?

Vincent
JohntheFish replied on at Permalink Reply
JohntheFish
The backup file should be utf8_general_ci because that is the encoding/collation the original site should have been created with and the new database should have been created with. However, I often come across sites where the encoding is different.

Rather than using phpMyAdmin to import your database, try using the MySQL CLI. It won't run into timeouts .
https://stackoverflow.com/questions/17666249/how-to-import-an-sql-fi...

Some developers have found it helps to disable foreign key checks when importing.
vlemieux replied on at Permalink Reply
Hi,
At least the import of the database is Ok !
I've used Adminer, but before I had to increase some values in php config and mysql ini (like post_max_size , upload_max_file_size , max_execution_time, max_allowed_packet )

I just have (a last ?) problem :
this adress doesn't work :http://localhost/site/la-boite-idees/physique-au-quotidien/musique/
but if I insert "index.php" behind :http://localhost/site/ which is the entry of the site :
http://localhost/site/index.php/la-boite-idees/physique-au-quotidie...
the page is reached.

Best regards

Vincent
vlemieux replied on at Permalink Reply
The last problem came from the .htaccess file which wasn't pasted

Vincent