Results 1 to 2 of 2

Thread: Hyperlink to a record based on the master record's ID
      
   

  1. #1
    sieg is offline Private
    Join Date
    Dec 2006
    Posts
    2

    Default Hyperlink to a record based on the master record's ID

    Hello,

    Here I have this website which is keeping contracts and invoices on a MySQL database.
    Now, I have a page where the contracts are listed and another one where invoices are listed.

    When I'm adding a new invoice I have a dropdown where client_name, contract_number and contract_date are concatenated so I can select the corresponding contract to add the invoice to.

    My issue is:
    on the contracts list page, I added a link to each contract, "View invoice" which is suppose to display the corresponding invoice.
    Can somebody help by telling me how should I format the hyperlink so the correct invoice opens?
    Right now I tried with "http://whatever.com/invoice_view.php?id=client" - where client is the name of the field from invoice where those three values above are concatenated - but it returns a view table without any values on it.

    Thanks a lot!

    Cheers!

    Sieg

  2. #2
    navaldesign's Avatar
    navaldesign is offline General & Forum Moderator
    Join Date
    Oct 2005
    Location
    Italy
    Posts
    12,115

    Default Re: Hyperlink to a record based on the master record's ID

    Depends on how the script looks for the client. If, f.e. your "invoice_view" pages searches the invoices based on the client ID, and your client id is represented in the php script as $client_id , your link should be http://whatever.com/invoice_view.php?id=$client_id . Have a look at www.navaldesign.info/therapy2/search.php Click on "Search Now" whithout selecting anything from the dropdowns (so that all results are displayed) then click on view. I beleive that is excactly what you are after. of course, much depends on your DB structure, which i don't know.
    Navaldesign
    Logger Lite: Low Cost, Customizable, multifeatured Login script
    Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
    DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
    Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!


Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49