PHP Generator Feature Demo
  • Themes
    • Default
    • Default compact
    • Cerulean
    • Cerulean compact
    • Cosmo
    • Cyborg
    • Darkly
    • Darkly compact
    • Facebook
    • Flatly
    • Journal
    • Lumen
    • Paper
    • Readable
    • Sandstone
    • Simplex
    • Slate
    • Slate compact
    • Spacelab
    • Superhero
    • Superhero compact
    • United
    • United compact
    • Yeti
    • Yeti compact
  • English
    • German
    • Brazilian
    • Czech
    • Danish
    • Spanish
    • Finnish
    • French
    • Hungarian
    • Italian
    • Dutch
    • Polish
    • Russian
    • Swedish
    • Slovak
    • Slovenian
    • Serbian
    • Turkish
    • Arabic
  • Learn more
    • PHP Generator Feature Demo
    • About this demo
    • Download project file for this demo
    • Check out other PHP Generator demos
    • NBA Database Demo
    • Security Demo
    • MySQL Schema Browser Demo
    • Learn more about our products
    • Try PHP Generator for free
    • SQL Maestro Group website
    • Follow us
    • Facebook
    • Twitter
    • YouTube
  • Recently added/updated
    • Grid Toolbar
    • Tabbed Forms
    • Stepped Area Chart
    • Candlestick Chart
    • Histogram Chart
    • Bubble Chart
    • Timeline Chart
    • Gantt Chart
    • Scatter Chart
    • Tree Map Chart
    • Export options
    • Invoice generation
    • Inline Button
    • HTML Wysiwyg
    • Watermarks
  • Data Grid
    • Table View
    • Card View
    • Autohiding Columns
    • Totals
    • Grid Header
    • Column Grouping
    • Record Comparison
    • Unicode Support
    • RSS
    • Custom Drawing
    • Custom Table Template
    • Custom Card Template
    • Custom Toolbar Template
    • Custom View Form
  • Grid Columns
    • Column Types
    • Text Truncating
    • Column Fixed Width
    • Formatting
    • Null Label
    • Hyperlinks
    • Html Display
    • Lookup Data View
    • Custom Rendering
  • Grid Options
    • Fixed Grid Width
    • Fixed Column Header
    • Bordered Table
    • Condensed Table
    • Line Numbers
    • Control Buttons Position
  • Data Sources
    • Table
    • View
    • Non-Updatable Query
    • Updatable Query
    • Updatable View
  • Master-Detail Views
    • Master/Detail Basics
    • Multiple Details
    • Nested Details
    • Card Mode Details
  • Data Input Forms
    • Separate Page
    • Modal Window
    • Inline Editing
    • Form Layouts
    • Tabbed Forms
    • Custom Separate Page
    • Custom Modal Dialog
    • Custom Inline Form
    • Wizard Form
    • Adding multiple records
    • Editors Overview
    • Validation
    • Client-side API
    • Dependent Lookups
    • On-the-Fly Adding
    • Quick Edit
    • Multi Edit
    • Custom Default Values
  • Editors
    • Text
    • Autocomplete
    • Text Area
    • HTML Wysiwyg
    • Spin & Range
    • Upload To Folder
    • Radio Group
    • Combobox
    • Dynamic Combobox
    • Cascading Combobox
    • Dynamic Cascading Combobox
    • Multiple Select
    • Checkbox Group
    • Common Properties
  • Data Filtering
    • Quick Filter
    • Filter Builder
    • Column Filter
    • Preliminary Filter
    • Selection Filters
    • Custom Filter - 1
    • Custom Filter - 2
  • Sorting
    • Sort By Click
    • Sort By Dialog
    • Default Sort Order
  • Partitioning
    • Range
    • List
    • Custom
  • Exporting & Printing
    • Grid
    • Single Record
    • Export Options
    • Custom Grid
    • Custom Single Record
    • User Defined Styles
  • Image Management
    • Image Galleries
    • Thumbnails
    • Linked Images
    • Multi Upload - 1
    • Multi Upload - 2
    • Watermarks
  • Charts
    • Pie Chart
    • Column Chart
    • Bar Chart
    • Line Chart
    • Area Chart
    • Geo Charts
    • Stepped Area
    • Candlestick
    • Histogram
    • Bubble
    • Timeline
    • Gantt
    • Scatter
    • Tree Map
    • Multiple Charts
    • Chart Placement
    • Customizing Charts
    • Dashboard
  • Many-to-Many Relations
    • Classic Junction Table
    • Handling Extra Columns
  • Fine-tuning & Tweaking
    • Custom Icons
    • Custom Theme
    • Custom Editor
    • Page Embedding
    • Ajax-based Validation
    • Color Themes
    • Barcodes Generation
    • Inline Button
    • Conditional Details
    • Using Ajax in Forms
  • Emailing
    • Basic Usage
    • Advanced Usage
  • Calculated Columns
    • Example - 1
    • Example - 2
  • Custom Templates
    • Grid View
    • Card View
    • Grid Toolbar
    • Single Record View
    • Separate Page Editing
    • Modal Dialog Editing
    • Inline Form Editing
    • Wizard Form
    • Custom Filter - 1
    • Custom Filter - 2
    • Export & Print: Data Grid
    • Invoice generation
  1. Data Input Forms
  2. Data Input Forms.Custom Separate Page
    • Separate Page
    • Modal Window
    • Inline Editing
    • Form Layouts
    • Tabbed Forms
    • Custom Modal Dialog
    • Custom Inline Form
    • Wizard Form
    • Adding multiple records
    • Editors Overview
    • Validation
    • Client-side API
    • Dependent Lookups
    • On-the-Fly Adding
    • Quick Edit
    • Multi Edit
    • Custom Default Values

