Article

How to Create our First Application with PHP

Topic: Career DevelopmentPublished September 5, 2019
No ratings yet522 viewsSign in to rate
If you are new to PHP, we recommend you read our article What is PHP and other details, so that you are familiar with this tutorial, what we will do is launch a message and print the date and time of the server with PHP, to achieve this you must have the tools and environment necessary for PHP to run smoothly. To be able to create applications or projects with PHP, you need to have a server installed that interprets or reads the PHP programming language, for this example we will only need PHP, but if you want to create more advanced projects where you need to save, edit, delete and list data, you will need a server with database support. PHP is a Server-side Programming Language, that is, it only works on a Web server, unlike the Javascript Programming Language that works on any user interface, but does not need a server, except Node JS which is Javascript-side server, if you need a server to function. Web Server Deployment You can choose to install the following local servers to start creating applications on your PC and then use a paid server, each of these local servers is created for the corresponding operating system, some have support for different operating systems: Wamp server It is a Local server developed for the Windows Operating System after its installation it deploys Apache Web Server, Open SSL, MySQL Database, PHP interpreter among other utilities. Xampp rnIt is a Local server developed for Windows, Linux and Mac OS X operating systems from Apple when installed integrates MySQL Database, Apache Web Server, Interpreter PHP and Perl, Maria DB among other utilities Mampp rnIt is a Local server created by the Mac OS X operating system from Apple, trans performing its installation integrates the Apache Web Server, MySQL Database, interpreter of PHP, Perl, Python, Ruby Programming Languages ​​among other utilities. Cloud Server (Internet) These servers are paid, most web pages are hosted on this type of servers such as the pages and applications you visit online. You can choose to hire an annual or monthly payment server, but check that it has support for PHP, Apache, MySQL Database, interpreter of PHP Programming Languages, all these are enough to run your applications with PHP. I have a paid server that supports PHP and Database which allows me to create applications like this tutorial: Notifications System with PHP, MySQL, jQuery Ajax and Bootstrap 4. Let's check also Deploy PHP Application on Kubernetes with 6 easy steps Creating the PHP Application To not go so far, we will start installing a local server, for this we will use Xampp, download and install this server like any program. 1. When you install Xampp you will be created an icon of the program, open the program and click on the Start button that corresponds to Apache and MySQL, although we will not use MySQL Database, we advise you to activate it for future applications, the Start button should have changed to Stop. 2. After installing Xampp, you create a directory structure in your operating system, do not touch the other directories if you do not know, just access or open the htdocs directory 3. Inside the htdocs directory create a folder with the name you want, for example, miaplicacionphp and inside it create a file called index.php The file created index.php has the extension .php that indicates that the format of that file has content of the PHP Programming Language. Open the index.php file and inside it, we will create a message and then print the date and time with PHP. Before continuing we emphasize that the time with PHP is the time of the server, but not the current time of your Computer, to get the time of your computer Javascript is used, but this is another issue. In the previous code you can see that to start writing code with PHP you must start by typing the We also add a line space with

to separate the Text from the date and time. Now go to your browser to run the application, type the following path in the navigation bar: http: // localhost / miaplicacionphp / and get the Text, space and Date and time with PHP rnWith this, we have created our first application purely with PHP. Notes 1. Some steps may change in future versions of the tools, this does not depend on us, but on the developers who support these tools.rn2. Having the basis explained in this article, you can create more advanced applications with PHP.

Further reading

Further Reading

4 total

Article

If you've ever wanted to create the ultimate custom draft experience for your Magic: The Gathering playgroup, building a Magic Cube is one of the most rewarding projects you can take on. An MTG Cube is a curated collection of cards designed to be drafted over and over again, offering endless replayability and a deeply personal expression of what you love about the game. Whether you prefer blazing-fast aggro strategies, intricate combo lines, or grindy control mirrors, your cu

February 23, 2026

Article

Key Takeaways: Family Nurse Practitioners (FNPs) provide comprehensive primary care, bridging the gap between traditional nursing and advanced clinical practice. Expanding the scope of practice enables FNPs to enjoy greater autonomy, higher earning potential, and improved access to care. Specialization, leadership, academic, telehealth, and entrepreneurial roles offer diverse career pathways and professional growth. FNPs play a critical role in shaping healthcare delivery, in

February 9, 2026

Article

The online graduate certificate in drug discovery and development provides a strategic educational platform for professionals preparing to lead innovation in pharmaceutical science. With flexible, asynchronous learning and a curriculum grounded in applied research and regulatory principles, this program at The University of North Texas Health Science Center at Fort Worth is well-suited for individuals seeking to expand their competencies while balancing academic, clinical, or

July 18, 2025

Article

Life often feels like a delicate balancing act between work, family, social obligations, and the everyday chores that never seem to end. One of the most time-consuming of these is keeping a home clean and organized. Recent trends and statistics reveal that more people are turning to professional home cleaning services as a practical solution to free up their schedules and reduce stress. My Cleaning Angel stands at the forefront of this movement, offering reliable home cleanin

May 1, 2025