Support

Site Restoration

#20101 Merged links

Posted in ‘Site restoration’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

PHP version
n/a
CMS Type
Other
CMS Version
n/a
Backup Tool Version
n/a
Kickstart version
n/a

Latest post by nicholas on Thursday, 22 May 2014 06:14 CDT

user76251
Hi all,
after restoring my site... there are some errors

Some links on my site are wrong:
i.e. http://mysite.pl/imagesksiazkimoi_rodzice_marta_kaczynska.jpg
http://mysite.pl/templatesrt_hadronroksprocketlayoutsliststhemesdefaultlists.css

should be

http://mysite.pl/templates/rt_hadron/roksprocket/layouts/lists/themes/default/lists.css


How to do the "/"


on my site ?

nicholas
Akeeba Staff
Manager
Please make sure that your server does not have magic quotes enabled by default. This is a Joomla! requirement and has nothing to do with the restoration of your site.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user76251
That serwer had ON by defoult... but i had nad create php.ini befor restoration
with
magic_quotes_gpc = off

and warning disapears...

But can You, advice me something ? to repair that broken css, js links?

nicholas
Akeeba Staff
Manager
You need to restore the site again or edit the articles and change the broken links manually.

Let me explain what happens when magic quotes is on. When you edit an article and save it with magic quotes enabled your server will strip off all slashes, including those in pathnames. This is a lossy process, meaning that the original information (the article text with the slashes) is not retained. That is why you need to restore again or edit the affected articles manually.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user76251
Ok, Thank You for patient... for my problem...

I see i must to create special php.ini before restoration...

I will try again :) Thanks again! Akeeba

nicholas
Akeeba Staff
Manager
You're welcome :)

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

nicholas
Akeeba Staff
Manager
Oh, an important note. For your trick to work you have to follow these steps:
  1. Upload Kickstart and your archive
  2. Run Kickstart
  3. When the extraction is complete and before clicking on "Run the installer" upload your custom php.ini file inside the "installation" directory
  4. Now click on the "Run the installer" button
  5. When the restoration is complete close the installer's tab and click on Clean Up in Kickstart's tab.
  6. Now upload your custom php.ini in BOTH the site's root and its "administrator" directory.

If you don't do these steps in this exact sequence your custom php.ini file will be ignored by your server.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user76251
WOw that's exactly what I neeed!

noobsteps :P for me ... very very good because i was try to do it 4 times
.... but never thinking about "administrator " directory

HYHY :) Nicho rulez!

nicholas
Akeeba Staff
Manager
He he... It has a perfectly reasonable explanation that nobody has bothered telling you.

Your host is running PHP as CGI or FastCGI. If you want me to oversimplify it, this means that every time you try accessing a .php file on your server it will load PHP. PHP will immediately load its configuration first from its global php.ini file (which is out of your reach, this is what your host maintains) and a php.ini file in the same directory as the .php file being loaded.

Read again the last part of the previous sentence. It's the key to understanding what's going on!

In the front-end, Joomla! loads the index.php found in your site's root. Therefore, PHP will look for a php.ini inside your site's root.

In the back-end, Joomla! loads the index.php found in your site's "administrator" directory. Therefore, PHP will look for a php.ini inside the "administrator" directory.

When installing or restoring a Joomla! site, you load the index.php found in your site's "installation" directory. Therefore, PHP will look for a php.ini inside the "installation" directory.

And now you see why you needed to put the same file in three different places at different times in the restoration process. I'm pretty sure that now you understand a little better how your server works. Isn't it nice when what you do makes sense instead of sounding like a "magic" and arcane solution? :)

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user76251
Nonono :) i prefer magic like akeeba's programs and support !

Therfore, i must to try do some restoration again step by step :P

