Page 1 of 1

Wordpress not working on lampp

PostPosted: 19. April 2012 15:50
by Batman
I'm on Linux Mint 12 and using xampp 1.7.7.

When I try to remove plugins in wordpress, it asks for FTP information...

To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.

I think this is a permissions problem but have no idea how to fix... can anyone help please?

Re: Wordpress not working on lampp

PostPosted: 27. April 2012 17:30
by JonB
OK -

Two things (but I think the resolution will be the same)

You didn't mention the WordPress version (but I don't think it matters). And - I am going to presume that LAMPP is running locally (on the machine you are at)

I do a good amount of WordPress work and customization. What you are experiencing is a by product of WordPress being designed for shared hosting. It is 'assuming' you are connected to a server where the WordPress user uploads files via FTP AND is on a remote machine. That's not the case when you are working on the 'console machine'. By way of explanation, on a shared server the FTP user is almost always the 'owner' of the files in the Document Root. Wordpress is using FTP effectively as a 'proxy' -- that's how the 'auto-upgrade' also works.

(Its the same with XAMPP for Windows, same issue)

There are two possible fixes:

One: Get ProFTPd working and configured exactly as your Wordpress is. I.E. exact URL (hostname or IP) as set in your wp-config.php. He defualt user/owner for all files in /opt/lampp/htdocs is a special Linux user 'nobody'.

Two: I'm pretty sure you can remove the plugins manually without any problems. AFAIK, WordPress plugins are self contained - and - WordPress discovers them by enumerating the /wp-content/plugins folder. (its just like themes in that sense). I think just removing the folder will do the trick.

Good Luck

Re: Wordpress not working on lampp

PostPosted: 28. August 2012 04:55
by prezla
The easiest way to do this is to find out what user apache is running as and change ownership of the entire WordPress directory to that user. For example, if apache is running as ‘httpd’, you could use the following commands on your WordPress installation directory.

Apache not as a service but as part of XAMPP , you must ran command for each directory where your site is located, for default its /opt/lampp .
I use a virtual host, so in my case this is:

Code: Select all
<?php echo(exec("whoami")); ?>        /* users to find if you changed the default user nobody. */

or look in /opt/lampp/etc/httpd.conf
Code: Select all
<IfModule unixd_module>
User nobody
Group nobody

Code: Select all
# chown -hR nobody /www/      /* command which assign ownership to the user. */

and so for each host. :roll: