Choose your database:
AnySQL
MySQL
MS SQL Server
PostgreSQL
SQLite
Firebird
Oracle
SQL Anywhere
DB2
MaxDB

Subscribe to our news:
Partners
Testimonials
Jonathan Oakes: "This is a lovely application. It's easy to hook into my own bespoke applications. It's very powerful, yet really quite simple to use. Thanks for this".
Grey: "We're a two-person company, it's just me an my wife. I'm the technical guru, and she handles the business operations. I have to know a lot about MySQL, but that's much too technical for her. I have frequently had to setup CGI scripts (I code in Perl) so she can manage some of our tables (suppliers, manufacturers, etc).

I discovered PHP Generator a couple of days ago, tried the free version,and within a few hours I had purchased the Pro version (as well as SQL Maestro for MySQL).

Today I am completing the conversion of the last of my custom table managers to PHP Generator. This is eliminating several thousand lines of code that I don't have to support any more!

Thanks for this fantastic product".

More

Add your opinion

PHP Generator for MySQL online Help

Prev Return to chapter overview Next

Print

The table below show parameters for customizing printer-friendly version of the page.

 

State of the webpage

Page Part

Default template

Parameters

Print

webpage layout (list page)

print/page.tpl

PagePart::PrintLayout PageMode::PrintAll

data grid (list page)

print/grid.tpl

PagePart::Grid

PageMode::PrintAll

detail page

print/detail_page.tpl

PagePart::PrintLayout PageMode::PrintDetailPage

webpage layout (single record)

print/page.tpl

PagePart::PrintLayout PageMode::PrintOneRecord

data grid (single record)

view/print_grid.tpl

PagePart::Grid

PageMode::PrintOneRecord

 

Example

 

This example learns how to implement a two-column version of the printer-friendly page. It can be seen live in our Feature Demo that also contains an example of customization templates for printing a single record. You can study these examples online or download the demo project file for a deeper investigation.

 

 

The template code is as follows:

 

<div style="max-width: 800px">

{foreach item=Row from=$Rows name=RowsGrid}

    <div style="width: 50%; float: left; padding-bottom: 2em; border-bottom: 1px solid #ddd">

        <h3>{$Row.1} <small>({$Row.2})</small></h3>

        <table>

            <tr>

                <td style="text-align:right"><strong>Become independent (year)</strong></td>

                <td style="text-align:left">{$Row.3}</td>

            </tr>

            <tr>

                <td style="text-align:right"><strong>Population</strong></td>

                <td style="text-align:left">{$Row.4}</td>

            </tr>

            <tr>

                <td style="text-align:right"><strong>Life Expectancy</strong></td>

                <td style="text-align:left">{$Row.5}</td>

            </tr>

        </table>

    </div>

{/foreach}

</div>

 

The event handler code is as follows:

 

if (($part == PagePart::Grid) && ($mode == PageMode::PrintAll)) {    

       $result = 'custom_print_list.tpl';

}

    



Prev Return to chapter overview Next