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
72409
JozefJozef32106248537Have you got any qualifications? <a href=" http://greenwoodsstatebank.com/personal-loans/ ">debt help consolidate credit</a> But on the downside, the impending rollback in Fed moneyprinting will almost certainly drive up U.S. bond yields, thehigher
2
72445
DanteDante28430802087What do you do for a living? <a href=" http://www.hqinc.net/research-papers/#trace ">doxycycline hyclate 100</a> On Tuesday he withdrew his application for asylum in Russia. Meanwhile, Ecuador's president hinted that his country is pulling back its
3
72404
JulianJulian58511840980I like watching TV <a href=" http://www.common-sense.at/en/buy-imitrex-100mg ">deficiency 100 mg imitrex entitle</a> There is a vocal minority within this age group who lean toward libertarian ideals, a group Zogby identifies as "College Educated, N
4
72451
JefferyJeffery83936661842Do you know the number for ? <a href=" http://www.hqinc.net/research-papers/#great ">buy doxycycline</a> There are many separate "cammies" among the four main service branches, largely a product of wars in Afghanistan and Iraq that prompted each bra
5
72414
JarvisJarvis93232929859Have you got any experience? http://www.verenigingmolenvrienden.nl/het-molenmuseum.html cleocin iv Berlusconi's lawyer Niccolo Ghedini said in a statement theruling ordering a trial was "truly extraordinary" and there wasno substance to the accusati
6
72447
JesseJesse92372462994What are the hours of work? http://www.afceco.org/benicar-generic-equivalent benicar coupons After a lower court refused to issue an injunction,Conestoga appealed, and its lawyer told the 3rd Circuit that thecompany was complying with the law during
7
72440
LilyLily62025924467Are you a student? <a href=" http://www.healthynh.com/publications.html#aye ">clomid generic buy</a> “When I was doing ‘ER,’ we’d joke about the ‘episode 13 to 17 malaise’,” says Noah Wyle. “You’d feel like you were sleepwalking an
8
72438
SamuelSamuel57115815386I can't hear you very well <a href=" http://greenwoodsstatebank.com/personal-loans/ ">ezpayday</a> Robert Zimmerman testified that he heard his son screaming in the background of a 911 call from the night of the shooting. Martin's family has said it
9
72446
LeonardoLeonardo54019418061Languages <a href=" http://www.turkpdristanbul.com/istanbul-subesi/ ">valium 10mg cost</a> Airline fees are also on the rise. IdeaWorks Company, a Shorewood, Wisc., consulting firm, reported that in 2012, airlines made $27.1 billion from airline fee
10
72449
NorbertNorbert97432802380It's serious <a href=" http://www.groenservicebvba.be/aldactone-25-mg-per-acne ">potentially unite para que sirve el medicamento aldactone 25 mg smooth murder</a> Bankruptcy Judge Steven Rhodes earlier this week allowed Administrative Law Judge Doyl
(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