Jump to content

rwslippey

New Members
  • Posts

    6
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

rwslippey's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Hello all... Appologies on the subject line.. really couldn't come up with an idea their. I'm stuck in a rut here on this... Basicly I am trying to write some code to track our volunteer fire company's member response (tracked for informational perposes as well as some regulatory reasons)... I created a database with all of out members... each member has an assosiated member number which is currently used in the db and in our current tracking system (papper, pen, 6 hours of manually modifying an excel sheet on a monthly basis)... What I am trying to do is query the DB and dump out the entire table of members.. (that was easy) What I want to do is display the member's name (currently stored as a variable $name) in an organized fashion...with a check box next to the name soemthing like this (cb=checkbox) CB Member name CB Member Name CB Member name CB Member name CB Member Name CB Member Name CB Member name CB Member name and so on down the page.. what I'm getting now is a list one on each line witht the check boxes... I have tryed a table to no avail.... I know how to code these into html the way I want but that would require changing my php code every time we add or remove a member from our roster....(trying to avoid that by having the code pull this info out of the db... Thanks for all the help in advance... Here's what I currently have coded so far (for this section) while($row = mysql_fetch_array( $result )) { $f_name=$row['f_name']; $l_name=$row['l_name']; $number=$row['number']; $name="$f_name $l_name"; $value="$l_name$number"; echo "<input type=checkbox name=$name value=$value />";echo $name; } ?> I want to use the valuie (name and number combinded to query the db later to add their presence to the DB)... Thanks again Rob
  2. Okay, found the problem.... The query you sent me worked in phpmyadmin so I got into looking at the code... My add stored the record id in a variable... and then deleted duplicates... so the second record was never displayed (some idiot made the two tables with the same record id's go figure... that'd be me) thanks for your help
  3. Okay, got it to return a result however it's still returning just one... like I said earlier I think it's in the php code....
  4. yes that is correct. Sorry about that... I said two databases
  5. Iv been trying to use something like select * From tbl1,tbl2 where tbl1.field LIKE $search OR tbl2.field LIKE $search I think the problem is in the PHP and what it is displaying. I need it to display the results from either table... so If it gets results from either table is displays results from both tables.. and if it gets multiple results from either table it'll display them also... basicly a keyword search I guess is the way to explain it...
  6. Okay first is first I appreciate any help that is given. I've really torn my hair out over this one. I have two databases with the same exact structure, however different data. They can not be linked as the data in one table does not relate at all to the other table. I need to be able to search table1 then table 2 and be able to echo any results that come back from either table. hope someone can help. I have all of the search scrips written to search and search one table fine, just teaching a new trick isn't working. again thanks for the help.
×
×
  • 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.