Differences HTML to PHP

Has big differences in page load speed if use php insteand html ??. I must convert to html in .htacess ??.

It depends on what your php script does. What do you intend to do?

No.

2 Likes

So dont has problem in show PHP pages for my visitors ??.
I need make make url query for return some pages.

Site: https://awesomemods.ml/mods.html

Speed is dependent on what you want to do. If you had the same code, PHP would be a bit slower because it has to run it though the PHP interpreter first. But you cannot really compare the two because they are very different.

And you cannot convert files using .htaccess. The server creates an HTML based off your PHP script, since browsers require HTML to display.

4 Likes

PHP is more advanced than HTML.

For that specific case, you can either use <p id="e">E</p> and <a href="#e">E</a>, or you can use PHP to create what is basically a search bar, but with predefined entries. Either works, but the former is easier.

1 Like

If storage urls in mysql ??. Dont affect my site load speed. ??.I was thinking show lastest files in my home page too equals this site.

https://awesomemods.ml/mods/mods_n/needforspeed-underground/needforspeed-underground.html

I’m not quite sure what you mean. You website seems to be working fine for me. And if you want to keep it how it is, you have to use PHP, or at the very least, JavaScript.

2 Likes

Ok, I just wanted to know if using php on my site would impact its much performance.

No, not unless you plan on using a lot of it.

2 Likes

i need make some changes in my site because Adsense say content insufficiency and cant show yours ADS =(.

When it comes to speed it is better to have static pages (HTML) than dynamic (PHP)

besides you use Cloudflare so you can say there “cache everything”

and then CF serves in most cases everything from their cache
and thus there is less work for this server
and of course less HITS (limit is 50,000 per day)

and if you use PHP you have to pay attention to security
and you are more susceptible to suspension in the event of a DDoS attack

5 Likes

PHP and MySQL add more complexity to a website, meaning there is more code that needs to be executed, compared to pure HTML (which requires no server side processing at all).

The deciding factor here is whether the code is processed as PHP. Using .htaccess rules to rewrite the file extension in the URL from PHP to HTML (or vice versa) doesn’t make a difference, because the PHP code is the same regardless of what the URL calling it looks like.

3 Likes

No. That’s like saying that planes are more advanced than cars. They are both methods of transportation, but they have different uses.

PHP and HTML are both languages (not both programming languages, however. PHP is but HTML is a markup language), but have different purposes. I guess you could say that PHP is more “advanced” (in the sense that a plane is usually more “advanced” than a car), because PHP can do more logically-based instructions, while HTML can only lay out the basic markup of a page which is then interpreted by a programming language anyways (I believe C in most browsers).

However, just because PHP is more advanced does not mean you use it over HTML, just like you wouldn’t use a plane to fly 2 miles because it is more “advanced” than a car.

3 Likes

For now I’m using php to include footer, header and nav.

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.