Data Input Forms.Custom Separate Page

Page settings

Appearance

Here you can select the number of cards to be placed in a row for each of supported screen resolutions. Your current resolution is highlighted in this way.

Page size

Total record count: 200.

page(s).
Cancel Save changes
×

This example demonstrates how to customize Edit and Insert forms in a separate page. You need to override templates forms/form.tpl and forms/page_form.tpl and then bind them with the OnGetCustomTemplate event. Click the button to see how to do it.

Add new
Refresh
Export
  • Export to Pdf
  • Export to Excel
  • Export to Word
  • Export to Xml
  • Export to Csv
Print
  • Print current page
  • Print all pages
  • Clear
  • Selection filter
    • Show selected only
    • Show unselected only
    • Show all
  • Export
    • Export to Pdf
    • Export to Excel
    • Export to Word
    • Export to Xml
    • Export to Csv
  • Print
  • Update
        protected function doGetCustomTemplate($type, $part, $mode, &$result, &$params)
        {
            if ($part == PagePart::VerticalGrid
            && ($mode == PageMode::Edit || $mode == PageMode::Insert)) {
               $result = 'custom_page_form.tpl';
            }
            
            if ($mode == PageMode::FormEdit || $mode == PageMode::FormInsert) {
               $result = 'custom_form.tpl';
            }
        }
{include file="page_header.tpl" pageTitle=$Grid.Title pageWithForm=true}

<div class="col-md-12 js-form-container" data-form-url="{$Grid.FormAction}&flash=true">

    {* <Custom template> *}

    <div class="form-actions form-actions-top row">
        <div class="col-md-12">
            <div class="row">
                <div class="{if $isHorizontal}col-sm-9 col-sm-offset-3{else}col-md-8 col-md-offset-2{/if}">
                    <div class="btn-toolbar">
                        <button type="submit" class="btn btn-primary js-save js-primary-save" data-action="open" data-url="{$Grid.CancelUrl}">
                            {$Captions->GetMessageString('Save')}
                        </button>
                        <a href="#" class="btn btn-default js-save js-multiple-insert-hide" data-action="edit">{$Captions->GetMessageString('SaveAndEdit')}</a>
                        <a class="btn btn-default" href="{$Grid.CancelUrl}">{$Captions->GetMessageString('Cancel')}</a>
                    </div>
                </div>
            </div>
        </div>
    </div>

    {* </Custom template> *}

    <div class="row">
        <div class="js-form-collection {if $Grid.FormLayout->isHorizontal()}col-lg-8{else}col-md-8 col-md-offset-2{/if}">
            {foreach from=$Forms item=Form name=forms}
                {$Form}
                {if not $smarty.foreach.forms.last}<hr>{/if}
            {/foreach}
        </div>
    </div>

    {if $Grid.AllowAddMultipleRecords}
        <div class="row" style="margin-top: 20px">
            <div class="{if $Grid.FormLayout->isHorizontal()}col-lg-8{else}col-md-8 col-md-offset-2{/if}">
                <a href="#" class="js-form-add{if $Grid.FormLayout->isHorizontal()} col-md-offset-3{/if}"><span class="icon-plus"></span> add another record</a>
            </div>
        </div>
    {/if}

    {* <Custom template> *}

    <div class="form-actions row">
        <div class="col-md-12">
            <div class="row">
                <div class="{if $isHorizontal}col-sm-9 col-sm-offset-3{else}col-md-8 col-md-offset-2{/if}">
                    <div class="btn-toolbar">
                        <button type="submit" class="btn btn-primary js-save js-primary-save" data-action="open" data-url="{$Grid.CancelUrl}">
                            {$Captions->GetMessageString('Save')}
                        </button>
                        <a href="#" class="btn btn-default js-save js-multiple-insert-hide" data-action="edit">{$Captions->GetMessageString('SaveAndEdit')}</a>
                        <a class="btn btn-default" href="{$Grid.CancelUrl}">{$Captions->GetMessageString('Cancel')}</a>
                    </div>
                </div>
            </div>
        </div>
    </div>

    {* </Custom template> *}

