0% found this document useful (0 votes)
34 views

Empirical Study of Most Popular PHP Framework

Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views

Empirical Study of Most Popular PHP Framework

Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

2021 International Conference on Information Technology (ICIT)

Empirical Study of Most Popular PHP


Framework

Hamza Abutaleb,
Abdelfatah Tamimi and,
Thamer Alrawashdeh
Al-Zaytoonah university of Jordan
2021 International Conference on Information Technology (ICIT) | 978-1-6654-2870-5/21/$31.00 ©2021 IEEE | DOI: 10.1109/ICIT52682.2021.9491679

Amman, Jordan
Faculty of Science and Information
Technology Department of Software
Engineering

Abstract— There have been several PHP frameworks depending on the actions of each layer to solve this
for developers to pick from in the latest years. Developers issue.
face problems choosing the most relevant frameworks Developers use different patterns to lay out their
and appropriate support functions to include in their projects to make the code less complex and easier to
project. For this reason, a clear understanding of the
various frameworks is now becoming an important
work with .by far the most popular of these patterns is
necessity for web developers. In this paper, we collected MVC also known as Model View, Controller. The main
several research papers talking about different PHP goal of this pattern is to split a large app into specific
frameworks, and we compared them with each other in sections that all have their own purpose to illustrate
several ways which are: Request per second, Memory each section.
usage, Response time and, Number of files using several PHP frameworks are based on a Model, View, and
PHP frameworks: Laravel, CakePHP, Codeigniter, Controller (MVC). The architecture pattern of MVC is a
symfony2, Phalcon, Symfony, and Yii. the Laravel successful way of designing applications such as
outperforms other MVC framework in request per second,
CakePHP, Codeigniter, Laravel, Symfony, Yii,
memory usage. On the other hand, phalcon outperforms
other MVC frameworks in response time and number of
etc., The key MVC methods are to partition a program
files. into a different layer that can run independently and
achieve the same outcome.
Keywords— Codeigniter, CakePHP, Laravel, MVC, Today, millions of websites that can be considered
PHP Framework, Phalcon, Performance, Symfony, web applications exist. When developing a web
Symfony2, Yii. application, following a design pattern can make a big
difference. MVC, short for Model-View-Controller is a
I. INTRODUCTION popular design pattern that is used by many
Over the past year’s websites have gone from simple frameworks for web development. When developing
HTML pages with a bit of CSS to incredibly complex web applications, choosing the right framework is
applications with thousands of developers working on important. [1]
them to make these complex web-app much easier. In the choice of the best PHP framework remains an
today's IT industry, web developers must be familiar issue, and developers need to learn how to select the
with and knowledgeable about at least one framework. most suitable PHP framework with the best support
PHP is a common language for general-purpose features to be used in their project. In this paper, we
scripting that is particularly suitable for web compare different MVC framework that we collected
development. From your blog to the most famous from many research paper all the researchers
websites in the world, PHP powers all easily, flexibly, compared the frameworks with different criteria, and
and pragmatically. PHP, a web scripting framework that we collected similar comparisons between the
allows for dynamic website design such as intuitive, research papers as shown in the table 1 and
quick compilation, cross-platform, open-source, compared them in terms of Request per second,
flexibility, and minimal configuration needed. In the Web Memory usage, Response time and, Number of files.
environment, PHP is one of the most powerful
programming languages. Many developers prefer to Section 2 of this paper illustrates MVC Architectural
deploy PHP-based frameworks that bring all the pattern and Section 3 examines PHP Framework.
problems together such as data access, business logic, Section 4 describes Evaluation of the performance,
and data representation layer. This in fact creates SECTION 5 figure of the test and finally, the
problems with development, especially for big projects. conclusions presented in Section 6.
However, The MVC architecture pattern offers an easy
way to divide code into layers from each other

978-1-6654-2870-5/21/$31.00 ©2021 IEEE 608


Authorized licensed use limited to: UNIVERSIDADE DE SAO PAULO. Downloaded on July 24,2024 at 18:52:42 UTC from IEEE Xplore. Restrictions apply.
2021 International Conference on Information Technology (ICIT)

II. MVC ARCHITECTURAL PATTERN View-Controller, Active Log, Relationship Data


