473,414 Members | 1,606 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,414 software developers and data experts.

What are the Pros and Cons of PHP?

xarzu
88 64KB
What are the pros and cons of plain PHP or Classic ASP?

PHP and Classic ASP are server-side scripting languages. What is wrong with having a website written in this instead of the trendy JavaScript Frameworks like React, Angular etc.? If memory serves me correctly, there is an issue with security where you can post in a text box some script and hack into a system.

Can we please discuss some pitfalls or drawbacks to having a website written entirely in PHP or ASP? What does a JavaScript framework or Node.js bring to the table that would otherwise be lacking?

I am just now venturing into a contract where I am tasked with updating and maintaining existing code. All I know right now is that it is written in PHP and Classic ASP. I am in the process of investigating these scripting languages and I want to know what the opinion of other developers are.
Jul 23 '21 #1
5 11016
dev7060
636 Expert 512MB
PHP is as secure as any other language. The application code is as secure as the developer makes it.

If memory serves me correctly, there is an issue with security where you can post in a text box some script and hack into a system.
Follow the best practices to prevent SQL injections.
Jul 24 '21 #2
TatsianaIsakova
12 Byte
There's nothing wrong with PHP, actually. It still powers the majority of website thanks to its safe, user-friendly, and sophisticated user experience. As for the security issue, you need to select the framework that ensures advanced security functions like Cross-Site Scripting (XSS), Cross-Site Request Forgery (CSRF), SQL Injection.

Our company gets a lot of PHP 'orders' so I wouldn't say it's losing its popularity to React and such.

In this post, for example, our developers share their take on PHP and its frameworks. You can read it for a more in-depth insight into the technology.
Jul 26 '21 #3
PHP as a server-side web development language has evolved from the small open-source project. It was created in 1995 by Rasmus Lerdorf who wrote a few CGI programs and managed to make them work with web forms and databases. He hasn’t aimed to create a new programming language but it turned to become among one of the biggest open-source languages. Anyone can make a contribution to the new release including task deployment, testing, documentation, and sources.

Thanks to its accessibility, PHP has gained popularity among a huge number of developers. It might be a common choice for newcomers, as its learning curve is much easier in comparison with others.

The PHP community has various open-source free libraries, tools and extensions. For example MySQL Extension, it allows developers to create PHP apps that interact with the database while enabling improved statement and transaction support.

In the light of ASP vs PHP comparison, the PHP developers deal with the other type of code – interpreted one that is completely written in C. It allows excellent customization nevertheless that might be the cause for some bugs and poor coding.

Since this server-side language was initially released for web development, it is efficient in communicating and accessing most types of databases. Due to its adaptability and flexibility, developers are not limited in their choice. Moreover, PHP can have support for other services covering different protocols like POP3, HTTP, IMAP, LDAP, etc.

Consequently, being open-sourced turned out to be a great solution for the PHP web development community. They have gained the biggest market share and keep on the constant improvements and regular releases.

The first reason why PHP is good for web development is that this programming language has been initially presented as a web scripting language. It is greatly supported and improved by its own community that consists of more than 5 million PHP developers. The open-source programming language is quite popular among newcomers and has gained the biggest market share. Its supportive community keeps on growing for more than 25 years.

Working with open source has its own advantages and disadvantages. In fact, this language is easy to learn, compatible with different servers, and suitable for various web applications. Another distinction of PHP development is the interpreted code. This type of code is usually executed on the server, later generated into HTML, and only then sent to the user side. Accordingly, the execution time is longer and might get some errors with importing heavy files and lead to slower performance compared to other languages.

On the other side, PHP web development is often chosen for increased scalability. This is accomplished by adding more servers. The overall workload will be distributed between them and can handle more user requests. This approach relies upon the horizontal scalability that differs PHP from ASP.NET.

Having a number of in-built security features, PHP is still considered less secure compared with other web-server programming languages. While obtaining more flexibility in writing the code, engineers have more responsibilities to secure it and can’t rely only on the in-build tools.

Lower development and maintenance cost is usually acknowledged as a great benefit. PHP developers have access to all the tools and libraries without any additional fees. Moreover, developers can choose among the different hosting services and have the opportunity to pay less.

This adaptable and flexible programming language can easily meet the primary needs of web development. However, the companies need to outline their needs at first and make sure it corresponds to the set requirements and final goals.
Aug 13 '21 #4
elianawilson
2 2Bits
Pros of Using PHP
1. Speed up custom web application development
2. Simplify web application maintenance
3. No need to write additional code
4. Work with databases more efficiently
5. Automate common web development tasks
6. Protect websites from targeted security attacks
7. Perform unit testing efficiently
8. No need to increase web development cost

Cons of Using PHP
1. Programmers need to learn PHP frameworks instead of PHP
2. Quality of PHP frameworks differs
3. Lack of option to modify core behavior
4. Affect Speed and performance of websites
Sep 7 '21 #5
Vanisha
25 16bit
PHP is a widely used server-side programming language that has been around since the mid-1990s. As with any technology, there are pros and cons to using PHP. Here are some of the most notable ones:
Pros:

Easy to learn
Open-source
Large community and ecosystem
Cross-platform compatibility
Fast and efficient

Cons:

Security
Inconsistency
Scalability
Limited support for asynchronous programming
Legacy code

Join PHP Online Training
Feb 15 '23 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Ronnie Patton | last post by:
Hello everyone can you help me find some information out about pros and cons using a global.asa in any asp application My co-works are saying its your choice to use one or not based on what the...
0
by: Sniffle | last post by:
Thanks... Say you have a double opt in mailing list, of which the subcriber list is store in the db. Im still somewhat of a newb, so bear with me... are there any pros/cons as to keeping the...
0
by: Steve | last post by:
We've recently got a new Server in. The server has 16Gb of RAM, 8 cpus etc We now have a choice of sticking with Windows 2000 Advanced Server or going with Windows 2003 Enterprise edition. ...
112
by: Andy | last post by:
Hi All! We are doing new development for SQL Server 2000 and also moving from SQL 7.0 to SQL Server 2000. What are cons and pros for using IDENTITY property as PK in SQL SERVER 2000? Please,...
5
by: Fred | last post by:
Not much expertise on XSLT and trying to understand it's uses when creating apps in VS.NET? If I wanted flexibility on the UI (View aspect of M.V.C.): - How does it compare with creating...
5
by: JayCallas | last post by:
I have a requirement where I need to perform a query for position information. But for some types of entries, I need to "expand" the row to include additional position rows. Let me explain with an...
5
by: sinister | last post by:
I'm starting a database/web interface project, using Linux and postgresql. I've programmed in PHP4 in the past, and for this new project am unsure whether to use PHP4 or PHP5. My main concerns...
1
by: Doogie | last post by:
I'm looking for some good reading material on the pros/cons of using the Session object and was wondering if anyone could point me in the right direction?
62
by: estherschindler | last post by:
This is part of a series examining the strengths and weaknesses of various scripting languages, with particular attention to enterprise (read: big company) use. You Used Python to Write WHAT?...
3
by: ziycon | last post by:
What would be the pros/cons of turning off error warnings in the website pages like below? What are peoples opinions on this approach? <?php error_reporting(0); ?>
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.