Categories
PHP

Validating HTML and XML

How to validate XML and HTML files (or strings) with PHP’s DOMDocument class.

Categories
PHP

Handling Errors While Parsing XML

How to use libxml extension to handle errors while parsing XML string or file.

Categories
PHP

Parsing XML with SAX

With SAX Parser, you create functions to deal with specific events, for example, the start or end of an XML element (tag). When the parser encounters an XML element, it calls the event handler functions to process that element.

Categories
PHP

Transforming XML with XSL

How to transform an XML document and an XSL stylesheet using XSLT and capture the results.

Categories
PHP

Parsing and Creating XML with DOM

Learn how to use DOM to read all elements in the XML file and outputs them. Also how to append data to an XML file (or create a new XML file if not already exists).

Categories
PHP

Parse Feeds URL and XML Files

This tutorial describes how to parse an XML document or RSS feed that follows a known schema.

Categories
PHP

PDO – Set character encoding of a database

The type of character set used on the HTML page must match the character set used in the database table. In this tutorial, we’ll specify the utf-8 encoding for PHP, MySQL database, HTML page, and Notepad++ editor.

Categories
PHP

PDO – Insert, update, and delete records

In this tutorial, you’ll learn how to retrieve, insert, update, and delete data using PDO’s query, prepare, and exec functions.

Categories
PHP

Connecting Different Databases Via PDO

PDO (PHP Data Objects) defines a lightweight, consistent interface for accessing many different SQL databases in PHP. You can write and execute database queries with a single interface regardless of the particular database system we happen to be using at the time.

Categories
PHP

How to Use SQLite

SQLite is a fast, efficient database system that offers a viable alternative to MySQL/MariaDb. In this tutorial, we’ll teach you: how to create a database and tables, insert and retrieve data and how to use prepared statements to insert form data.