Mapping, and Front Controller.
Model View Controller (MVC) Architectural pattern
is a pattern used to build a web site, which has B. CodeIgniter
become the based architecture for most of the PHP Codeigniter is a powerful PHP framework with a
Frameworks. Developing any types of applications very small footprint, built for developers who need a
can be a pain every developer faces due to simple and elegant toolkit to create full-featured web
managing or separating User Interface (UI) from the applications. [5]
application logic [1]. Therefore, to avoid those
Codeigniter is loosely based on the common pattern
difficulties and have an efficient, reusable, stable,
of Model-View-Controller creation.
and scalability application, adopting an MVC pattern
Although view and controller classes are a required
is an effective solution [2]. Implementing the use of
part of Codeigniter creation, models are optional.
MVC pattern in building a Framework makes the Codeigniter is most commonly noted for its speed as
application development process becomes well- opposed to other PHP frameworks.
structured. The pattern is abstracted into three
distinct parts as model, view, and controller that [3]. C. Laravel
. Laravel is a web application framework with
expressive, elegant syntax. We believe development
A. Model must be an enjoyable, creative experience to be truly
The model aspect refers to all the data-related logic fulfilling. Laravel attempts to take the pain out of
that the consumer is dealing with. This reflects either development by easing common tasks used in the
the data that is being transmitted between the View majority of web projects, such as authentication,
and Controller components or some other data routing, sessions, and caching. Laravel aim to make the
relevant to business logic. For example, the development process a pleasing one for the developer
Customer Object can extract customer information without sacrificing application functionality. Happy
from the database, manipulate it, and update data developers make the best code. To this end, we've
back to the database, or use it to make data. attempted to combine the very best of what we have
B. View seen in other web frameworks, including frameworks
implemented in other languages, such as Ruby on
The view component is used for all device logic of Rails, ASP.NET MVC, and Sinatra. [6].
the UI. For example, the Consumer View would
Key design point of Laravel:
contain all UI elements, such as text boxes, drop-
downs, etc., in which the final user interacts. 1-Eloquent ORM (object-relational mapping) is an
advanced PHP implementation of the active record
C. Controller pattern, offering at the same time internal methods for
Controller serve as an interface between Model and placing restrictions on the relationship between
View components to handle both business logic and database objects
incoming queries, to control data using the Model object, 2- Application logic is an integral part of the
and to communicate with Views to render the final applications that have been created, either by using
output. For example, the Customer Controller can controllers or as part of the route declaration
manage all Customer View experiences and inputs and
3- Class auto-loading allows automatic loading of
update the database using the Customer Model. The
same controller can be used to display the data of the PHP classes without the need for manual management
customer. An important thing to know about MVC is the of inclusion routes
Model and View never interacts with each other. Any 4- Reverse routing determines the relationship
interactions between them are done through the between the connections and the paths, making it
controller a birthing controller between the Model and possible for future improvements to the routes to be
View means that the presentation of data and the logic immediately propagated to the related links. When
of data are completely separated which makes creating connections are created using the names of the current
complex applications much easier. routes, Laravel will automatically create the required
III. PHP FRAMEWORK standardized resource identifiers (URIs).
5- Migration offers a version control mechanism for
database schemas, making it easy to associate
A. CakePHP changes to the codebase of the program and the
CakePHP is an open source web application necessary changes to the database structure. As a
framework. It follows the Model-View Controller result, this function simplifies the implementation and
(MVC) approach and is written in PHP, modeled upgrade of Laravel-based applications.
after the concepts of Ruby on Rails, and distributed
D. Phalcon
under the MIT License. [4]
CakePHP incorporates well-known software Phalcon is an open source full stack framework
engineering principles and software architecture for PHP, written as a C-extension. Phalcon is
trends, such as Configuration Convention, Model- optimized for high performance. Its unique
architecture allows the framework to always be

609
Authorized licensed use limited to: UNIVERSIDADE DE SAO PAULO. Downloaded on July 24,2024 at 18:52:42 UTC from IEEE Xplore. Restrictions apply.
2021 International Conference on Information Technology (ICIT)

memory resident, offering its functionality whenever Comparisons


