Jump to content

Recommended Posts

Guys,

1. I am creating a "Service Call Register" Form which Customer Info as well as "Problem Reported Details".
2. I have maintained Customer Info in "Customer Master" Table.
3. In the Form I have provided a Combo Box to fill in Customer Name,
4. Combo Box Values are populated from Customer Master Table.

Unitll here every thing works fine.
My next step is - The moment user selects a customer in Combo Box,
The same form should fetch and display Customer Address, Phone Numbers and Contact Person.
And the user continues entering "Problem Reported Details".

Is it possible to do in PHP.
If Yes, Please tell me how.

P.l.e.a.s.e
Regards
Beethoven.
Link to comment
https://forums.phpfreaks.com/topic/10107-form-element-event-trigger/
Share on other sites

Dear Barand and Crayon

My Special Thanks to you both....
Barand I implemented the concept you have suggested and also used the xmlhttp.js file.
Barand, "Service Call Registration" is the first application I have worked on using PHP I am so much eager to show this application to you. I am very happy, it worked the way I wanted, Moreover it is extreemly fast.

I wont be able to thank you both enough.
Thanks again.

Regards,
Beethoven.
Hello,
make one form for the combobox alone(you can still leave the rest of the form there, we just change the target and move the </form> tag later), assign a javascript onchange event to it to
submit the form once the customer has been choosen (I guess the value of the combobox options will be some kind of customer unique id = uid).
That form will point to itself basically, except that it now knows the uid of the previously choosen
customer.

In the form you have to do an if/else statement checking if the uid is there.
if it is it will change the forms target and not set the </form> for the previous "little" form that only choose the customer.
It also does not display the combobox anymore, but rather does a quick query to your Db to get the full customer details and displays them nicely formatted.

Good luck.
Andi
This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.