Themes, Styles, Images not working on MAMP local dev WP site - php

My recently downloaded-to-MAMP WP site is not displaying any CSS, styles, themes, or images. The live site broke after a PHP upgrade. After some panicking, I downloaded the WP site (all files, manual installation, FTP download) and exported the database. After a lot of trial and error, I got it just about running on the MAMP localhost, with PHP back at 5.6 (site broke on 7.0).
I did not install Wordpress directly, simply the root directory from the live server in the MAMP localhost folder. The site is displaying the text, line breaks, paragraph breaks, and image holders, but no styles or grid or anything - bare HTML.
A quick check with the inspector shows that the image-holders are pointing to the correct path for images, and the images are in the relevant folder in Uploads.
I tried deleting all plugins from wp-options, and changing themes in the database too.
I can't access wp-admin either - too many redirects. The site is obviously connecting to the database, styles.css is in place, the theme is named correctly, I have tried reverting to twentyfourteen too. No joy. Any thoughts? I can't move it back to the original server space now either and revert to the older PHP either.

Do you have a Full backup of any state of your Site? Did you check wether the PHP versions of Mamp and WordPress match exactly? Try to install a clean version WordPress on Mamp and then insert the databases. Don’t forget to change your WP config file to the local host address that MAMP is using.

Related

WordPress Site missing Dashboard after migration

I had a WordPress installation which I recently moved to a new Linux host. My host is for three website. I already had a WordPress site at the home directory (/public_html/). The later installation is at 'public_html/mukharsamvad.com'. The first WordPress installation is working fine. But the website with domain name 'mukharsamvad.com' is not showing any media (photos etc.). Even after logging into 'wp-admin' it doesn't directs to dashboard. Admin bar appears at the top, but doesn't have any menu or option.
After checking the URLs of images, I have found as 'http://mukharsamvad.com/wp-content/uploads/2019/10/nitish-kumar-11-1.jpg/'. It is treating it as directory. Please recommend me fixes.
Removed old installation and re-install WordPress. After restoring database, problem with image urls solved, but Dashboard still missing.
Here what you can do
check by deactivating all the plugins
change the theme
if not worked , switch for theme editor.
install classic editor plugin and enable it
if this not worked ,
inspect element & check console for errors.
it sounds like you are missing file of Wordpress I would suggest you to compare each directly with installed WordPress if you still don't solve problem then take backup of migrating WordPress installation do fresh installation then override the backup files

How to fix 'ERR_CONNECTION_TIMED_OUT' error in WordPress with WAMPSERVER installed?

I'm running up a local WordPress server with WAMPSERVER, and I'm working on editing the theme's child theme.
I also setup virtual server on my network. In the past few days I don't see any issue, everything work perfect. Until yesterday the virtual server look like not able to connect via my mobile phone and other computer in the same network.
Today I'm trying to work on the editing. It just can't load to the homepage or even wp-admin. So I took a look at the console in developer mode and I had this error.
I have try to do all the research like changing the port at httpd.conf and wp_option in wordpress to localhost. It just don't work at all.
UPDATE:
I have solve the issue with reinstall the WAMPSERVER and WordPress manually. I'll keep this post and make a guide for the future use.
Firstly I have no idea what to do because I can't even load to /wp-admin. So I decided to backup and restore everything manually.
1. Backup directory
Open up where your WordPress installed.
Click on the WAMP icon at the taskbar. If you don't see it probably is hidden inside the up arrow icon. Left click on the WAMP icon and navigate to www directory.
You don't need to copy and backup all the files in here. Navigate to yoursite/wp-content and copy plugins, themes and uploads.
Paste at any place in your computer as a backup except C:\wamp64. Because it will delete all the files when you uninstall the WAMPSERVER.
I'm using WAMPSERVER 3.1.7, older version might be different. Please Google where is my www directory in wampserver replace.your.version or original path which you can find at C:\wamp64\www.
2. Backup database
We need to backup our database in order to recover the page, post or portfolio we created in the WordPress.
In your browser navigate to localhost/phpmyadmin and select your WordPress database at the right panel then select export button on the top and press GO. Make sure your Format: SQL before you press press the go.
All the pages, posts and portfolios that you created are store inside the database, not in the WordPress folder. Read more at here.
Uninstall WAMPSERVER
Update later...
Reinstall WAMPSERVER
Update later...
Prepare to install WordPress
Update later...
Holla
Update later...
Hope the above guide will solve your issue. I'm not a professional IT guy but it does work for me at least :).
Feel free to edit or suggest if you think I have mistake in the guide.

