1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Winfield, BC, Canada
    Rep Power
    In a table in which there is more than one primary key (using php3):...

    I want to create a php script that displays say (for the purpose of adding to database):
    Customer Id # (as a select)
    Email (as a select)
    two other fields

    a customer may have more than 1 email, but each email is unique as is the customer id #

    i know how to populate the customer id # from the database but is there a way (without creating a new script and passing it customer id # (storing it as hidden in the next scripts form, and then limit the emails listed)) to disable the email select until the customer id # has been selected (which then populates the email select and enables it)

    in other words is there a way to do this in 1 script?
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2000
    Ontario, Canada
    Rep Power
    You'll have to look into Javascript to accomplish that. The Javascript works client-side, so you could create a script to make the E-Mail field become active when you select a customer ID... The most I do with JS is cheap AM/PM clocks and fancy image mouseover/out stuff, so I'd suggest you take a visit over to the DevShed Javascript forum.

    To alcohol! The cause of, and solution to, all of life's problems. -- Homer Simpson

Similar Threads

  1. Do I need to select a field in a SELECT statement?
    By assemblage in forum MySQL Help
    Replies: 7
    Last Post: February 12th, 2004, 08:34 PM
  2. Wan to select partial text in a text field
    By raghava66 in forum HTML Programming
    Replies: 2
    Last Post: February 12th, 2004, 02:11 AM
  3. select distinct with more than 1 field
    By hoagnes in forum MySQL Help
    Replies: 13
    Last Post: January 30th, 2004, 12:43 PM
  4. html form problem using mult select and file field
    By Justin_M in forum HTML Programming
    Replies: 4
    Last Post: January 5th, 2004, 07:13 PM
  5. tell me how to select first char from a field
    By hasitha in forum PHP Development
    Replies: 3
    Last Post: December 24th, 2003, 02:48 AM

IMN logo majestic logo threadwatch logo seochat tools logo