Author
it’s needed, without expensive file stats and file Framework environment performance
reads that traditional PHP frameworks employ. [7] Windows 10
Intel Core i5
E. Symfony Ummi Memory
and 12 GB ,
khaira latif, Laravel usage,
memory tested
Symfony is an Open Source PHP framework for web Tien Yii
salary table
Response
applications and a set of reusable PHP components. It kusumasari time
with 2.844.04
was originally conceived in 2005 by the interactive entry php7
agency Sensio- Labs for the development of web sites
for its own customers. [8]
V. FIGURE OF THE TEST
F. Yii
A. Request per second
Yii is a high-performance, component-based PHP
Figure 1 shows the performance comparison among
framework for developing large-scale web applications
MVC: symfony2 Codeigniter CakePHP Symfony
rapidly. It enables maximum reusability in web
phalcon, and Laravel. It can be shown that Laravel
programming and can significantly accelerate your Web
outperforms other MVC on request per second. It was
application development process. Like most PHP
able to handle 3000 requests per second compare to
frameworks, Yii is an MVC framework. Yii excels among
others in this case, the higher output represents the
PHP frameworks at being efficient, feature-rich and
perfect score, which means the highest results.
clearly-documented. Yii is carefully designed from the
ground up to be fit for serious Web application
development. It is neither a byproduct of some project 3500 3000
nor a conglomerate of third-party work. It is the result of 3000
the authors' rich experience with Web application Request Per Second 2500 2200
development and their investigation of the most popular 2000
Web programming frameworks and applications. [9]. 1300
1500
IV. EVALUATION OF THE PERFORMANCE 1000 750
In order to conduct a benchmarking study between 500 231.99
49.33
Laravel, Symfony phalcon Yii symfony2, CakePHP, and 0
Codeigniter.
See the below table contains all information about the
authors, frameworks, the Environment they used in the
test, and the Performance Test.
FIGURE 1. Request per second among PHP framework
TABLE I. AUTHORS AND FRAMEWORK THEY USED

Comparisons B. Response Time


Author
Framework environment performance Figure 2 The time of the page to submit a response
Majida Request per from the system. Calculated by millisecond. The lower
laaziri, Intel core i5 second, number of milliseconds of the MVC determined the
Khaoula ,8GB ,DDR3 Memory
Laravel better output. Figure 2 shows phalcon came out to be
benmoussa ,SATA3,SSD,U usage,
Codeigniter with the least response time.
Samira buntu 14.04 Response
Symfony
khoulji, LTS, Apache time,
Mohamed 2.4, PHP5.5 Number of
kerkeb files 25
web design
Request per 20.27
Rashidah second, 20
Laravel which contains
olanrewaju Memory
Response time /mills

Codeigniter “hello word” 14.73


Thouhedul usage, 15 12.79
Symfony was carried out
isalm, Response
CakePHP on apache (ab
Nor’ashikin time,
–c 200 –n 10 7.24
Bet ali, Number of
50000)
files 4.46 4.93
5 3.1
(ab-Apache
Benchmark
tool) comes Request per 0
with the second,
Natalya Apache Web Memory
prokofyeva, Phalcon server. usage,
Victoria Symfony2 method:both Response
boltunova frameworks time,
were loaded Number of FIGURE 2. Response time among PHP framework
with 2,000 files
requests

610
Authorized licensed use limited to: UNIVERSIDADE DE SAO PAULO. Downloaded on July 24,2024 at 18:52:42 UTC from IEEE Xplore. Restrictions apply.
2021 International Conference on Information Technology (ICIT)

C. Number of Files the developer faces when they choose a framework, so


As shown in Figure 3, phalcon come up with the least we collect many framework and compare between them
file of 10, then symphony with 15 files, then The outcome of testing this framework: Laravel,
Codeigniter with 22 files followed by Laravel with 26, CakePHP, Codeigniter, symfony2, Phalcon, Symfony,
CakePHP 37 files, while symfony2 loaded 301 files. and Yii using criteria such as (Request per second,
Response time, Number of files and, Memory usage) in
each framework shows that the Laravel outperforms
350 301 other MVC framework in request per second, memory
300 usage. On the other hand, phalcon outperforms other
250
Number Of File Requierd

