Peter D Bethke Best way to pass error from lib to screen
Feb 24, 2014; 13:42
Peter D Bethke
Best way to pass error from lib to screen
Hello all,
I loaded the knop demo for 9 without adding the data source for the sample db and got a lasso error that I traced to a single line in /_library/lib_customer_list.inc:
// get list of records $d -> select($searchparams);
I=92m assuming that the knop_database object is kacking on selecting from a database that=92s not been initialized - but it did sort of mess with the shiny out of the box experience of knop running even if the database was not initialized.
Is there a method in knop_database that will let me check for connectivity before running the select method, and then if it returns no connectivity is there an error object that I can then pass a message to the index page warning users to add the datasource?
Something like:
if ($d->available);
$d -> select($searchparams);=09
else;
$error->(add: =91Error: You need to RTFM and add the database first to run the demo properly);
/if;
Then, maybe in the html body:
if: $error->haserrors;
$error->render;
else;
=85. knop list code here ...
/if;
Peter -- ############################################################# This message is sent to you because you are subscribed to the mailing list <knop@lists.montania.se>. To unsubscribe, E-mail to: <knop-off@lists.montania.se> Send administrative queries to <knop-request@lists.montania.se> List archive http://lasso.2283332.n4.nabble.com/Knop-Framework-Discussion-f3157831.html The Knop project and code is hosted at GitHub. https://github.com/knop-project/knop
Feb 24
Steve Piercy - Web Site Builder Re: Best way to pass error from lib to screen
Feb 24, 2014; 13:00
Steve Piercy - Web Site Builder
Re: Best way to pass error from lib to screen
Mar 01
Johan Solve Re: Best way to pass error from lib to screen
Mar 01, 2014; 16:58
Johan Solve
Re: Best way to pass error from lib to screen
Search
Lasso Programming
This site manages and broadcasts several email lists pertaining to Lasso Programming and technologies related and used by Lasso developers. Sign up today!