HTML Page in PHP Website
-
Does having an HTML page in a PHP website affect SEO? I have a PHP website but one of my targeted pages have an HTML page. Will it cause any harm to the website or is it fine to have a html page in a PHP website?
-
Having different file types in of URLs in your site doesn't affect SEO. It may confuse you, and you may inadvertently link internally to pages that don't exist on your site, but there is no effect on SEO.
There is a way to parse HTML files as if they were PHP pages--but nowadays I don't recommend that. If you do have HTML pages on your site, you may just want to leave them alone. But if you do think you need to change or update their functionality, then setting up a 301 Permanent Redirect from the old HTML page to a new .PHP page, for example, will do just fine. It should not have any effect on rankings.
-
Hi plinggtre67,
This should have no direct effect on SEO. The reason is, PHP is server sided script, which is usually outputted as HTML anyway. HTML is what the browser actually reads.
If you are referring to some pages having .html extensions and some having .php, then from user's perspective that may have a slight impact on some users not knowing whats going on, but in general it shouldn't matter. If you would like a consistent look on the page extensions you can use an Apache URL re-write to remove the extensions all together (just like Moz does). You should notice no pages on Moz site have an actual .extension appended to them.
Example Code: @ StackOverflow
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteRule ^(.)$ $1.phpRewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.html -f
RewriteRule ^(.)$ $1.htmlI hope this makes sense and helps,
Don
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
I have created a simple website, but one of the panels moves
All right, I've created a simple website (http://fontvilla.com) and I have had a problem for personal reasons. When you execute the code below and see the whiteboard at the right-hand side labeled as the.newsLetter and change the screen size, it moves away unlike that I have just floated right above. But if I float this one right then it floats to the middle of the screen, so works as I want it. In order to do that, I am going to make this reactive, and need to have it like the one above. You got a fix...?? Help, please! Thank you. Thank you. <title></span></p> <p><span>Home </span></p> <p><span></title> <nav> Contact Products About Home </nav> Here is just a simple title This is just a little bit of dummy text. This is just a little bit of dummy text. This is just a little bit of dummy text. This is just a little bit of dummy text. Welcome to A dummy website!! Latest News March 28, 2015 New advanced update with double speed and a whole bunch of cool new st.. more>> March 28, 2015 New advanced update with double speed and a whole bunch of cool new st.. more>>
Local Website Optimization | | fbowable0 -
Proper SEO structure for Franchise/ Franchisee websites
Hi Neighbors, Franchise website design and development can be difficult, there’s no doubt about it. I had to find the right balance between a unique and unified brand identity, and a localized experience that accurately reflects the individual franchisees and their efforts. Due to the many benefits, I have structured the to read _domain.com/location _ domain.com = TLD /location = subfolder (location page) I have also built a customized CMS (e.g. Drupal) and have given each location access to manage their location page (subfolder). To accommodate local SEO optimization, franchisees have complete control in terms of optimizing their location page (subfolder). Title tags, meta description, Alt tags, etc... Will any local optimization performed in the subfolder (location page) be stiffened because it was not done in the TLD but in the subfolder ?
Local Website Optimization | | Jeffvertus1 -
Matching page for keyword doesn't show in search
Hello! I'm having an issue with my website Rooms Index, the website is in Hebrew so I'll provide examples in English for better understandings. When I'm searching Rooms by Hour in Haifa, google doesn't show the intended category page which is this, instead it shows my homepage in the results, this happens only for certain areas, while other areas are working well such as Tel aviv. For example if I searched day use in Las Vegas it'd show me the Las Vegas page dayuse.com/las-vegas, but searching for Brooklyn I'd only see dayuse.com. the pages are indexed and I can find them if I search site:roomsindex.co.il what could cause such problem?
Local Website Optimization | | AviramAdar0 -
Boost Website Traffic
Tom Beavan Websites is my business where I create and design affordable websites for small businesses in Wordpress. I am looking to improve my traffic to my website as dramatically as possible. At present, my website is a one-page website with limited content - https://www.tombeavan.co.uk. My website ranks #1 for local keywords like: Web design Wiltshire Web design Trowbridge Wordpress developer UK So in terms of keyword position, I am doing well for local business but I only get 200-300 visitors per month. I would like to dramatically improve this to improve the number of enquiries I get. I do tend to get a few enquiries but think if I improve the website traffic, the quantity of website enquiries will increase too? I have a long list of tasks I would like to do for SEO: Add a lot more content to the website Add more backlinks Guest blogging Lots more What would you recommend a good starting place or a place which will increase traffic effectively? Thanks for your advice in advance 🙂
Local Website Optimization | | tombeavan0 -
Do location pages boost the homepage?
Google has stated that businesses should spend time creating location pages for the various service areas that businesses operate in. What I want to know is, it is equally about boosting the relevance of the site as a whole, as well as ranking that individual page in the local area. Does Google take into account the fact that you have the location page and reward the homepage by favoring it more in that local area, or is it simply about ranking an individual page in each town/city?
Local Website Optimization | | OliverNeely2 -
Multiple My Business pages affecting local SEO?
Hey Moz! We have a situation with a dentist firm with multiple doctors at the same address. They have two locations for their dental offices, and each of the dentists operate at both offices. The issue: Each doctor insists on having their own by business page for each location and i'm afraid this is hurting their local SEO. We've been tracking keywords by week and we've seen some big fluctuations in ratings and i'm looking into why this is happening. The office in location 1 has it's own Google My Business page and the three dentists have their own my business page set up at the exact same address. The office in location 2 has it's own Google My Business page as well and the three dentists have their own my business page there also. This leads the two addresses of the main offices having multiple My Business pages at the same address competing against eachother since they are all are registered with similar names and specialties. Could this be hurting our local SEO? Thanks! -Z
Local Website Optimization | | zacgarrison_700 -
Site Audit: Indexed Pages Issue
Over the last couple of months I've been working through some issues with a client. One of my starting points was doing a site Audit. I'm following a post written by Geoff Kenyon https://mza.bundledseo.com/blog/technical-site-audit-for-2015 . One of the main issues of the site audit seems to be that when I run a "site:domain.com" query in Google my homepage isn't the first page listed in fact it isn't listed in this search when I go through all of the listings. I understand that it isn't required to have your homepage listed first when running this type of query, but I would prefer it. Here are some things I've done I ran another query "info:homepage.com" and the home page is indexed by Google. When I run a branded search for the company name the home page does come up first. The current page that is showing up first in the "site:domain.com" listing is my blog index page. Several months back I redirected the index.php page to the root of the domain. Not sure if this is helping or hurting. In the sitemap I removed the index.php and left only the root domain as the page to index. Also all interior links are sent to the root, index.php has been eliminated from all internal links everything links to root The main site navigation does not refer to the "Home" page, but instead my logo is the link to the Home page. Should I noindex my blog/index.php page? This page is only a compilation of posts and does not have any original content instead it actually throws up duplicate content warnings. Any help would be much appreciated. I apologize if this is a silly question, but I'm getting frustrated/ annoyed at the whole situation.
Local Website Optimization | | SEO_Matt0 -
Home page links -- Ajax When Too Many?
My home page has links to major cities. If someone chooses a specific city I want to give them the choice to choose a suburb within the city, With say 50 cities and 50 suburbs for each city that's 2500 links on the home page. In order to avoid that many links on the home page (or any page) I would like to have just the 50 cities and pull up the suburbs as an ajax call that search engines would not read/crawl. This would be better than clicking on a main city and then getting the city page which they then can choose a suburb. Better to do it all at once. Is it a bad idea to ajax the subregions on the home page and to code it so Google, Bing, other search engines don't crawl or even see anything on the home page related to the suburbs? The search engines will still find the suburb links because they will be listed on each main city page.
Local Website Optimization | | friendoffood0