Where I should store the Wordpress site in Xampp (linux)

I never use Wordpress but I usually use Xampp (Linux) to work.
So, I installed Wordpress and it works fine, if I enter with my browser to http://localhost/wordpress/ I can see the WP page.
I got from a friend his WordPress site files and stored them in /opt/lampp/htdocs like any regular web site, but when I try accessing http://localhost/folder_name/ I get the Index of folder_name and not the actual site.
I noticed that /opt/lampp/apps/ has a "WP" folder, and inside it - an htdocs folder like xampp have.
Where's the correct place to store the WP project ?
Is it /opt/lampp/apps/wp/htdocs or opt/lampp/htdocs/ ?
How can I get the WP site working and not get the index of / page?
You want to put the root of your WordPress installation in the same location you would put anything you want to be able to access at http://localhost. From what you're saying, it sounds like that is /opt/lampp/htdocs/
The Problem
WordPress runs just about everything through a database, including it's siteurl and home directory values. If you don't have a database at all, nothing is going to work. You'll find more on this problem Here.
The Hard Fix
You could try Migrating your friend's WP install to your XAMPP server, but you'll need their database for that to work. You could then use a tool like Wordpress Database Reset, which will get you back to basically a fresh install, just with any themes and plug-ins your friend's install included.
The Easy Fix
Since it sounds like you want a fresh install with a custom theme or plug-in from your friend, you can just start with a fresh install, and then add any themes and plug-in's in. Installing WordPress is fairly simple since they have a web-based installer to help you get everything set up. Check out this guide. Once you've got the basic site set up you can import any themes and plug-ins you want from your friend's WordPress installation.
I hope this helps!
I have read your problem folder path correct is opt/lampp/htdocs/
you need to make all services enable for server.

Plugin files/database doesn't appear using wordpress

I am facing very strange issue, I have installed a wordpress plugin (Google maps delevoped by webdorado) into the wordpress via web (dashboard) and everything works just fine as it should.
The problem that I am facing is that I cannot find nether plugin's files (directories) in the "wp-content/plugins" folder where all plugins should be held, nether its databases in "phpmyadmin" which is very strange.
The other plugins installed on the website - their files and databases are in "wp-content/plugins" as well as in the database which is how they should be, but the Google maps plugin is not in the "wp-content/plugins" folder nether in the database. I have installed the plugin on the other hosting and domain to test it out if the files appear there and in fact files did appear with databases as they should, but on my original domain database and files are not shown for some reason - but the plugin works and I can use the plugin just as fine.
Mainly, I am wondering why cant I see the files and databases of the Google maps plugin?
Extra notices, I am using "Filezilla" ftp solution to access the files and phpmyadmin to check the database's content.
I am really thinking there might be an issue with permissions that are blocking the "view" of the "Google maps" plugin's files.
Thanks!

My PHP code is commented out

Before everything happened, I was running this wordpress install for developing themes using xampp. But I decided to upgrade the memory of this machine from 2GB to 6GB since I need extra room for applications. I back-up my code in a separate partition by copying them. Since I have a 32bit OS at the time, I format the computer and installed a 64bit version. All is well and fine the OS side.
When I setup my web dev environment something goes wrong.
When I imported my htdocs back, first by just fully copying them to a new fresh install of xampp and notice that all of the codes that put are not working. My CI code is displaying my PHP code in the browser. My theme in wordpress is also commenting out my PHP code when I view the source. The themes included in my fresh wordpress install works so there's something I am missing here.
From the looks of it, the php is being executed properly since anything that I install works. Just that the ones that came from a previous xampp is not.
Open up the php.ini file and set short_open_tag = On. Then restart apache.
If you are opening a local script directly in the web browser, maybe through your editor, double-clicking on the file or dragging and dropping the file ito the browser - it will be treated as HTML only.
Instead, open the file by typing... http://localhost/your-file.php into the address bar. I personally create a projects folder in the htdocs folder and then create a bookmark for... http://localhost/projects/ and this will display all my projects that are saved into my projects folder.
Note: if you changed the mail port for the Apache server, you will need to add that to the path as well. eg. If your main port is 8888, your would do this... http://localhost:8080/your-file.php
I had the same problem and this worked for me. Good Luck
For me, it was because the file was named as ".html". You must have an extension ".php"

Categories