MVC frameworks in response time and number of files.


200 Phalcon and Laravel are all web platforms based on
150
PHP. PHP is used as a programming language in both
100
26 37
15 22 frameworks When it comes to developing or create
50 10
websites. Laravel has a built-in ORM that runs on a
0
conventional object-oriented programming or relational
scheme. Phalcon used a Volt template engine that is
faster than ORM. Phalcon is primarily used for its
quicker execution. Laravel is more common than
FIGURE 3. Number of Files Required among PHP framework phalcon because it has better documentation available,
D. Memory Usage it has a wider and more extensive set of repositories to
work on and grow the software. It's going to have a
Figure 4 indicated that Laravel is about 518KB higher and wider community to reach out if any support
compare to phalcon with 530KB, Codeigniter with is needed. There's no harm in using the other because
725KB follows by symphony with a memory usage until we're not trying to test the technology, we're not
of about 1711, symfony2 with 1586KB, then going to be able to work on it or we can't be comfortable
CakePHP with 2824KB. Hence, it can be with it. So, it depends on the developer’s requirement
concluded that Laravel is memory usage efficient. and time to select the framework for the web
application.
4000 3500
References
[1] Bergström, A., & Hernberg, H. (2020). A comparative study of
3500
2824.26 ASP.NET Core MVC and CodeIgniter for web development
3000 (Dissertation).
Memory usage in KB

2500 [2] Z. Hui, Z Hoa and C. Qijun, “The Research of Dynamic Statistics
1711.57 Chart Based on MVC Design Pattern,” International Conference
2000 1586 on System Science ang Engineering (ICSSE), Shanghai, China,
1500 2014.
1000 752.55 [3] N. Wang, L. Li, Y. Wang, Y. B. Wang and J. Wang, “Research
518 530 on the Web Information System Development Platform Based
500 on MVC Design Pattern,” International Conference on Web
0 Intelligence and Intelligent Agent Technology, 2008.
[4] H. Shu-qiang and Z. Huan-ming, “Research on Improved MVC
Design Pattern Based on Struts and XSL,” International
Symposium on Information Science and Engieering, 2008.T.
Wang and L. Jiang, “Research on IETM Publishing System
Based on MVC Pattern,” WASE International Conference on
FIGURE 4. Memory Usage among PHP framework Information Engineering, 2010.
[5] MIT License - Wikipedia
[6] https://codeigniter.com/
VI. CONCLUSION [7] https://laravel.com/
[8] https://docs.phalcon.io/
[9] https://symfony.com/
The pattern MVC-based PHP framework has [10] https://www.yiiframework.com/
achieved the separation of user experience and [11] Olanrewaju, Rashidah & Islam, Thouhedul & Ali, Norashikin.
business logic for the creation of web applications, (2015). An Empirical Study of the Evolution of PHP MVC
offering simple methods and clarification of architecture Framework. 10.1007/978-3-319-07674-4_40.
and structure execution. PHP frameworks have always [12] Majida Laaziri, Khaoula Benmoussa, Samira Khoulji, Mohamed
been the default option for developers to build complex Larbi Kerkeb(2019), A Comparative study of PHP frameworks
performance,10.1016/j.promfg.2019.02.295.
web applications, particularly large open-source
[13] Latif, U., & Kusumasari, T. (2018,). COMPARISON BETWEEN
projects. YII FRAMEWORKS AND LARAVEL IN 3 DIFFERENT
An Empirical Study of the Most Popular MVC pattern for VERSION FOR VIEWING LARGE DATA OF SHIPYARD
PHP Frameworks has been evaluated in this paper, INDUSTRY IN INDONESIA. 10.25124/ijies.v2i01.12
choosing the most relevant frameworks and appropriate [14] Natalya Prokofyeva, Victoria Boltunova (2017), Analysis and
support functions to include in their project is a problem Practical Application of PHP Frameworks in Development of
Web Information Systems, 10.1016/j.procs.2017.01.059

611
Authorized licensed use limited to: UNIVERSIDADE DE SAO PAULO. Downloaded on July 24,2024 at 18:52:42 UTC from IEEE Xplore. Restrictions apply.

You might also like