Category: PHP

How to Make PHP mail() Function Work in Localhost Server

There are several ways that could make PHP mail() function work in localhost. I haven’t tried them except for the solution below: Download sendmail and extract it on your desired location. Open sendmail.ini and...

Display PHP Errors

The following code snippet will show php errors and warnings if there is any.

Create a Dynamic PDF File Based on User’s Input

When I need to create a pdf using PHP, I prefer to use the TCPDF library, because I find it easy to use and flexible. I the tutorial Create a PDF Using PHP and...

Create a Graph Using PHP and SVGGraph

Creating a graph is very easy with the aid of SVGGraph library. You can download it here. This library supports almost all kinds of graphs such as pie graph, line graph, bar graph, and...

Create a PDF Using PHP and TCPDF

If you search online about how to create a PDF using PHP, you will find so many ways on how to do it. There are so many libraries that you can download together with...

Import Mysql Using PHP

On phpmyadmin, export the database.

Mysql Copy a field’s value to another related table

The task is to copy the value of the oldfield field to newfield field [code] UPDATE table2 SET newfield = (SELECT oldfield FROM main_table WHERE table2.qid = main.qid) [/code]

Generate RTF File Using PHP

This tutorial will show you how to generate Rich Text Format file using PHP and RTF tags (not html tags). This is somehow complex compated to using html tags, but this will produce a better result.

Create an RTF File and Add Page Break Using PHP

Adding a page break on a rich text format file created using PHP is very easy. Just add “

Note: This does not work on Wordpad Editor.