Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6368065
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T00:37:43+00:00 2026-05-25T00:37:43+00:00

Are there any security / performance concerns if we set the Apache web server

  • 0

Are there any security / performance concerns if we set the Apache web server to configure Apache to handle all HTML as PHP? I was specifically referring to:

AddType application/x-httpd-php .php .php3 .php4 .html

I was in a situation where I needed to add some PHP logic into some HTML files; ideally, I didn’t have to change the filename e.g. page.html to page.php (to keep the page rank, etc. for page.html).

This is related to the following question: httpd AddType directive

Edits:
From the existing answers / comments below, it looks like the community suggests to either use redirects or only target specific HTML files. The constraint is that I am redesigning an existing site (400+ HTML pages; each of them uses some sort of Dreamweaver template that pulls in the header and footer from different files). I was hoping to completely shy away from Dreamweaver move into something non-proprietary. So, I am down with two options:

  1. Use Server Side Includes (SSI) to pull in the header and footer. This will result in all my HTML files to be decorated with SSI.
  2. Sprinkle some PHP snippet to include the header and footer. For this choice, I have to make sure the file name stays unchanged.
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T00:37:43+00:00Added an answer on May 25, 2026 at 12:37 am

    The more files the server determines it needs to pass through the PHP interpreter, the more overhead involved, but I think this goes without saying. If your site does not have ANY pages with plain HTML, then you’re already paying all the performance penalties that you could possibly pay – adding HTML to the list is no different in this case than simply renaming all the files to have a .php extension.

    The real performance penalty would come if you do have plain HTML pages – the server will needlessly pass these pages to PHP for interpretation when none is necessary. But even then, it isn’t dramatic – the PHP interpreter won’t be needed for those HTML pages, so it won’t do anything aside from determining that it doesn’t need to do anything. This has a cost, but it isn’t significant.

    Now, if we’re talking high-volume here, every little bit of performance matters and this would not be a practicable solution. For low- to mid-volume sites, however, the performance penalty would be nill.

    If this is a one-time change and there are a limited number of files that are affected, then it may be more conservative to use a FilesMatch directive.

    <FilesMatch "^(file_one|file_two|file_three)\.html$">
      AddType application/x-httpd-php .html
    </FilesMatch>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Are there any huge performance issues or security concerns? Using SQL Server 2005 and
Are there any security issues keeping the .NET PDB files on the real server?
Are there any known security issues related to running a web application via a
Are there any security or compliance concerns around storing user data, (name, email, address,
this is a 3 part question Is there any performance or security risk in
is there any security issue realated to leaving ASP.NET Session ID value on html
Are there any security exploits that could occur in this scenario: eval(repr(unsanitized_user_input), {__builtins__: None},
Am wondering if there would be any security flaw in this approach. I am
Is there any comparison to show why JSP/ASP.Net is better from security point of
I was wondering if there is any difference in performance (or any other important

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.