</div>


<form id="{$Grid.FormId}" class="form-horizontal" enctype="multipart/form-data" method="POST" action="{$Grid.FormAction}">

    {if not $isEditOperation and $Grid.AllowAddMultipleRecords}
        <div class="btn-group pull-right form-collection-actions">
            <button type="button" class="btn btn-default icon-copy js-form-copy" title="Copy"></button>
            <button type="button" class="btn btn-default icon-remove js-form-remove" style="display: none" title="Delete"></button>
        </div>
    {/if}
    <div class="clearfix"></div>

    {include file='common/messages.tpl' type='danger' dismissable=true messages=$Grid.ErrorMessages displayTime=$Grid.MessageDisplayTime}
    {include file='common/messages.tpl' type='success' dismissable=true messages=$Grid.Messages displayTime=$Grid.MessageDisplayTime}

    {* <Custom template> *}

    <div class="row">
        {assign var=Columns value=$Grid.FormLayout->getColumns()}
        <div style="margin: 0px 20px;">
          <ul class="nav nav-tabs" role="tablist">
            <li role="presentation" class="active"><a href="#about-{$Grid.FormId}" aria-controls="about-{$Grid.FormId}" role="tab" data-toggle="tab">About</a></li>
            <li role="presentation"><a href="#add-info-{$Grid.FormId}" aria-controls="add-info-{$Grid.FormId}" role="tab" data-toggle="tab">Additional info</a></li>
            <li role="presentation"><a href="#media-{$Grid.FormId}" aria-controls="media-{$Grid.FormId}" role="tab" data-toggle="tab">Media</a></li>
          </ul>

          <div class="tab-content" style="margin-top: 20px; min-height: 350px">
            <div role="tabpanel" class="tab-pane active" id="about-{$Grid.FormId}">
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.title}
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.original_title}
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.tagline}
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.overview}
            </div>
            <div role="tabpanel" class="tab-pane" id="add-info-{$Grid.FormId}">
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.release_date}
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.original_language_id}
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.genre_id}
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.runtime}
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.rating}
            </div>
            <div role="tabpanel" class="tab-pane" id="media-{$Grid.FormId}">
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.poster}
                {include file="custom_templates/custom_form_column.tpl" Col=$Columns.trailer}
            </div>
          </div>
        </div>
    </div>

    {foreach key=HiddenValueName item=HiddenValue from=$HiddenValues}
        <input type="hidden" name="{$HiddenValueName}" value="{$HiddenValue}" />
    {/foreach}

    {* </Custom template> *}

    {if $flashMessages}
        <input type="hidden" name="flash_messages" value="1" />
    {/if}

    <div class="row">
        <div class="col-md-12 form-error-container"></div>
    </div>

    {include file='forms/form_scripts.tpl'}

</form>

 
Actions Title Genre Release Date Runtime Rating
Star Wars Adventure 1977-03-20 121 7.81
Finding Nemo Animation 2003-11-29 100 7.34
American Beauty Drama 1999-09-15 122 7.63
Pirates of the Caribbean: The Curse of the Black Pearl Adventure 2003-07-03 143 7.24
Kill Bill: Vol. 1 Action 2003-10-10 111 7.47
The Lord of the Rings: The Fellowship of the Ring Adventure 2001-12-18 178 7.75
The Lord of the Rings: The Two Towers Adventure 2002-12-18 179 7.72
The Lord of the Rings: The Return of the King Adventure 2003-12-01 201 7.85
The Dark Knight Drama 2008-07-16 152 8.02
The Godfather Drama 1972-03-15 175 8.23
Batman Begins Drama 2005-06-14 140 7.29
The Shawshank Redemption Drama 1994-09-10 142 8.30
Alien Horror 1979-05-25 117 7.51
Terminator Salvation Drama 2009-05-20 115 5.81
Fight Club Drama 1999-10-14 139 8.03
Titanic Drama 1997-11-18 194 7.22
The Matrix Adventure 1999-03-30 136 7.72
Pulp Fiction Thriller 1994-10-14 154 8.01
Ice Age: The Meltdown Adventure 2006-03-23 91 6.40
Iron Man Adventure 2008-04-30 126 7.20
There are no records to display

Multiple Sort

Column Order

Filter builder

  • «
  • 1
  • 2
  • ...
  • 10
  • »

About this demo

This demo application contains 100+ pages and illustrates most of features provided by PHP Generator. Hope it will help you to create even more powerful websites for your users.

You can download the demo project from our website and run the demo on your webserver as described in readme.txt.

Download PHP Generator Free Trial

Legend
New Recently added or significantly updated pages.
Pro Pages illustrating features available only in the Professional edition of PHP Generator.

© 2002- SQL Maestro Group. Follow us:

Created with PHP Generator for MySQL. Want to learn more? Download the demo project!

Change your password

Change password for user ''

Passwords do not match. Please try again.

Close Change password