I've been trying to install an existing drupal 6 app into a MAMP environment (mac), but i get a white page as a result of the home page. The thing is that i can access to the rest of pages if i put the absolute url, but it doesn't show anything at root ( http://virtualhostname/ )! Maybe it's a question of the .htaccess and rewrite issues. I already setted up the memory_limit of php.ini of mamp and drupal to 256M so i don't think this is the problem either. Maybe is the db, cause some parts of the pages doesn't show properly, maybe at the import something went wrong, i don't know.
Its probably a php problem. Check your apache logs for the error. If you are running linux, just go to the terminal and do 'tail -f /var/log/apache2/error.log' and referesh the url you are getting the white page.
This will let you know the reason for the white page and then you can resolve it. You can paste the error over here, so that people can look and help you debugging it.
Hope this helps!!
Put these lines at the top of your index.php file, it will display the error out to the screen instead of just the white page.
error_reporting(E_ALL);
ini_set('display_errors', TRUE);
ini_set('display_startup_errors', TRUE);
UPDATE
Sounds like the 'whitespace at the end of template files' problem, details and fixes are here: http://drupal.org/node/1424
This is usually a php memory issue, but I have also seen similar situations where having an OP code cache like APC gets messed up and the usual solution is to restart apache to solve it.
Make sure you clear cache and run update.php
Related
I moved my website from live to localhost to make some modifications to it and I have encountered a problem, one page will not show up: "Oops! That page can’t be found.".
I have tried the following
1. activated rewrite_module
2. deactivated each plugin to see if anyone is causing the problem
3. recopied the database and files in case of failure during the first transfer
4. read that resetting permalinks might solve the problem. Changed permalinks to default - the page now works, but when I changed back to custom the problem is still there.
This is weird because only one page does not seem to show, every other page works fine and also there is no problem on the live version.
I ran out of solutions can any one please help?
This may be caused by the permalink or .htaccess
check the url of your page if no issues on URL then
Follow this steps once:
Go to settings-> permalink-> set it as default ->Reload or refresh
Then again now Go to settings-> permalink->postname
Your .htaccess will get update with the permalink.
This could be a problem with htaccess. When using the query string urls in wordpress, no htaccess is required, but for anything else Wordpress uses mod_rewrite.
Is htaccess turned on your localhost Apache server? In httpd.conf, AllowOverride All should be turned on in your active directory.
Is Wordpress able to create new files? Insufficient permissions might prevent it from creating the htaccess file.
Finally, check that your links are pointing to the right place. Sometimes the problem is as simple as a misspelling in your link ;) Good luck.
I'm struggling from an error on WordPress 3.8.1.
Whenever I try to upload a media to a post, it does not add, it says An error occurred in the upload. Please try again later..
But the weirder thing is that it is shown on dashboard/media/library even after this issue.
I also cannot see uploaded attached media to my posts (edit post / [add media button]) / media library / uploaded to this post, but in dashboard/media/library section , these old uploaded images are shown properly that which is uploaded to what post.
I have tried the followings:
Re-installed both my local version and en_US from both update manager and manually
Deleted wp-includes and wp-admin folders and replaced them manually.
I have checked chown and chmod of the wp-content/uploads folder. To make sure they are working, I have deleted wp-content/uploads/2014 folder, and after first upload that shows this error, the folder is created with right chown and chmod and files were there (wp-content/uploads/2014/01/26/file with resolutions.jpg)
I have deleted unneeded plugins, deactivated all plugins and themes, switched back to WordPress's default plugin, I have even reset active plugins json object at wp_options from SQL, did not help.
I have enabled php error logs, nothing related is shown
I have altered the WP_DEBUG definition to true, I have even defined WP_DEBUG_DISPLAY to true, no help.
When I try to add from wp-admin/media-new.php , using multi uploader, file is freezing at "Crunching…" step, but old browser upload works flawlessly.
I'm managing the VPS and hosting the blog myself with CentOS 6.5 x64. safe_mode is set as off. There is not a mod_security option in my php.ini. My upload_max_filesize in php.ini is set to 20M, memory_limit is 256M, only 3 sites are hosted and memory is quite empty while testing these. This also happens even with 50kb .jpg images, so this should not be related.
I have re-uploaded all wordpress files from a clean downloaded zip, no help.
I have tried adding AddType x-mapp-php5 .php .php4 to the end of .htaccess as suggested here, that did not help at all.
The thing is that, I have tried a clean installation to another domain on the same server, it is working as it should.
What could be the problem? How can I fix this?
Thanks in advance,
See if custom post type has any files that are in UTF-8. If you change it to ANSI, that should help, if thats an issue.
I had the same issue, and found that there is a problem with my theme itself... try doing the same action using the twentyten theme. if that works, then take a look and see if there is any conflicting code in the functions.php of the theme...
if you are using a child theme can I suggest making another child theme, or using an alternative them as in my experience not all themes "like" being used as a child...
If you are trying to upload into a custom post-type, change the capability_type setting in your functions.php file to 'post' and it should fix your problem.
Check permissions of your wp-content or wp-content/upload folders, If folder permission is not 755 then change it to 755 and re-upload again. I hope it will solve your problem.
If you are using a low scale server and added a plugin named "WP-SmushIt" then it will surely cause an error. Reason is simple this plugin uses CPU resources to minimize the size of images in process of optimizing it and so it crosses the server limited execution time. Solution is simple-> Go with higher plan servers or try changing server execution time listed in php config file.
Not directly related to this, but I have experienced the exact same issue after moving the very same site to a different server now. Only difference is now I've been using Nginx instead of Apache. I have checked the ownerships before and they were all correct (else the normal upload wouldn't work earlier either). I'm leaving this here just as a reference.
The fix on my newer case was simply changing the ownership of the web root and all the files inside.
Nginx and PHP5-FPM were running with same user: www-data, which is at the group with same name: www-data.
So changing of all the ownership of the files fixed in this case:
su
chown -R www-data:www-data /path/to/wordpress/root/
And the issue was gone.
I still don't know the original reason of my old issue, I had to wipe, start from clean and restore the posts, plugins etc. from scratch.
I was facing same issue in wordpress like media not loaded in popup. then i have resolved.
I think, Some times problem created by ajax response.Means ajax response comes with some additional content.
Wordpress media popup is loaded content by ajax(json Response) and ajax give response with some content like style and other.
For Example:-
<style>
.class{}
</style>
then json(ajax response).
So First check your ajax response in console.We have to disable all plugins then check it is work or not.If no then activate default theme. because content comes from plugin and theme.
check your folder permission, and mod_security settings, also try to increase max_execution_time and memory,
I moved my wordpress site from one host account to another. I keep my URL unchanged. After that, my site is work fine - but only on front side. I cannot login to admin area - there is only blank white screen after i enter my username and password. Here is a brief detail what i have installed and what i try to do for now:
front end is work just fine - mean that DB connection is ok
login form is appear correctly. I even try to enter wrong username and/or password in order to check auth procedsure - it's ok for incorrect login. If credentials is correct - white blank screen.
have very simple template - no fancy sliders, no sophisticated framework - "simply works core"
have Better WP security installed - i try to delete plugin folder - no change
try to clean/delete .htaccess - no change
try to get manually a secret key from .htaccess and login with him - again white blank screen.
trying to run wordpress in debug mode - no error messages. Also no errors form php in error.log (edited at 28.10.2013)
Please, if anyone have same or similar problem - i'll be very happy to resolve this. My blog is a long time active, i have a lot of posts and pages there.
try change this on your wp-config.php to see if the wordpress dump any useful information about this white screen.
define('WP_DEBUG', false);
Replace that line with the following:
// Turns WordPress debugging on
define('WP_DEBUG', true);
// Tells WordPress to log everything to the /wp-content/debug.log file
define('WP_DEBUG_LOG', true);
// Doesn't force the PHP 'display_errors' variable to be on
define('WP_DEBUG_DISPLAY', false);
// Hides errors from being displayed on-screen
#ini_set('display_errors', 0);
hope that helps :)
After few days of hard but unsuccess tryouts, i found a solution. It's drastic and not well explain what happen, but it worked for me - and hope for something else too. So:
rename wp-content\plugins diretory to __plugins - this will deactivate ALL plugins
rename .htaccess to .__htaccess - this will remove all url rewrite records
clean browser cache
login from wp-admin\
when try to access plugin list, a lot of messages appear - sayng for deactivating all plugins
restore plugins and htaccess to their original names
and finally - activate all needed plugins again
In conclusion - this does not answer the question why (even if URL is not change) this happen. It also not so pleasant if you have a lot of plugins - you must remember which of them is activated.
Thank you all, that problem is closed for me.
I fixed it.
I tried the following:
define('WP_MEMORY_LIMIT', '64M');
Change Plugins name
Check white spaces
Increase memory
Change Theme
Upload new wp-admin
All of them didn't work..
I downloaded wp-config with ftp and changed the encoding using notepad++ from utf8-BOM to just utf8
A white screen only tells you that something has gone wrong.
This can be anything. Speculating is just a waste of time.
Go and find the error.log of your webserver!
Then last lines of this file should tell you what went wrong.
When you don't understand it, you can ask again.
I'm running the latest version of WordPress (3.5.1), hostet with Strato and since yesterday some of my plugins are not getting the correct path to their files.
UPDATE: It's not a Multisite!
All files are still on the server and haven't been changed or updated since friday (at this point the site was live without issues). The problem is that the plugins are looking at some kind of internal path which looks something like this: website/wp-content/plugins/xxx/xxx/xx/xx/123456789/htdocs/website/wp-content/plugins/akismet/akismet.css so all I get is an error 404 (Not Found)
I cannot locate the problem and I'm not getting any PHP errors or anything like that; only the paths are broken... the plugins are even working, but without images, css and scripts!
Therefore I've deactivated all of the plugins but as soon as I activate them again, I'm running into the same problem.
And finally I've already contacted the provider, but they cannot help at all because it seems to be a problem within WordPress.
UPDATE: I've completely removed all of the plugins, but even if I now download and activate a new plugin the path is broken as mentioned above...
UPDATE2: The wrong path looks like this:
domain.com/wp-content/plugins/mnt/web1/a1/12/123456789/htdocs/
/website/wp-content/plugins/akismet/akismet.css
instead of domain.com/wp-content/plugins/akismet/akismet.css
(actually the second version of the path is working, but all of the plugins are calling the first version, even if completely new installed)
UPDATE3: Sorry, I'm not able to go more into detail, because I've no clue what's going wrong, so I'm giving it a try from another perspective: everything is working fine, with the exception of the plugins. The plugins are even displayed in the frontend, but without any CSS, JavaScript or images. The same thing happens in the backend. I can see all of the plugins and manage (install, edit, configure,...) them, but there is no styling. Everything in case of the design seems to call a wrong path. In doing so the first part of the path is okay, and also the last part, but in the middle there are numbers which should normally not be displayed within a frontend path because they are a part of the Strato server root directory.
It seems your the WP_CONTENT_URL is not correct.
This is defined as in ./wp-includes/default-constants.php:
define( 'WP_CONTENT_URL', get_option('siteurl') . '/wp-content');
So check your settings > general > WordPress Address (URL)
You can also try to define the correct WP_CONTENT_URL in your wp-config.php:
define( 'WP_CONTENT_URL', 'http://www.yourdomain.com/wp-content');
When the above don't help check your .htaccess. Maybe wp-content/ is rewrite to the fullpath.
I moved a Wordpress website from one server to another and I am now getting 404 errors on everything but the home page.
I also checked that the .htaccess file is there and the database contents. They are fine. Not sure what else could be causing this.
Any ideas from the community?
Assuming you have pretty permalinks enabled, are you sure that the new server has mod-rewrite enabled? You can also check to see if this is the problem by going to a pagelike yoursite.com/?p=1 where 1 is a page id.
Assuming the URL has changed
You need to update either the database or (if you're lucky) one of the .php files in the wordpress distro - see the wordpress article on this.
I had the same issue and ended up having to edit the database. You're seeing the 404's because wordpress thinks it's still hosted at the old URL and is therefore trying to retrieve files from it.
If the URL has not changed
Perhaps permissions need updating on the folders? The folders should be set at 755 and the files 644 (reference here).
Looks like you may have solved the problem - I had a similar problem where permalinks would not work, but the default links did work. I modified the .htaccess file to what Wordpress said to do. Twice I thought I had solved the problem, but didn't.
I had moved it to my local Ubuntu Karmic Koala system for testing, and found that the solution involved editing a file in /etc/apache2/sites-enabled. On my system, it was called 000-default.
This file had statements like the .htaccess file, and in two places had AllowOverride None, which I had to change to AllowOverride All. Apparently, this file overrides any local .htaccess files.
I also had to change the location of Wordpress in the main configuration, but that was obvious.
I hope this will help someone who has tried all the normal suggestions like me, and is still having problems.