Re: PHP and MySQL question

by "Darrell King" <darrell(at)webctr.com>

 Date:  Mon, 4 Aug 2003 14:19:44 -0400
 To:  "Susan Friesen" <susanfriesen(at)telus.net>,
<hwg-techniques(at)hwg.org>
 References:  telus
  todo: View Thread, Original
A "row" isn't a "column", though.  Each row in the table is a set of
"columns", or fields, and constitutes a "record".

To add a new row, you can use the INSERT query via the provided textarea on
the database main page or you can look for an insert link in the table
display or in the right frame's home page next to the appropriate table in
the list.

To add a new field to a table, you can click to the table's detail display
(click on the table name) and look for the "Add new field" form below the
table printout.  Of course, you can also use the textarea on the database
main page and use the ALTER TABLE query, too.

To make radio buttons coordination, you must name them so they are part of a
set (they have the same name):

<.input type="radio" name="publish" value="yes">Publish
<.input type="radio" name="publish" value="no">Don't Publish

Then, you look for the value of $_POST['publish'] (or just $publish if you
have automatic globals on) and see if it holds "yes" or "no".




----- Original Message -----
From: "Susan Friesen" <susanfriesen(at)telus.net>



Hi folks,
Is there anyone out there using phpMyAdmin 2.3.0 that can show me how to
enter a new row into a table? I've inherited this software and I don't have
any experience with it. I know SQL at a beginner's level, so figured I could
easily add in a new row! (Technically, it's adding in a new column to the
table, but phpMyAdmin seems to call it a row?)

>From the "Structure" page, I assume I click on the "Insert" button? But
where do I go from there? Any kind helpers out there?


Also, I am modifying the PHP generated input form and I can't figure out how
to do radio buttons. This form is to allow us to view all the information
that was originally inputted, so we can edit the information if need be.
This is what I've got:

<.input type="radio" name="publish_yes" value="<?=$publish_yes?>">Publish
<.input type="radio" name="publish_no" value="<?=$publish_no?>">Don't
Publish

But the two options are not "one or the other", I can click on both and each
value will show as "on". What do I have to change here?

HWG hwg-techniques mailing list archives, maintained by Webmasters @ IWA

This page is part of a preserved archive of archives.hwg.org. The site is no longer active and its content is not maintained. For enquiries about this archive, write to archive(at)iwanet.org.