1

As the title implies, I am working with a copy of a live Magento site that has been placed in a subdomain. We have applied a new theme and have done some other customizing. We are now trying to test it on the live server through a subdomain.

When I had first copy/pasted the entire folder we worked on into the subdomain, I went through the usual steps: uploading the database and deleting the local.xml. Those steps went flawlessly.

At the Magento installation wizard things went awry. It seemed as if CSS files weren't loading (no styling) as well as JS files (no functionality such as being able to click on the "continue" button.)

Using my browser's Web Console, I was able to see some of the problem files which mostly entailed the install.php file and various javascript files. I matched the permissions of these files up with the one's on the live public_html folder and matched the permissions.

Voila, install wizard was styled and functional. Went through the steps, no issues with database connection, etc. Now onto the Magento admin panel, we're having a similar issue. No styling at all but links are functional.

Now when viewing the site, it's the opposite. The new theme and styling are there but anything that seems to utilize javascript (animated text, home slider, etc) doesn't show up at all. As well as product images — however its dynamic text (description, names, etc) show up.

When I use Web Console on product pages this time, there are plenty more files that come up in errors. Half are CSS and JS. This time they don't pinpoint a specific file path since it generates per product page.

So my main question, was there something we could've done while uploading to the staging subdomain that would've retained the original permissions? Some way to match everything to the live site so that everything that should execute does?

Please feel free to let me know if I need to post screenshots or be more specific about the matter.

Thanks!

  • How did you copy to your staging system? By console, by rsync, by FTP? – Nicolas Sep 25 '15 at 5:53
  • We zipped the folder as a tar.gz using the OSX terminal. Copied that over via Cyberduck SFTP. Then extracted the folder within our server cpanel. Since posting, we've contacted our server provider and they were able to correct all the permissions. The test subdomain is now working — we are just trying to fix the small issues we already had locally. I'm still curious for future reference — is there a way to go about uploading our folder without changing the permissions, if possible? Considering we originally copied from the live site which already has the accurate permissions. – user1234567 Sep 25 '15 at 9:14
0

To be honest I'm not very familiar with OSX, although I know it's more or less based on linux/unix, so it should be possible to carry file permissions between the systems.

I guess your ZIP tool (probably you were using same kind of GUI app) should be able to take file permissions into account when zipping files. Check the options for that. Alternativly use a command line tool like gzip/tar with appropriate options like:

tar -cvfp file.tar folderToCompress

(see https://superuser.com/questions/838392/how-to-tar-a-directory-preserving-not-only-permissions-but-ownership-too; ignore the ownership thing)

Another, probably better way is to use rsync for such tasks, since it establishes a server-server connection and has a lot of other nice features (https://en.wikipedia.org/wiki/Rsync).

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.