Example from W3 Schools php and Ajax - should be simple!

Ask about general coding issues or problems here.

Moderators: macek, egami, gesf

lister
New php-forum User
New php-forum User
Posts: 21
Joined: Mon May 16, 2011 8:18 am

Example from W3 Schools php and Ajax - should be simple!

Postby lister » Fri Aug 09, 2013 6:23 pm

Hi - I can't figure this out...(im still new to php and ajax...)

Anyway - this demo is exactly what I am trying to achieve - but - the demo is to find ONE user - I want to find and display several users with a similar ID...

So in the example you can search for Peter Griffin and it shows just him, whereas Id like to search for 'Peter' and for ALL the 'Peters' to be displayed...

Im sure this is simple but I can't figure it out. I thought it would be the option - value parameter but alas, it's not...

Any help greatly appreciated!

http://www.w3schools.com/php/php_ajax_database.asp

johnj
php-forum Super User
php-forum Super User
Posts: 1805
Joined: Thu Mar 10, 2011 5:07 pm

Re: Example from W3 Schools php and Ajax - should be simple!

Postby johnj » Fri Aug 09, 2013 8:41 pm

you have use a different sql for that....something like this....select * from user where firstname LIKE '%peter'. This will fetch all "Peters".


Return to “PHP coding => General”

Who is online

Users browsing this forum: Bing [Bot] and 1 guest