user76251
Still don't works
:(
when i upload php.ini i must also change php thru httaccess...

my php
error_log = /plik_logow.log
error_reporting = E_ALL & ~E_NOTICE
log_errors = 1
magic_quotes_gpc = Off
magic_quotes_runtime = Off
magic_quotes_sybase = Off
memory_limit = 64M
display_errors = on
extension=pdo.so
extension=pdo_mysql.so

my .httacces

:Location /*.php
Use php54
:Location
php_flag magic_quotes_gpc off
SetEnv PHPRC /php.ini


I did copy those 2 files- first to installation folder

then to root and aminnistrator ....


;/

nicholas
Akeeba Staff
Manager
You have to also follow a similar process:
  1. Upload Kickstart and your archive
  2. Run Kickstart
  3. When the extraction is complete and before clicking on "Run the installer" upload your custom php.ini file inside the "installation" directory and your custom .htaccess file in the site's root directory.
  4. Now click on the "Run the installer" button
  5. When the restoration is complete close the installer's tab and click on Clean Up in Kickstart's tab.
  6. Now upload your custom php.ini in BOTH the site's root and its "administrator" directory. Also re-upload your custom .htaccess file in the site's root.


If you are wondering why: during the extraction, Kickstart renames .htaccess to htaccess.bak to prevent the .htaccess from screwing up the extraction when transferring sites between different servers. When you click on the Clean Up button it does the inverse procedure, renaming htaccess.bak to .htaccess. This is why you need to upload the customised .htaccess file twice.

Morever, if you are using Admin Tools' .htaccess Maker on your site you MUST put the
php_flag magic_quotes_gpc off
SetEnv PHPRC /php.ini

directives in the custom code to add to the bottom of the file before clicking on "Save & Create .htaccess"

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user76251
Ok, im still out of solution...
So i will describe step by step what i done...

1. Clear all root and upload archive and kickstart
(file.jpa, kickstart.php, json2,jquery,cacert,pl-pl.kickstart)

2. Run kickstart
2a) kickstart extraction fails - so i must create bin folder - run kickstart again

3. Before click "run installation" button i was

-delete all .htaccess bak

- upload to root - .htaccess
:Location /*.php
Use php54
:Location
php_flag magic_quotes_gpc off
SetEnv PHPRC /installation/php.ini

-upload to installation folder - php.ini
error_log = /plik_logow.log
error_reporting = E_ALL & ~E_NOTICE
log_errors = 1
magic_quotes_gpc = Off
magic_quotes_runtime = Off
magic_quotes_sybase = Off
memory_limit = 64M
display_errors = on
extension=pdo.so
extension=pdo_mysql.so

4. AND RUNING and install
5. Cleaning
6. Upload php x 2 & htaccess

-upload to root & admin folder - php.ini
error_log = /plik_logow.log
error_reporting = E_ALL & ~E_NOTICE
log_errors = 1
magic_quotes_gpc = Off
magic_quotes_runtime = Off
magic_quotes_sybase = Off
memory_limit = 64M
display_errors = on
extension=pdo.so
extension=pdo_mysql.so

upload .htaccess to root

:Location /*.php
Use php54
:Location
php_flag magic_quotes_gpc off
SetEnv PHPRC /php.ini


-------------------------------------------------

DOne but still some links are broken :(
Im almost surrender i thinking im stupid !

nicholas
Akeeba Staff
Manager
I have a suspicion. Can you restore the backup locally, e.g. on XAMPP? Do you still get broken links?

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user76251
Hmmm i never did ... but I willl try ! to clear Your suspicions ....

hmmm... please wait a minute :)

user76251
Ok i did it.... I do nothing with php.ini htacces ttricks...

Just upload and instal on localhost -

Everything works just fine
(some angie warnings during installation php 54 to 5.5 on new xamp)

All works fine on localhost

I think i need to argue with my client's host provider....

:( or mayby Your suspicions

nicholas
Akeeba Staff
Manager
Yep, you need to have a talk with your client's host. They need to provide you with a viable way to disable magic quotes without using a .htaccess or php.ini file inside your site as this seems to be not working.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!