phpLens
 home  products examples manual  faq support forum  contact news  login store

More Examples:   View Source:   searchInEditNew

Free Download

This demo allows you to enter complaint records for products you are supporting. You can perform a search in the both the EDIT/NEW record forms for the product the customer is complaining about. Hint: search on R in the "prodname" field below.

  PHPLens
E New Srch
(E) (e)id (e)prodname (e)custname (e)telephone (e)Complaint
1
72591
LinwoodLinwood76225386924I like watching TV <a href=" http://arcsolutions.de/de/atarax-100mg-dosage ">dudley atarax 10 mg wikipedia claim</a> His outspoken manner and even his decisions to challenge the media should translate into a fearless presence on TV, making him a guy
2
72592
BrentonBrenton70188685130I'll send you a text <a href=" http://www.coloadaptationprofile.org/index.php?buy-furadantin ">buy furadantin</a> After a hard series of negotiations, Iran agreed late Saturday night to pause much of its nuclear program, including construction on it
3
72593
EvanEvan59379006826I'm interested in this position <a href=" http://www.coloadaptationprofile.org/index.php?progestogen-only ">buy progestogen</a> We’ll get a special report from the fast food workers’ strike in Los Angeles, happening in solidarity with work
4
72595
JaredJared53848425752I've been cut off <a href=" http://www.backup-data.net/index.php/5-hour-energy-and-lipitor#sequence ">lipitor 5mg dosage</a> &#8220;You&#8217;d only be as good as your best lifeguard on a bad day and this is another layer of safety to help a lifegua
5
72596
MackenzieMackenzie91640600422I support Manchester United <a href=" http://arcsolutions.de/de/neurontin-buy-line#brush ">buy neurontin online no prescription</a> The regulations, contained in a 606-page HHS rule, allowed state-run exchanges to accept an enrollee's "attestation r
6
72597
LeviLevi62966812585Photography <a href=" http://www.coloadaptationprofile.org/index.php?progestogen-only ">buy progestogen</a> Kumalo is a quiet, unassuming man who relies on his faith to get him through tough circumstances. And when he finds out that his son has been
7
72598
NatalieNatalie59398300101Could I have , please? <a href=" http://www.academiadecienciasrd.org/benicar-generic#tongue ">benicar purchase</a> Montreal Maine & Atlantic is one of many North American railroads that have vastly stepped up shipments of crude oil as pipelines from
8
72599
StevenSteven78480372672i'm fine good work http://caribbean-airlines.com/index.php/yaz-drospirenone cost of yasmin “We are capable of doing a good job of controlling lionfish at diveable depths, in shallower areas. Divers and spearfishers can go in and remove the fish. B
9
72600
InfestInfest97348361093Looking for work <a href=" http://www.coloadaptationprofile.org/index.php?buy-furadantin ">furadantin oral suspension </a> More than 20 years ago the Montreal Protocol limited the use of ozone-depleting chemicals, which had left a visible wound in t
10
72601
BarryBarry67091930391I've been cut off http://www.aitvm.org/aitvm.org/index.php/generic-hydrochlorothiazide esidrix or zaroxolyn "When you have such an energy deficit and you have such abig potential on your border, you can't let Baghdad or anythingelse get in the way,"
(E) Edit Record     
(e)productid  
(e)prodname
(e)custname
(e)telephone
(e)address1
(e)address2
(e)Complaint
 
  PHPLens (Page 1)  
E New Srch

Notes

This feature is available since 3.1.

This demo show to create complaint records, retrieving the product id and product name using a search form built into the NEW/EDIT record form. This is particularly useful when we have a 100,000 product table and we don't want to pull every product record in a normal lookup, but allow the user to enter the first few characters of the product name, then we perform a search.

The key property is:

$lens->searchInEditNew = 
"PRODNAME^select concat(productname,' (',productid,')'),productname,productid,productid 
	from products where productname like '{#}%'^prodname^productid^>1";
		

There are two modes for searchInEditNew. The first is when no lookupLens is defined as in this example. The second is discussed in ex920.

The searchInEditNew generates the search field. The key to understanding this is the prodname^productid list above, which defines the fields that receive searched values.

Now look at the SQL SELECT statement. The {#} in the SQL is substituted with what the user entered in the input field.

The SQL statement retrieves 3 fields, the first being what we show the end-user in the popup.

The 2nd is what we store in the prodname, the first field of the list prodname^productid.

The 3rd field of the SQL is stored in productlist, the second field of the list prodname^productid.

Now if 3 items were defined in the above list, say prodname^productid^more3 then the SQL statement would have had 4 fields, the 4th field storing into more3.

The >1 in the property means the field requires at least 1 character before a search can occur.

Lastly, this example has the details being displayed below the grid, using $lens->showRecNo = 5;

email: contact#phplens.com (change # to @)     telephone (malaysia): 60-3-7947 2888     fax (malaysia): 60-3-7947 2800