Hide a subdirectory on my website hosting

If understood correctly, you’ll have to follow this Codex instructions: Using a pre-existing subdirectory install. If you already have WordPress installed in its own folder (i.e. http://example.com/wordpress) then the steps are as follows: If that’s your case, you’ll learn how to make WP work as if it were on the root, even being installed on … Read more

add_rewrite_rule to remove /category/ from permalink

I believe the rewrite rule your wanting to alter is this category/(.+?)/?$ index.php?category_name=$matches[1] category to do what you want it should just be a case of adding the following rewrite rule in your functions.php add_rewrite_rule(‘(.+?)/?$’, ‘index.php?category_name=$matches[1]’, ‘top’); this should work but might conflict with other rules so that will be worth checking.

Strange behaviour of is_user_logged_in() and get_current_user_id()

I’ve run your code and it works fine to me except for the inclusion in file-access.php: require_once($_SERVER[‘DOCUMENT_ROOT’].’/wp-load.php’); enable debug to see if there are errors depending on other issues and not regarding these specific code lines. But.. as per WP documentation: actions reference the earlier action hook where the authentication process is completed and cookies … Read more

How to rename index.php to home.php

how to correct example.com/home.php? First, put things back the way you found them. Both index.php and home.php are reserved file names. And index.php is special not only to WordPress but to the server itself– look into DirectoryIndex. You should not be manipulating them in this way. Unless you really know what you are doing you … Read more

wordpress blog displaying blank pages [closed]

That’s odd. Perhaps you need to clear your cache or maybe your server takes a while to respond to a changed .htaccess file. (What web host are you using?) Is there another .htaccess file in the WP folder which might have been modified? Or maybe you’ve made other changes??? By the way, why are you … Read more

Disable directory browsing of uploads folder

To disable directory browsing all you have to do is drop in a blank index.html file into the wp-content\uploads directory, each subsequent sub-directory also would need a blank index file, there are plugins that can automatically do this for you. ps. Get a better host, there is no reason they should disallow you having your … Read more