- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 1049 Articles for PHP
16 Views
This article explains how to handle XML documents in PHP. XML (eXtensible Markup Language) is defined as a textual markup language designed for both people and computers. It is a format used for storing and moving data between applications. PHP simplexml_load_string() function provided by PHP allows us to parse XML strings with ease and this function will convert XML string into an object for us which can be examined in order to understand XML data. Usong PHP simplexml_load_string() Method PHP simplexml_load_string() function accepts an XML string and returns a SimpleXMLElement object, the object has properties and methods that will ... Read More
37 Views
Arrays are linear data structures used to handle data in programming. Sometimes while dealing with arrays we need to add new elements to an existing array.In this article, we will discuss several methods to add elements to the end of an array in PHP, complete with code examples, outputs, and an analysis of the time and space complexity of each approach. Following are different approaches to adding elements to an array − Using square brackets [] We add an element to the end of an array in PHP is by using square brackets []. This syntax is only suitable when ... Read More
73 Views
To force PHP to use strings for array keys is quite easy, as in PHP array keys are automatically stored as integers if the array elements are numbers. If they are not numbers then it will cast to strings. Forcing PHP to Use strings for Array Keys Following are the ways to force PHP to use strings for array Keys Using php array() function Using json_encode() function Using php array() Function If you use the array() function and keep the first key in quotes it will take other keys as a string does not matter if you are ... Read More
467 Views
Given task is to find all the students with marks greater than average marks using SQL. i.e. if the marks of students in a class are 65, 75, 89, 92, and, 60 then the average would be 76.2 and, the query should return records with the marks 89 and 92. Let's start step by step. Creating a Table First of all, we need to create a table called Students using the CREATE statement. This table has three columns Student_Id, Subject, and Marks. This table stores three types of subjects, and marks range from 0 to 100 − CREATE TABLE ... Read More
165 Views
To use PHP in HTML, you must enclose the PHP code with PHP start tag . In this article from the example we will learn to use and become comfortable with PHP in HTML. PHP (Hypertext Preprocessor) is a popular server-side scripting language used for web development. It allows you to embed dynamic content into your HTML. Approach to use PHP in HTML To effectively use PHP in HTML, you need to enclose PHP code within tags. Remember, PHP files must have a .php extension since PHP code is processed on the server before the page is ... Read More
383 Views
Introduction Navigating through database operations in XAMPP can be challenging, particularly for beginners. Realizing this complexity, over 15 million active monthly users have turned to XAMPP for its ease of use and flexibility. This article offers a step-by-step guide on performing basic database operations in XAMPP, from data insertion to deletion. Let's take the first stride towards mastering your XAMPP database management skills together! Basic DataBase Operations in XAMPP Basic DataBase Operations in XAMPP include performing CRUD operations such as select, insert, update, and delete statements on a MySQL database using PHP. SELECT Statement The SELECT statement is a ... Read More
406 Views
Hosting websites and online applications requires setting up a web server infrastructure. In this article, we'll try to understand the setting up of Nginx on Fedora 24 Server and Workstation using MariaDB and PHP/PHP-FPM. This combination creates a strong stack for managing databases and presenting dynamic content. The main concepts covered here can be applied to subsequent versions of Fedora or other Linux distributions, even if Fedora 24 is an older edition. Main Characteristics of Fedora 24 Server Fedora 24 Server was created using the Linux kernel, which serves as the foundation of the operating system. The Linux kernel offers ... Read More
334 Views
LEMP stack is a powerful combination of open source technology used for Web development and hosting. LEMP comprises Linux, which is the operating system in the combination, Nginx (pronounced as engine x) is a web server software, used to handle HTTP requests from servers, it helps the delivery of static and dynamic content. MySQL or MariaDB are used for efficient data storage and retrieval and PHP is used to construct dynamic web applications, enabling developers to communicate with databases and integrate dynamic information into HTML pages. Installing and configuring each component of LEMP, one at a time is required to ... Read More
305 Views
Setting up LAMP (Linux, Apache, MySQL/MariaDB, PHP, and PhpMyAdmin) in Ubuntu Server 14.10 includes putting in and configuring an effective net improvement stack. LAMP affords an entire environment for growing and deploying dynamic web sites and net programmes. Linux serves as the running system, offering a strong and steady basis for the stack. Apache acts as the net server, managing incoming requests and serving net pages. MySQL/MariaDB serves as the relational database control system for storing and dealing with data. PHP is the scripting language used for dynamic content generation. Additionally, PhpMyAdmin is established as a net-primarily based total management ... Read More
215 Views
Follow these instructions to install LAMP (Linux, Apache, MariaDB, and PHP) on a Fedora 24 server. First, perform a minimum installation of Fedora 24. Install the necessary components, including PHP, MariaDB, and Apache, after updating the system. Activate the automatic startup of the Apache server and permit incoming HTTP traffic over the firewall. Set a strong root password, activate the MariaDB service, and safeguard the installation. Set PHP settings appropriately for your needs. By creating a straightforward PHP file and using a web browser to view it, you may test the LAMP architecture. After completing these procedures, your Fedora 24 ... Read More