[set page_title]Preview[/set] [set ui_checklist]1[/set] [set help_name]wizard.preview[/set] @_UI_STD_HEAD_@
To preview your site, click Finish. The following will occur:
In order to launch, you must have a secure (SSL) connection and a payment gateway enabled.
[perl tables="transactions products"] my $pdb = $Db{products}; my $tdb = $Db{transactions}; my $pcount = $pdb->query( { sql => 'select * from products', row_count => 1, } ); my $tcount = $tdb->query( { sql => 'select * from transactions', row_count => 1, } ); delete $Scratch->{pmessage}; delete $Scratch->{pdefault}; if($pcount > 0) { $Scratch->{pmessage} = "$pcount products currently in the database - select Yes to add/replace products"; $Values->{sampleproducts} = $Scratch->{pdefault} = ''; $Scratch->{pwidget} = "yesno"; } else { $Scratch->{pmessage} = "No products currently in the database - select No to add no products"; $Scratch->{pwidget} = "hidden"; $Values->{sampleproducts} = $Scratch->{pdefault} = '1'; } delete $Scratch->{tmessage}; delete $Scratch->{tdefault}; if($tcount > 0) { $Scratch->{tmessage} = "$tcount orders currently in the database - select Yes to add/replace orders"; $Values->{sampleorders} = $Scratch->{tdefault} = ''; } else { $Scratch->{tmessage} = "No orders currently in the database - select No to leave blank"; $Values->{sampleorders} = $Scratch->{tdefault} = ''; } return; [/perl] [set write_flag] [flag type=write table="variable"] [flag type=write table="pricing"] [flag type=write table="products"] [/set] [comment] When we get Postgres better figured out, we can put this back in for it. Until then, MySQL and DBM only. [/comment] [if variable PGSQL] [tmp the_fields]sampleproducts buildcat enablesecure[/tmp] [else] [tmp the_fields]sampleproducts buildcat sampleorders enablesecure[/tmp] [/else] [/if] [table-editor table=variable left_width=120 table_width=500 wizard=1 defaults=1 bottom_buttons=1 next_text=Finish no_top=1 no_bottom=1 row_template="[scratch row_template]" mv_nextpage="[either][cgi ui_nextpage][or]__UI_BASE__/wizard/do_save[/either]" mv_prevpage="[either][cgi ui_prevpage][or]__UI_BASE__/wizard/step_products[/either]" hidden.ui_return_to="__UI_BASE__/wizard/index" hidden.mv_click="write_flag" hidden.mv_check=profile_save_values ui_data_key=code default.code="[value code]" widget.code=text_10 ui_data_fields="code [scratch the_fields]" ui_display_only="[scratch the_fields]" ui_hide_key=1 label.sampleorders="Insert sample order data" help.sampleorders=`$Scratch->{tmessage}` widget.sampleorders=yesno label.buildcat="Rebuild category lists" widget.buildcat=select passed.buildcat="Yes, No" label.sampleproducts="Insert products data" help.sampleproducts=`$Scratch->{pmessage}` widget.sampleproducts=`$Scratch->{pwidget}` label.enablesecure="Enable Secure (SSL)" help.enablesecure="Select Yes if your Stronghold secure server is set up" widget.enablesecure=yesno ] @_UI_STD_FOOTER_@