Wordpress File Problem


#1

I have a WP Multi-site install where I am getting errors on Media uploads. They are not getting the right URL and causing all sorts of problems. Can’t use them in my Avada theme and won’t display them in Media Library. Can only see file when I go to edit it.

This hasn’t happened on other multi-site installs with Reclaim using the same theme.

Cheers
Kimon


#2

Hi Kimon,

I edited your post to remove the URL since this is a public forum and it required a login to view. This is an issue I’ve brought up with Installatron and have an open ticket with them on and actually has nothing to do with the theme. Their multisite installs currently are somehow setup in a way where the .htaccess file used causes issues. The “fix” for now is to use the htaccess for version 3.4 and below at htaccess « WordPress Codex. Hopefully I can get them to fix their install (all I can assume is that maybe they are using old versions of core WordPress files and then updating them so the htaccess has to be different as a result). I made this fix in your install so you should be seeing media uploads now.


#3

That did it! I was wondering why it started working. I thought it might be an Installation wonkiness since it hasn’t happened to me before in other circumstances doing multi-site or with Avada. Good luck getting them to tweak it!

As always you guys are amazing. Thanks for the quick fix. Less than ten minutes. Wow!


#4

This has reared its head again on another install (still within NYU hosting). Tried to fix with htaccess 3.4 like you mentioned and it broke the subdirectory site (was using the correct htaccess code). Tried to revert to 3.5 and site was still broken.

Threw my hands up and deleted the entire WP installation and reinstalled. Now getting this error after installation and can’t get to new install at all:

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@kimon.hosting.nyu.edu to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.


#5

Ugh, Installatron has promised me they have a fix in the works that they’ll be releasing soon. In the short term can you send me the URL you’re working from? PM is fine.


#6

Here is the URL: Making Room for Youth – American Hardcore Punk, a most recent example of art movements throughout history


#7

Sites that are installed to a subfolder have a little bit extra in .htaccess from the default in the Codex. Instead of:

# BEGIN WordPress
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]

# uploaded files
RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]

# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]

RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^[_0-9a-zA-Z-]+/(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^[_0-9a-zA-Z-]+/(.*\.php)$ $1 [L]
RewriteRule . index.php [L]
# END WordPress

you have to change the second and last line to add the folder name it’s installed in, in this case sites

# BEGIN WordPress
RewriteEngine On
RewriteBase /sites/
RewriteRule ^index\.php$ - [L]

# uploaded files
RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]

# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]

RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^[_0-9a-zA-Z-]+/(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^[_0-9a-zA-Z-]+/(.*\.php)$ $1 [L]
RewriteRule . sites/index.php [L]
# END WordPress

This is now fixed for that install.


#8

Went to fix this for my kimonkeramidas.com install but I think Installatron did something funky with that one. Don’t want to attempt to fix .htaccess and screw things up. Also in the above example I don’t think you ever changed the code after you pasted it.


#9

Is something not working with that site? I see media uploads in a subsite without issue. Sorry about the code in previous message, edited to fix.