PHP
- How do I create dynamic websites using PHP/javascript/HTML/CSS?chat-to.dev How do I create dynamic websites using PHP/javascript/HTML/CSS?
# <br>Overview Dynamic websites are the website on which a user sends the request from the client side to the server side and the data is rendered in the backend, as PHP is a server side scripting language so it plays the main role while creating dynamic websites. Some of the dynamic websites are li...
- Why PHP Usage Has Declined by 40% in Just Over 2 Yearsthenewstack.io Why PHP Usage Has Declined by 40% in Just Over 2 Years
PHP popularity has dropped dramatically, coinciding with WordPress becoming "JavaScript-first" according to its co-creator Matt Mullenweg.
> In conclusion, it is easy to see PHP in 2024 as the forgotten child of web development, while JavaScript is the most popular kid in class. Sadly for PHP, its decline in usage is unlikely to stop any time soon — why would it, when WordPress developers are busy adapting to a new JavaScript paradigm? But at least there is active development at the PHP Foundation.
- Help installing PHP on Ubuntu (Solved. Thank you!)
(I'm currently using Firefox 124.01 on Ubuntu 22.04.03 LTS) (My formatting is also givinge problems... I want to eat my own eyeballs out right now...)
I'm very new to Linux, and trying to get PHP installed, but it won't render anything...
Following this guide (https://ubuntu.com/server/docs/programming-php), I started with:
sudo apt update sudo apt install apache2
Test Page Success!
So I continue with:
sudo apt install php libapache2-mod-php sudo apt install php-mysql sudo apt install php-cgi
Then:
sudo systemctl restart apache2.service
I write the following in /var/www/html/index.php:
``` <?php
phpinfo();
Test Text1
?>
Test Text2 ```
I see "Test Text2" and nothing else. I see my PHP tags and their contents upon source inspection.
Then I perform the following:
apt list --installed | grep php sudo apt purge php apt list --installed | grep php (0 Results)
And try again: ``` sudo apt install php libapache2-mod-php sudo apt install php-mysql sudo apt install php-cgi
sudo systemctl restart apache2.service ```
No luck... Any ideas what's going on?
A little additional info:
~$ which php /usr/bin/php
~$ php -v PHP 8.1.2-1ubuntu2.14 (cli) (built: Aug 18 2023 11:41:11) (NTS) Copyright (c) The PHP Group Zend Engine v4.1.2, Copyright (c) Zend Technologies with Zend OPcache v8.1.2-1ubuntu2.14, Copyright (c), by Zend Technologies
``` ~$ apt list --installed | grep phpWARNING: apt does not have a stable CLI interface. Use with caution in scripts.
libapache2-mod-php8.1/jammy-updates,jammy-security,now 8.1.2-1ubuntu2.14 amd64 [installed,automatic] libapache2-mod-php/jammy,jammy,now 2:8.1+92ubuntu1 all [installed] php-common/jammy,jammy,now 2:92ubuntu1 all [installed,automatic] php-mysql/jammy,jammy,now 2:8.1+92ubuntu1 all [installed] php8.1-cli/jammy-updates,jammy-security,now 8.1.2-1ubuntu2.14 amd64 [installed,automatic] php8.1-common/jammy-updates,jammy-security,now 8.1.2-1ubuntu2.14 amd64 [installed,automatic] php8.1-mysql/jammy-updates,jammy-security,now 8.1.2-1ubuntu2.14 amd64 [installed,automatic] php8.1-opcache/jammy-updates,jammy-security,now 8.1.2-1ubuntu2.14 amd64 [installed,automatic] php8.1-readline/jammy-updates,jammy-security,now 8.1.2-1ubuntu2.14 amd64 [installed,automatic] php8.1/jammy-updates,jammy-updates,jammy-security,jammy-security,now 8.1.2-1ubuntu2.14 all [installed,automatic] php/jammy,jammy,now 2:8.1+92ubuntu1 all [installed] ```
/etc/apache2/mods-enabled$ ls access_compat.load authz_core.load deflate.load mime.load php8.1.load status.load alias.conf authz_host.load dir.conf mpm_prefork.conf reqtimeout.conf alias.load authz_user.load dir.load mpm_prefork.load reqtimeout.load auth_basic.load autoindex.conf env.load negotiation.conf setenvif.conf authn_core.load autoindex.load filter.load negotiation.load setenvif.load authn_file.load deflate.conf mime.conf php8.1.conf status.conf
- PHP Annotated – February-March 2024blog.jetbrains.com PHP Annotated – February-March 2024 | The PhpStorm Blog
Welcome to the February–March edition of PHP Annotated! We'll recap the most interesting developments in the PHP community over the past couple of months, featuring handpicked news, articles, tools, a
- ActivityPub Server in a Single PHP Fileshkspr.mobi ActivityPub Server in a Single PHP File
Any computer program can be designed to run from a single file if you architect it wrong enough! I wanted to create the simplest possible Fediverse server which can be used as an educational tool to show how ActivityPub / Mastodon works. The design goals were: Upload a single PHP file to the server....
- PHP 8.2.16 Releasedwww.php.net PHP: Hypertext Preprocessor
PHP is a popular general-purpose scripting language that powers everything from your blog to the most popular websites in the world.
- PHP 8.3.3 Released!www.php.net PHP: Hypertext Preprocessor
PHP is a popular general-purpose scripting language that powers everything from your blog to the most popular websites in the world.
- Improve my code - function to sanitize input fieldschat-to.dev Chat Rooms and Programming Content | Chat-to.dev
Join chat rooms and explore programming content on Chat-to.dev.
i created this function to sanitize the input fields on my site, but i need it (the function) to allow the input of some html tags. how can i improve the function to allow this?
- PHP Annotated – January 2024blog.jetbrains.com PHP Annotated – January 2024 | The PhpStorm Blog
Welcome to the January edition of PHP Annotated! We'll recap the most interesting developments in the PHP community over the past month, featuring handpicked news, articles, tools, and videos. Highl
- Library validate against graphql schema
Does anyone knows a good library to validate queries and mutations again a graphql schema file? To ensure the query/mutation is valid before sending it to the server.
- FrankenPHP v1.0 is Herelaravel-news.com FrankenPHP v1.0 is Here - Laravel News
FrankenPHP is a modern PHP application server written in Go, FrankenPHP gives you a production-grade PHP server with just one command.
- PHP Annotated – November 2023 | The PhpStorm Blogblog.jetbrains.com PHP Annotated – November 2023 | The PhpStorm Blog
Welcome to the November edition of PHP Annotated! In it, we look back over some of the most interesting developments in the PHP community during the past month, featuring handpicked news, articles, to
- Exploring stdClass in PHPdev.to Exploring stdClass in PHP
Ever encountered scenarios in PHP where creating objects dynamically without adhering to a predefined...
- PHP: why make your own exceptions?dev.to PHP: why make your own exceptions?
Like many other programming languages, PHP allows throwing and catching exceptions. If you surround...
- FrankenPHP 1.0 Betadunglas.dev The PHP Revolution Is Underway: FrankenPHP 1.0 Beta - Kévin Dunglas
I'm very proud to announce the immediate availability of FrankenPHP 1.0 beta. FrankenPHP is a brand-new application server for PHP, written in Go and built on top of Caddy, that dramatically simplifies the deployment of PHP apps, and brings new features to PHP such as: a worker mode that improves ty...
- PHP wishlist for 2024medium.com PHP wishlist for 2024
It’s never too late to make the language cooler through some hypothetical features
- Understanding the Strategy Design Pattern in PHP with a Simple Examplehashemirafsan.medium.com Understanding the Strategy Design Pattern in PHP with a Simple Example
The Strategy design pattern is a behavioral design pattern that allows an algorithm to vary independently from clients that use it. In…