Phoca

Phoca

Upgrading Phoca Gallery

Important!

If you want to upgrade the Phoca Gallery component, don't uninstall the previous version, because while uninstalling the data stored in the database will be lost.

You can upgrade using two different methods. You can upgrade via the installer or you can upgrade via FTP.

 

Upgrade Phoca Gallery with help of  Joomla! Installer

Upgrade Phoca Gallery:

  • Extensions » Install/Uninstall. Now you are in Extensions Manager. Click on Upload Package File - select the Phoca Gallery component ZIP file from your disc and click on Upload File & Install.

Then you can choose between Install or Upgrade Phoca Gallery component. Select Upgrade. If you select Install, all previously stored Phoca Gallery data in your database will be removed.

If you are upgrading from 1.x to 2.x, then check if all 6 tables are created.
If you upgrade from 2.1.0 to 2.2.0 check the columns of your tables. See the MySQL update procedure

 

Upgrade Phoca Gallery via FTP

The following guide works only in Joomla! 1.5. See this article: How to install large components with help of FTP in Joomla! for upgrading in Joomla! 1.7 (1.6).

 

Some useful articles about FTP downloading and uploading:

Download the newest Phoca Gallery version from the Phoca Gallery download site. You get a ZIP file. Unzip this file into your temporary folder on your disc. You get these files and folders:

  • [assets]
  • [controllers]
  • [elements]
  • [front]
  • [help]
  • [helpers]
  • [language]
  • [libraries]
  • [models]
  • [other]
  • [tables]
  • [views]
  • admin.phocagallery.php
  • config.xml
  • controller.php
  • index.html
  • install.bak
  • install.sql
  • install.phocagallery.php
  • phocagallery.xml
  • uninstall.sql
  • uninstall.phocagallery.php

Copy all files and folders except folders: front, language, other into:

  • your-server/administrator/components/com_phocagallery/

Copy all files and folders from folder front into:

  • your-server/components/com_phocagallery/

Copy all files and folders from folder language into:

  • your-server/language/
  • your-server/administrator/language/

While copying your files you need to accept the overwritting previously installed files.

 

Updating the MySql database after a manual upgrade

If you are upgrading Phoca Gallery with help of FTP method, you need to be aware as in new version there can be new database tables or new columns in database tables.

You need to open the install.bak file which you can find in root of the installation ZIP file and compare it with your database. E.g. with help of phpMyAdmin tool. In install.bak file you can see which new tables and columns were added in previous versions. So if some table doesn't exists in your database and you can see the SQL query for this table in install.bak file, just run this query (query for creating one table) so this table will be added into your database (Don't run all the queries as they can overwrite your current data in your site, which means deleting all your data).

You can see the upgrade sql queries too (upgrading columns in tables). If you compare the table in your database with SQL query of the install.bak file and you will recognize that some columns don't exists in your tables, you need to run the SQL upgrade queries (which are prepared at the end of the install.bak file). After copying and pasting the queries into phpMyAdmin you need to remove comments characters (-- at the begin of the line) and you need to modify the prefixes.

Upgrading the tables:

Because the names of tables are prepared for system installation, so they contain '#__' instead of your table prefix, you have to rename them:

  • #__phocagallery to TablePrefix_phocagallery
  • #__phocagallery_categories to TablePrefix_phocagallery_categories, etc.

TablePrefix is the prefix you selected while installing Joomla! CMS (it is mostly 'jos_' and it should differentiate the Joomla! tables from other tables used in your database). Make sure that you delete #_ at the start of the line; you only need one _ {underscore}.

Upgrading the columns:

If you have all tables in your database (e.g. you are upgrading from 2.1.0 to 2.2.0) check the columns of your tables. E.g. in Phoca Gallery version 2.2.0 there are new colums: extlink1, extlink2 and these should be added into table: #__phocagallery. In case you are upgrading e.g. from 2.1.0 to 2.2.0 and you got some error message while automatically upgrading of Phoca Gallery tables, check the #_phocagallery table and if extlink1 or extlink2 columns aren't included, then run the SQL query for 2.2.0 version:

ALTER TABLE `#__phocagallery` ADD `extlink1` text NOT NULL AFTER `params` ;
ALTER TABLE `#__phocagallery` ADD `extlink2` text NOT NULL AFTER `extlink1` ;

If you're upgrading to 2.2.2 then run also the SQL query for the 2.2.2 version:

ALTER TABLE `#__phocagallery_categories` ADD `date` datetime NOT NULL default '0000-00-00 00:00:00' AFTER `description` ;

Important!!! - You cannot upgrade this way if your current version is earlier than 1.3.0, because Phoca Gallery has own categories behaviour (new table for Phoca Gallery categories in database) from version 1.3.0.
Important for 1.x versions!

After upgrading a component, default settings will be set to default (it means that e.g. Pagination will be disabled, ...). You must set parameters in default settings again. Parameters components in menu links will be not changed. If you use SEF, menu links will be invalid and you must refresh them. If you want to fix the settings just go to the Menu and click on the Phoca Gallery menu link. You are now in in Menu Item [edit]. Click on Save button. Phoca Gallery menu link will be refreshed - SEF will work again and e.g. Pagination will be displayed.). If this is a problem (maybe you have a lot of menu links), you must upgrade via FTP.

 

 

Phoca News Gadget

Phoca Facebook Phoca on Facebook:
Phoca Twitter Phoca on Twitter:
Phoca - Follow us on Twitter
Phoca Google Plus Phoca on Google+:
Phoca - Follow us on Google Plus
Phoca YouTube Phoca on YouTube:
Phoca on YouTube
Phoca Pinterest Phoca on Pinterest:
Phoca on Pinterest
Phoca News Phoca News:
Phoca News RSS
Phoca Latest Files Phoca Latest Files:
Phoca News RSS

Phoca Forum - Latest Topics