Tag Info

Hot answers tagged

4

Here's the code from wp-admin/includes/file.php: if ( ! $method && function_exists('getmyuid') && function_exists('fileowner') ){ if ( !$context ) $context = WP_CONTENT_DIR; // If the directory doesn't exist (wp-content/languages) then use the parent directory // as we'll create it. if ( WP_LANG_DIR == $context ...


3

Okay here we go. It is a bug in WordPress itself. I have already shortly explained the issue in my question, so either have a look at it or check out the ticket linked above for more details. Until the issue is properly resolved I propose this dirty, dirty hack. It is based off the idea that as soon as another sub-menu that is accessible is added ...


2

Thanks @kaiser but not need to go through your solution I found a easy one and I'll share here for newbie likes me. If you're working on a WP Network site then the steps are: At the top, hover over My Sites and then click Network Admin. At the left, hover over Settings and then click Network Settings. Scroll to the bottom of the page and change the Max ...


2

This is more server config question than WordPress. Make sure the www-data group has write permissions in the directory you're running WordPress from. Assuming it's in /var/www/ then sudo chmod -R g+rwxs /var/www/ should do the trick.


2

If you did want to lock things down.... a normal wordpress site will usually only require the database user to have SELECT, INSERT, UPDATE and DELETE. If you want to use the automatic update feature it will also require CREATE and ALTER. Some plugins may require other permissions but most won't.


1

I found the problem. In settings > media the folder for uploads was actually pointing to a different path. Once I redirected it to wp-content/uploads it all worked.


1

Do you have any kind of cache plugin used? Perhaps to help speed up the website. If Yes that just may be the issue here. Another suggestion is change the current active theme to any default WP theme (twentyThirteen, TwentyFourteen), and then see if Preview give you an issue. If it does not, then its possible that there is an issue with your current ...


1

If you need to change the template used, you can use the template_include filter (change "itermediate-template.php" and "page.php" with correct file names of your template files): add_filter( 'template_include', 'cyb_exclude_template_for_editors', 99 ); function cyb_exclude_template_for_editors( $template ) { $user = wp_get_current_user(); if( ...


1

WordPress specifically checks that the fileowner of the files it creates are identical to the value returned by getmyuid. Meaning that if it creates files using a different owner than the owner of the WordPress files themselves, it won't use the "direct" mode. Same group is not enough. The files WordPress writes must have the same ownership as the ...


1

There are several sides to this. What it should be ideally, what is is practically, and what it usually has to be practically. There are two contexts to the writing files in WordPress. Just do it with PHP The locked down hardest scenario here is that only uploads is writable. Otherwise core functionality will start to break down. However plugins might ...


1

Ok, I found the permission read private posts so I revoked that privilege to the reader group and marked the articles I didn't want them to see as private. Doing any sort of permissions in WordPress feels kind of hacky, but this is a much better solution than modifying source code.


1

You are using Ubuntu package for WordPress right? Had you tried conventional install (just downloading official WP archive and setting it up with LAMP)? While it's not very "Linux way" maybe, it's commonly suggested to stick with that for WordPress. I briefly dealt with Ubuntu WP package in the past and ended up doing just that as well. PS if that 3.8.2 ...


1

There's a filter named 'upload_size_limit' where you should be able to change the value. Just add a small mu-plugin for that job: <?php /** Plugin Name: (WPSE) #177620 Alter Upload Size Limit */ add_filter( 'upload_size_limit', function( $limit = 0, $u_bytes = 0, $p_bytes = 0 ) { return ( in_array( get_current_screen()->base, array( /* Add ...


1

You can simply delete the lines from your wp-config.php. define('FTP_HOST', 'yourhost.com'); define('FTP_USER', 'youruser'); define('FTP_PASS', 'yourpass'); However, this does not automatically mean that you are secure. There are a lot of backdoors where malware could be injected, starting from the server, security-issues in your plugins, outdated ...


1

For starters, the WordPress Codex has a wealth of information on this very topic. For the sake of brevity that should take care of most of it; however, there are some relievant points that should be made: If you do not wish WordPress (essentially PHP) to have access to the file system with the exception of dynamic static assets such as images or cache then ...



Only top voted, non community-wiki answers of a minimum length are eligible