houssam_ballout Posted September 7, 2007 Share Posted September 7, 2007 hello all,I'd 1 drop-down , the customer name and the second is telephone noI want to make, when I change the Customer name by selecting it from the menu, I want the tel. no to be updated for thatThanks in advance Link to comment Share on other sites More sharing options...
boen_robot Posted September 7, 2007 Share Posted September 7, 2007 Exactly where do you keep the phones for each person? A database (and what database exactly)? XML file? Text file? Hardcoded in the PHP? Sample of such storage's model? Link to comment Share on other sites More sharing options...
houssam_ballout Posted September 7, 2007 Author Share Posted September 7, 2007 Exactly where do you keep the phones for each person? A database (and what database exactly)? XML file? Text file? Hardcoded in the PHP? Sample of such storage's model?Well, I am giving the user the ability to add phone and Name to the database so when he/she selects the name he should get the phone no Link to comment Share on other sites More sharing options...
boen_robot Posted September 7, 2007 Share Posted September 7, 2007 Well, I am giving the user the ability to add phone and Name to the database so when he/she selects the name he should get the phone noAny code you already have for that? If you've been able to pull off additions to the database, selecting existing records should be a piece of cake. And again, what is your data model (the actual structure of the database).Just don't tell me you don't have one, please. I mean, if we have to do the addion of phones and database creation too, you're practically starting to ask for a whole application. Link to comment Share on other sites More sharing options...
houssam_ballout Posted September 7, 2007 Author Share Posted September 7, 2007 Any code you already have for that? If you've been able to pull off additions to the database, selecting existing records should be a piece of cake. And again, what is your data model (the actual structure of the database).yeah I do know that, but I just need some help to achieve that how to make the phone number visible when selecting the customer name Link to comment Share on other sites More sharing options...
boen_robot Posted September 7, 2007 Share Posted September 7, 2007 yeah I do know that, but I just need some help to achieve that how to make the phone number visible when selecting the customer nameSimply submit the form and perform a query that selects all phones from your phone table where the name is the same as the submitted one (it almost sounded like the actual query you need... heh).If you mean you don't want to submit the form, and get the phone without a page refresh, read on AJAX with PHP and databases. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.