Learn how to access data in Firebird from PHP.
Category: PHP
PHP is a scripting language that’s usually embedded or combined with HTML and has many excellent libraries that provide fast, customized access to DBMSs.
Microsoft SQL Server
Learn how to access data in Microsoft SQL Server from PHP.
Using Oracle
This tutorial covers the essentials you need to know to use Oracle with PHP.
How to use PostgreSQL
PHP supports PostgreSQL, the pg_connect() function is used to connect to a PostgreSQL database server. Once a connection has been established, SQL commands can be executed with the pg_query() function.
How to use MySQLi
PHP allows developers to interact with databases in two ways: MySQLi (MySQL Improved) extension and PDO (PHP Data Objects) extension. In this tutorial we’ll discuss the MySQLi extension which provides both speed and feature benefits over the PDO version and is a good choice for MySQL (or MariaDB) specific development projects.
Configuring Sessions in PHP.INI
The configuration of PHP’s session mechanism is completely triggered in the [session] section of the php.ini configuration file. The default settings might not be suitable for all applications, so the next few codes cover some possible configurations.
Sessions Garbage Collection
How to configure PHP’s Garbage collection mechanism to remove old/expired sessions from the server.
HTTP Authentication with Sessions
The HTTP provides two methods of authentication: basic and digest. In this tutorial, we’ll discuss only “Basic” authentication method and use this method in conjunction with PHP sessions.
Sessions are a great way to secure certain parts of your website. In this tutorial, we create a PHP script that checks the site users, redirects unauthenticated users to the login page, and after a successful authentication sends them back to the page where they came from.
Storing Sessions in Database
By default, sessions are read from files, you can use the session_set_save_handler() function to define custom session handlers to store session data in a database. In this tutorial, we’ll create two code snippets, Procedural and OOP, to manage session data.