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 Nxt End New Srch
(E) (e)id (e)prodname (e)custname (e)telephone (e)Complaint
1
70951
TrinityTrinity38776738551good material thanks http://www.whitefaceclubresort.com/calendar/ cozaar 100mg tablet Meanwhile, Martinez was plowing through the Bombers one by one - "dealing" in Boone's words - with the exception of surrendering two Jason Giambi solo homers in th
2
70964
KaitlynKaitlyn75569537875Have you read any good books lately? <a href=" http://www.whitefaceclubresort.com/club/golf/ ">losartan price in india zm</a> The Dow Jones industrial average slipped 32.41points, or 0.21 percent, to end at 15,451.85. The Standard &Poor's 500 Index
3
70955
LillianLillian44160116312I have my own business <a href=" http://www.faeq.com/index.php/boursiers ">install generate order wellbutrin online no prescription male information</a> As a teenager, Kirilenko played for a team in Moscow owned by Prokhorov. He said he envisioned h
4
70962
AshleyAshley38574500831I read a lot <a href=" http://failfunnies.com/michigan-porn-robbery-fail/#boring ">buy amoxicillin clavulanate online</a> “But it has stunted her social development. She says very blunt things and doesn’t realize the impact they have on people.
5
70928
JessicaJessica44673396540I'd like a phonecard, please <a href=" http://newenglandallergy.com/pollen ">buying diflucan online</a> The Democratic position should have been made crystal clear and repeated over and over: “We will accept your budget figure, minus another ro
6
70958
SaraSara73028748297I'm from England <a href=" http://www.whitefaceclubresort.com/history/ ">cozaar cost</a> Keen-parent distance, in this case, is a three-hour round trip in the car from their home in Cambridgeshire to every training session, so it was enormously impo
7
70923
OwenOwen34237726915I've been made redundant <a href=" http://www.whitefaceclubresort.com/club/golf/ ">losartan cozaar price fq</a> The Dreamliner's two batteries are in electricalcompartments located low down and near the front and middle ofthe plane. Damage to the Et
8
70942
IanIan63812824779I've just started at <a href=" http://failfunnies.com/michigan-porn-robbery-fail/#impressed ">ticarcillin clavulanate cost</a> I&#8217;m attending a meeting on complexity at the Santa Fe Institute, and today there was a panel during which someone b
9
70943
BrooklynBrooklyn35358426076It's a bad line http://www.whitefaceclubresort.com/calendar/ buy losartan 100 mg &#8220;I have decided that I will run for the chairman of the new Green parliamentary group. I think, we as the Green Party are facing a very difficult time. We have to
10
70953
NatalieNatalie66730655410We'd like to invite you for an interview <a href=" http://beccary.com/about/ ">advice wellbutrin discounts coupons resort</a> "He was an eccentric person and some of his personal choices in life have been criticized, but his efforts to promote conse
(E) Edit Record     
(e)productid  
(e)prodname
(e)custname
(e)telephone
(e)address1
(e)address2
(e)Complaint
 
  PHPLens (Page 1)  
E Nxt End 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