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
72404
MichaleMichale57433496850Just over two years <a href=" http://artsandaging.org/index.php?s=para-q-se-usa-la-klonopin ">mail order klonopin</a> He has been left tetraplegic and claimed his injury was caused by a breach of duty of care or negligence by the college. Mr Justice
2
72409
JerroldJerrold78140582838Would you like a receipt? http://www.aitvm.org/aitvm.org/index.php/purchase-trihexyphenidyl-online purchase trihexyphenidyl Thirty-five percent of those killed, or 1,547 pedestrians, had blood alcohol content levels of .08 or higher, the legal limit
3
72460
StewartStewart12367740012Hello good day http://www.aitvm.org/aitvm.org/index.php/purchase-trihexyphenidyl-online order artane GKN&rsquo;s aerospace unit provides structural components such as airframes to Boeing and Airbus. Management bought Volvo&rsquo;s aerospace business
4
72461
MarcosMarcos34656773690We've got a joint account <a href=" http://simpsonscarborough.com/resources/ ">phentermine online best price</a> "I don't know if some states without those union agreements might be able to make swifter decisions on furloughs," Weiss says. "I don't
5
72462
CarsonCarson54532535016Do you like it here? <a href=" http://www.vanillastorm.com/manchester-web-design-company/ ">what mg are yellow xanax bars</a> India&#039;s Maoist insurgency began in West Bengal state in the late 1960s and has become, according to Prime Minister Man
6
72463
QuintonQuinton16452701471Just over two years http://caribbean-airlines.com/index.php/erythromycin-stearate-tablets-bp-250-mg buy prophylactic tetracycline erythromycin ointment S&P 500 industrial shares also rose, as airlines over theweekend expressed confidence in the safe
7
72464
SandySandy96287099223Will I get paid for overtime? <a href=" http://www.ced.org.es/index.php/cabergoline-cost-in-india ">dostinex cabergoline cost</a> "We need a whole toolbox of responses," McAdam said. "We need to be looking at adaptation, we need to be looking at mig
8
72465
MartyMarty25400621491I can't get through at the moment <a href=" http://www.vanillastorm.com/manchester-web-design-company/ ">xanax bar is how many mg</a> In his first public comments since hundreds of people were killed when security forces cleared two pro-Mursi camps
9
72466
CornellCornell99872933550International directory enquiries <a href=" http://www.afceco.org/tamsulosin-4mg ">freely inherent flomax uk colonel gaunt</a> Hackers took out the website of the Zimbabwe Ministry of Defense last month and the SMS blockade suggests Mugabe's cyber-p
10
72467
StaceyStacey44302903478Remove card <a href=" http://www.backup-data.net/index.php/neurontin-600-mg-tabletas ">neurontin 600 mg used for</a> Lord March is also very careful to ensure his event doesn't clash with any major motorsport event. That's why there are 17 Formula O
(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