Mysql and Textarea (Please help me figure out this problem. I' m stuck. Please help me!!! )

--0-2025112038-1179868410=:66062
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit

I'm just a php beginner.
So please be patient with my stupid questions.

What am I missing in this code that causing the function can’t update the textarea?

Update button erase the old information from mysql database and replace it with nothing. Basically it can’t read what is inside the Textarea box. Why??

Read the highlighted code.

<?php
include ('./includes/header.html');
include( '../mysql_connect.php' );
?>
</HEAD>
<BODY>
<TABLE ALIGN="center" BORDER="0" CELLSPACING="0" CELLPADDING="0">
<TR ALIGN="center" VALIGN="middle">
<TH ALIGN="center"><FONT SIZE="6" COLOR ="#310032">View
Existing Data</FONT></TH>
</TR>
</TABLE>
<FORM METHOD="post" ACTION="ved.php">
<?php
$query = "SELECT DISTINCT Assign_Engineer FROM lo_data";
$result = mysql_query($query);
?>
<BR /><BR />
<CENTER>
<SELECT NAME="R"><OPTION VALUE="NULL">Choose a Category:</OPTION>
<?php
while ($line = mysql_fetch_array($result))
{
foreach ($line as $value)
{
echo"<OPTION VALUE='$value'";
}
echo ">$value</OPTION>";
}
?>
</SELECT>
<INPUT TYPE="submit" NAME="Submit" VALUE="Submit Data"><BR /><BR
/>
<?php
if (isset($_REQUEST['save_assign_engineer'])) {
$id = (int) $_REQUEST['save_assign_engineer'];
$job_title =
mysql_real_escape_string($_REQUEST['Assign_Engineer'][' .$id . ']['Job_Title']);
$sql = "
UPDATE `lo_data`
SET `Job_Title` = '" . $job_title . "'
WHERE `ID` = " . $id;
mysql_query($sql);
}
if (isset($_POST["R"])) {
$result = mysql_query("SELECT * FROM lo_data WHERE Assign_Engineer ='".$_POST["R"]."'");
}
?>
<DIV STYLE="overflow:auto;">
<TABLE WIDTH="80" BORDER="1" CELLSPACING="1" CELLPADDING="3"
BORDERCOLOR="CDCB98">
<THEAD>
<TR STYLE="position: relative; top:
expression(this.offsetParent.scrollTop); background-color: #CDCB98;">
<TH>ID</TH>
<TH>Reference No</TH>
<TH>Job Descriptions</TH>
<TH>Category</TH>
<TH>Assign Engineer</TH>
<TH>Date Received</TH>
<TH>Date Required</TH>
<TH>Date Assigned</TH>
<TH>Projected Completion Date</TH>
<TH>Date Completed</TH>
<TH>Manhour Spent</TH>
<TH>Status</TH>
</TR>
</THEAD>
<?php
$num=mysql_num_rows($result);
echo $num;
while($row = mysql_fetch_array($result))
{
echo "<TBODY>";
echo "<TR VALIGN=\"TOP\" ALIGN=\"CENTER\">";
echo "<TD>{$row['ID']}</TD>";
echo "<TD>{$row['Ref_No']}</TD>";
echo '<TD> <P><TEXTAREA NAME="Assign_Engineer[' . $row['ID'] . '][Job_Title]" ROWS="10"
COLS="40">'.$row['Job_Title'] .'</TEXTAREA>';
echo " <BR />";
echo '<button type="submit" name="save_assign_engineer" value="' .
$row['ID'] . '" />Updaet data</button>
';
echo "<TD>{$row['Category']}</TD>";
echo "<TD>{$row['Assign_Engineer']}</TD>";
echo "<TD>{$row['Date_Received']}</TD>";
echo "<TD>{$row['Date_Required']}</TD>";
echo "<TD>{$row['Date_Assigned']}</TD>";
echo "<TD>{$row['ProjectedCompletionDate']}</TD>";
echo "<TD>{$row['Date_Completed']}</TD>";
echo "<TD>{$row['ManhourSpent']}</TD>";
echo "<TD>{$row['Status']}</TD>";
echo "</TR>";
echo"</TBODY>";
}
?>






---------------------------------
Sick sense of humor? Visit Yahoo! TV's Comedy with an Edge to see what's on, when.
--0-2025112038-1179868410=:66062--
sam rumaizan [ Di, 22 Mai 2007 23:13 ] [ ID #1718836 ]

Re: Mysql and Textarea (Please help me figure out this problem. I' m stuck. Please help me!!! )

use $_POST[your var] in this script..
not simple but worked..

other option

$_HTTP_POST_VARS[your var]


----- Original Message -----
From: "sam rumaizan" <samcalc [at] yahoo.com>
To: <php-windows [at] lists.php.net>
Sent: Wednesday, May 23, 2007 4:13 AM
Subject: [PHP-WIN] Mysql and Textarea (Please help me figure out this
problem. I' m stuck. Please help me!!! )


> I'm just a php beginner.
> So please be patient with my stupid questions.
>
> What am I missing in this code that causing the function can't update
the textarea?
>
> Update button erase the old information from mysql database and replace
it with nothing. Basically it can't read what is inside the Textarea box.
Why??
>
> Read the highlighted code.
>
> <?php
> include ('./includes/header.html');
> include( '../mysql_connect.php' );
> ?>
> </HEAD>
> <BODY>
> <TABLE ALIGN="center" BORDER="0" CELLSPACING="0" CELLPADDING="0">
> <TR ALIGN="center" VALIGN="middle">
> <TH ALIGN="center"><FONT SIZE="6" COLOR ="#310032">View
> Existing Data</FONT></TH>
> </TR>
> </TABLE>
> <FORM METHOD="post" ACTION="ved.php">
> <?php
> $query = "SELECT DISTINCT Assign_Engineer FROM lo_data";
> $result = mysql_query($query);
> ?>
> <BR /><BR />
> <CENTER>
> <SELECT NAME="R"><OPTION VALUE="NULL">Choose a Category:</OPTION>
> <?php
> while ($line = mysql_fetch_array($result))
> {
> foreach ($line as $value)
> {
> echo"<OPTION VALUE='$value'";
> }
> echo ">$value</OPTION>";
> }
> ?>
> </SELECT>
> <INPUT TYPE="submit" NAME="Submit" VALUE="Submit Data"><BR /><BR
> />
> <?php
> if (isset($_REQUEST['save_assign_engineer'])) {
> $id = (int) $_REQUEST['save_assign_engineer'];
> $job_title =
> mysql_real_escape_string($_REQUEST['Assign_Engineer'][' .$id .
']['Job_Title']);
> $sql = "
> UPDATE `lo_data`
> SET `Job_Title` = '" . $job_title . "'
> WHERE `ID` = " . $id;
> mysql_query($sql);
> }
> if (isset($_POST["R"])) {
> $result = mysql_query("SELECT * FROM lo_data WHERE Assign_Engineer
='".$_POST["R"]."'");
> }
> ?>
> <DIV STYLE="overflow:auto;">
> <TABLE WIDTH="80" BORDER="1" CELLSPACING="1" CELLPADDING="3"
> BORDERCOLOR="CDCB98">
> <THEAD>
> <TR STYLE="position: relative; top:
> expression(this.offsetParent.scrollTop); background-color: #CDCB98;">
> <TH>ID</TH>
> <TH>Reference No</TH>
> <TH>Job Descriptions</TH>
> <TH>Category</TH>
> <TH>Assign Engineer</TH>
> <TH>Date Received</TH>
> <TH>Date Required</TH>
> <TH>Date Assigned</TH>
> <TH>Projected Completion Date</TH>
> <TH>Date Completed</TH>
> <TH>Manhour Spent</TH>
> <TH>Status</TH>
> </TR>
> </THEAD>
> <?php
> $num=mysql_num_rows($result);
> echo $num;
> while($row = mysql_fetch_array($result))
> {
> echo "<TBODY>";
> echo "<TR VALIGN=\"TOP\" ALIGN=\"CENTER\">";
> echo "<TD>{$row['ID']}</TD>";
> echo "<TD>{$row['Ref_No']}</TD>";
> echo '<TD> <P><TEXTAREA NAME="Assign_Engineer[' . $row['ID'] .
'][Job_Title]" ROWS="10"
> COLS="40">'.$row['Job_Title'] .'</TEXTAREA>';
> echo " <BR />";
> echo '<button type="submit" name="save_assign_engineer" value="' .
> $row['ID'] . '" />Updaet data</button>
> ';
> echo "<TD>{$row['Category']}</TD>";
> echo "<TD>{$row['Assign_Engineer']}</TD>";
> echo "<TD>{$row['Date_Received']}</TD>";
> echo "<TD>{$row['Date_Required']}</TD>";
> echo "<TD>{$row['Date_Assigned']}</TD>";
> echo "<TD>{$row['ProjectedCompletionDate']}</TD>";
> echo "<TD>{$row['Date_Completed']}</TD>";
> echo "<TD>{$row['ManhourSpent']}</TD>";
> echo "<TD>{$row['Status']}</TD>";
> echo "</TR>";
> echo"</TBODY>";
> }
> ?>
>
>
>
>
>
>
> ---------------------------------
> Sick sense of humor? Visit Yahoo! TV's Comedy with an Edge to see what's
on, when.

--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
bedul [ Mi, 23 Mai 2007 06:25 ] [ ID #1721248 ]

Re: Mysql and Textarea (Please help me figure out this problem. I' m stuck. Please help me!!! )

Looks like a problem in the definition of the TEXTAREA NAME.
The echo statement is started and ended with a '
While in the $row['ID'] also a quote is used. So the echo string looks not
correct.

Try: echo '<TD> <P><TEXTAREA NAME="Assign_Engineer[' . $row[\'ID\'] .
'][Job_Title]" ROWS="10"


""bedul"" <landavia81 [at] gmail.com> wrote in message
news:009c01c79cf2$7310ad80$670b1e0a [at] mis01...
> use $_POST[your var] in this script..
> not simple but worked..
>
> other option
>
> $_HTTP_POST_VARS[your var]
>
>
> ----- Original Message -----
> From: "sam rumaizan" <samcalc [at] yahoo.com>
> To: <php-windows [at] lists.php.net>
> Sent: Wednesday, May 23, 2007 4:13 AM
> Subject: [PHP-WIN] Mysql and Textarea (Please help me figure out this
> problem. I' m stuck. Please help me!!! )
>
>
>> I'm just a php beginner.
>> So please be patient with my stupid questions.
>>
>> What am I missing in this code that causing the function can't update
> the textarea?
>>
>> Update button erase the old information from mysql database and replace
> it with nothing. Basically it can't read what is inside the Textarea box.
> Why??
>>
>> Read the highlighted code.
>>
>> <?php
>> include ('./includes/header.html');
>> include( '../mysql_connect.php' );
>> ?>
>> </HEAD>
>> <BODY>
>> <TABLE ALIGN="center" BORDER="0" CELLSPACING="0" CELLPADDING="0">
>> <TR ALIGN="center" VALIGN="middle">
>> <TH ALIGN="center"><FONT SIZE="6" COLOR ="#310032">View
>> Existing Data</FONT></TH>
>> </TR>
>> </TABLE>
>> <FORM METHOD="post" ACTION="ved.php">
>> <?php
>> $query = "SELECT DISTINCT Assign_Engineer FROM lo_data";
>> $result = mysql_query($query);
>> ?>
>> <BR /><BR />
>> <CENTER>
>> <SELECT NAME="R"><OPTION VALUE="NULL">Choose a Category:</OPTION>
>> <?php
>> while ($line = mysql_fetch_array($result))
>> {
>> foreach ($line as $value)
>> {
>> echo"<OPTION VALUE='$value'";
>> }
>> echo ">$value</OPTION>";
>> }
>> ?>
>> </SELECT>
>> <INPUT TYPE="submit" NAME="Submit" VALUE="Submit Data"><BR /><BR
>> />
>> <?php
>> if (isset($_REQUEST['save_assign_engineer'])) {
>> $id = (int) $_REQUEST['save_assign_engineer'];
>> $job_title =
>> mysql_real_escape_string($_REQUEST['Assign_Engineer'][' .$id .
> ']['Job_Title']);
>> $sql = "
>> UPDATE `lo_data`
>> SET `Job_Title` = '" . $job_title . "'
>> WHERE `ID` = " . $id;
>> mysql_query($sql);
>> }
>> if (isset($_POST["R"])) {
>> $result = mysql_query("SELECT * FROM lo_data WHERE Assign_Engineer
> ='".$_POST["R"]."'");
>> }
>> ?>
>> <DIV STYLE="overflow:auto;">
>> <TABLE WIDTH="80" BORDER="1" CELLSPACING="1" CELLPADDING="3"
>> BORDERCOLOR="CDCB98">
>> <THEAD>
>> <TR STYLE="position: relative; top:
>> expression(this.offsetParent.scrollTop); background-color: #CDCB98;">
>> <TH>ID</TH>
>> <TH>Reference No</TH>
>> <TH>Job Descriptions</TH>
>> <TH>Category</TH>
>> <TH>Assign Engineer</TH>
>> <TH>Date Received</TH>
>> <TH>Date Required</TH>
>> <TH>Date Assigned</TH>
>> <TH>Projected Completion Date</TH>
>> <TH>Date Completed</TH>
>> <TH>Manhour Spent</TH>
>> <TH>Status</TH>
>> </TR>
>> </THEAD>
>> <?php
>> $num=mysql_num_rows($result);
>> echo $num;
>> while($row = mysql_fetch_array($result))
>> {
>> echo "<TBODY>";
>> echo "<TR VALIGN=\"TOP\" ALIGN=\"CENTER\">";
>> echo "<TD>{$row['ID']}</TD>";
>> echo "<TD>{$row['Ref_No']}</TD>";
>> echo '<TD> <P><TEXTAREA NAME="Assign_Engineer[' . $row['ID'] .
> '][Job_Title]" ROWS="10"
>> COLS="40">'.$row['Job_Title'] .'</TEXTAREA>';
>> echo " <BR />";
>> echo '<button type="submit" name="save_assign_engineer" value="' .
>> $row['ID'] . '" />Updaet data</button>
>> ';
>> echo "<TD>{$row['Category']}</TD>";
>> echo "<TD>{$row['Assign_Engineer']}</TD>";
>> echo "<TD>{$row['Date_Received']}</TD>";
>> echo "<TD>{$row['Date_Required']}</TD>";
>> echo "<TD>{$row['Date_Assigned']}</TD>";
>> echo "<TD>{$row['ProjectedCompletionDate']}</TD>";
>> echo "<TD>{$row['Date_Completed']}</TD>";
>> echo "<TD>{$row['ManhourSpent']}</TD>";
>> echo "<TD>{$row['Status']}</TD>";
>> echo "</TR>";
>> echo"</TBODY>";
>> }
>> ?>
>>
>>
>>
>>
>>
>>
>> ---------------------------------
>> Sick sense of humor? Visit Yahoo! TV's Comedy with an Edge to see what's
> on, when.

--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
gerritpetersen [ Mi, 23 Mai 2007 12:03 ] [ ID #1721249 ]

Re: Mysql and Textarea (Please help me figure out this problem. I' m stuck. Please help me!!! )

nope.. i just realized when have his source code and read again /sob

the problem is in the button..

he use <button > tag???
he should use <input type=submit> or <input type=button>

oh well... he type a long setence to ask.. why he can't execute ?? not the
code problem but the tag html problem
----- Original Message -----
From: "Birt.Ecplipse" <gerritpetersen [at] gmail.com>
To: <php-windows [at] lists.php.net>
Sent: Wednesday, May 23, 2007 5:03 PM
Subject: Re: [PHP-WIN] Mysql and Textarea (Please help me figure out this
problem. I' m stuck. Please help me!!! )


> Looks like a problem in the definition of the TEXTAREA NAME.
> The echo statement is started and ended with a '
> While in the $row['ID'] also a quote is used. So the echo string looks
not
> correct.
>
> Try: echo '<TD> <P><TEXTAREA NAME="Assign_Engineer[' . $row[\'ID\'] .
> '][Job_Title]" ROWS="10"
>
>
> ""bedul"" <landavia81 [at] gmail.com> wrote in message
> news:009c01c79cf2$7310ad80$670b1e0a [at] mis01...
> > use $_POST[your var] in this script..
> > not simple but worked..
> >
> > other option
> >
> > $_HTTP_POST_VARS[your var]
> >
> >
> > ----- Original Message -----
> > From: "sam rumaizan" <samcalc [at] yahoo.com>
> > To: <php-windows [at] lists.php.net>
> > Sent: Wednesday, May 23, 2007 4:13 AM
> > Subject: [PHP-WIN] Mysql and Textarea (Please help me figure out this
> > problem. I' m stuck. Please help me!!! )
> >
> >
> >> I'm just a php beginner.
> >> So please be patient with my stupid questions.
> >>
> >> What am I missing in this code that causing the function can't update
> > the textarea?
> >>
> >> Update button erase the old information from mysql database and
replace
> > it with nothing. Basically it can't read what is inside the Textarea
box.
> > Why??
> >>
> >> Read the highlighted code.
> >>
> >> <?php
> >> include ('./includes/header.html');
> >> include( '../mysql_connect.php' );
> >> ?>
> >> </HEAD>
> >> <BODY>
> >> <TABLE ALIGN="center" BORDER="0" CELLSPACING="0" CELLPADDING="0">
> >> <TR ALIGN="center" VALIGN="middle">
> >> <TH ALIGN="center"><FONT SIZE="6" COLOR ="#310032">View
> >> Existing Data</FONT></TH>
> >> </TR>
> >> </TABLE>
> >> <FORM METHOD="post" ACTION="ved.php">
> >> <?php
> >> $query = "SELECT DISTINCT Assign_Engineer FROM lo_data";
> >> $result = mysql_query($query);
> >> ?>
> >> <BR /><BR />
> >> <CENTER>
> >> <SELECT NAME="R"><OPTION VALUE="NULL">Choose a Category:</OPTION>
> >> <?php
> >> while ($line = mysql_fetch_array($result))
> >> {
> >> foreach ($line as $value)
> >> {
> >> echo"<OPTION VALUE='$value'";
> >> }
> >> echo ">$value</OPTION>";
> >> }
> >> ?>
> >> </SELECT>
> >> <INPUT TYPE="submit" NAME="Submit" VALUE="Submit Data"><BR /><BR
> >> />
> >> <?php
> >> if (isset($_REQUEST['save_assign_engineer'])) {
> >> $id = (int) $_REQUEST['save_assign_engineer'];
> >> $job_title =
> >> mysql_real_escape_string($_REQUEST['Assign_Engineer'][' .$id .
> > ']['Job_Title']);
> >> $sql = "
> >> UPDATE `lo_data`
> >> SET `Job_Title` = '" . $job_title . "'
> >> WHERE `ID` = " . $id;
> >> mysql_query($sql);
> >> }
> >> if (isset($_POST["R"])) {
> >> $result = mysql_query("SELECT * FROM lo_data WHERE Assign_Engineer
> > ='".$_POST["R"]."'");
> >> }
> >> ?>
> >> <DIV STYLE="overflow:auto;">
> >> <TABLE WIDTH="80" BORDER="1" CELLSPACING="1" CELLPADDING="3"
> >> BORDERCOLOR="CDCB98">
> >> <THEAD>
> >> <TR STYLE="position: relative; top:
> >> expression(this.offsetParent.scrollTop); background-color: #CDCB98;">
> >> <TH>ID</TH>
> >> <TH>Reference No</TH>
> >> <TH>Job Descriptions</TH>
> >> <TH>Category</TH>
> >> <TH>Assign Engineer</TH>
> >> <TH>Date Received</TH>
> >> <TH>Date Required</TH>
> >> <TH>Date Assigned</TH>
> >> <TH>Projected Completion Date</TH>
> >> <TH>Date Completed</TH>
> >> <TH>Manhour Spent</TH>
> >> <TH>Status</TH>
> >> </TR>
> >> </THEAD>
> >> <?php
> >> $num=mysql_num_rows($result);
> >> echo $num;
> >> while($row = mysql_fetch_array($result))
> >> {
> >> echo "<TBODY>";
> >> echo "<TR VALIGN=\"TOP\" ALIGN=\"CENTER\">";
> >> echo "<TD>{$row['ID']}</TD>";
> >> echo "<TD>{$row['Ref_No']}</TD>";
> >> echo '<TD> <P><TEXTAREA NAME="Assign_Engineer[' . $row['ID'] .
> > '][Job_Title]" ROWS="10"
> >> COLS="40">'.$row['Job_Title'] .'</TEXTAREA>';
> >> echo " <BR />";
> >> echo '<button type="submit" name="save_assign_engineer" value="' .
> >> $row['ID'] . '" />Updaet data</button>
> >> ';
> >> echo "<TD>{$row['Category']}</TD>";
> >> echo "<TD>{$row['Assign_Engineer']}</TD>";
> >> echo "<TD>{$row['Date_Received']}</TD>";
> >> echo "<TD>{$row['Date_Required']}</TD>";
> >> echo "<TD>{$row['Date_Assigned']}</TD>";
> >> echo "<TD>{$row['ProjectedCompletionDate']}</TD>";
> >> echo "<TD>{$row['Date_Completed']}</TD>";
> >> echo "<TD>{$row['ManhourSpent']}</TD>";
> >> echo "<TD>{$row['Status']}</TD>";
> >> echo "</TR>";
> >> echo"</TBODY>";
> >> }
> >> ?>
> >>
> >>
> >>
> >>
> >>
> >>
> >> ---------------------------------
> >> Sick sense of humor? Visit Yahoo! TV's Comedy with an Edge to see
what's
> > on, when.
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>

--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
bedul [ Do, 24 Mai 2007 03:15 ] [ ID #1721254 ]

Start and stop windows service for multiple remote computers

--0-867205786-1222714720=:68039
Content-Type: text/plain; charset=us-ascii

Can someone show me how to Start and Stop windows service for multiple remote computers using Command Prompt or PowerShell or even Java?

Thank you



--0-867205786-1222714720=:68039--
sam rumaizan [ Mo, 29 September 2008 20:58 ] [ ID #1971223 ]

[***SPAM***] Re: [PHP-WIN] Start and stop windows service for multiple remote computers

The command line command net can start/stop services, so you could put the
relevant command into a batch file of sorts:
C:\WINDOWS\system32\net.exe start serviceName

or

C:\WINDOWS\system32\net.exe stop serviceName

HTH

Jacob Kruger
Blind Biker
Skype: BlindZA
'...Fate had broken his body, but not his spirit...'

----- Original Message -----
From: "sam rumaizan" <samcalc [at] yahoo.com>
To: <php-windows [at] lists.php.net>
Sent: Monday, September 29, 2008 8:58 PM
Subject: [PHP-WIN] Start and stop windows service for multiple remote
computers


> Can someone show me how to Start and Stop windows service for multiple
> remote computers using Command Prompt or PowerShell or even Java?
>
> Thank you
>
>
>


--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Jacob Kruger [ Mo, 29 September 2008 22:38 ] [ ID #1971224 ]

Re: Start and stop windows service for multiple remotecomputers

Hi Sam,

sam rumaizan wrote:

> Can someone show me how to Start and Stop windows service for multiple remote computers using Command Prompt or PowerShell or even Java?
> Thank you
>
please have a look at the following windows commands:

"net start" / "net stop" -> available on Windows 2000 and above, I think it's also available on Windows NT 4
"sc query", "sc start", "sc stop" -> available on Windows XP, also works on remote computers other than XP (works when started on XP and stopping a service on Win 2000 SP4)

Otherwise have a look at the PSService from SysInternals, http://technet.microsoft.com/de-de/sysinternals/bb897542.asp x

Good luck!

Regards,

Sascha



--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
harlequin2 [ Di, 30 September 2008 08:36 ] [ ID #1971479 ]

drop down menu to a table

--0-1224431455-1236043652=:56071
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: quoted-printable

How do I insert data from a drop down menu=A0values (select box) to a table
=0A=0A=0A
--0-1224431455-1236043652=:56071--
sam rumaizan [ Di, 03 März 2009 02:27 ] [ ID #1991645 ]

Re: drop down menu to a table

--0-1660838963-1236048775=:66733
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: quoted-printable

How do you specify the value of the option?



--- On Mon, 3/2/09, pterry [at] sensite.net <pterry [at] sensite.net> wrote:

From: pterry [at] sensite.net <pterry [at] sensite.net>
Subject: Re: [PHP-WIN] drop down menu to a table
To: samcalc [at] yahoo.com, php-windows [at] lists.php.net
Date: Monday, March 2, 2009, 6:38 PM

Include the drop down in a form with method=3Dpost and action=3Dsomething.p=
hp
In something.php, write $_post['drop down name'] to the table.
Sent from my Verizon Wireless BlackBerry

-----Original Message-----
From: sam rumaizan <samcalc [at] yahoo.com>

Date: Mon, 2 Mar 2009 17:27:32
To: <php-windows [at] lists.php.net>
Subject: [PHP-WIN] drop down menu to a table


How do I insert data from a drop down menu=A0values (select box) to a table




=0A=0A=0A
--0-1660838963-1236048775=:66733--
sam rumaizan [ Di, 03 März 2009 03:52 ] [ ID #1991646 ]

RE: drop down menu to a table

This will be you answer I guess

<option value=3D"foo">bar</option>



-----Original Message-----
From: sam rumaizan [mailto:samcalc [at] yahoo.com]
Sent: dinsdag 3 maart 2009 3:53
To: php-windows [at] lists.php.net; pterry [at] sensite.net
Subject: Re: [PHP-WIN] drop down menu to a table

How do you specify the value of the option?



--- On Mon, 3/2/09, pterry [at] sensite.net <pterry [at] sensite.net> wrote:

From: pterry [at] sensite.net <pterry [at] sensite.net>
Subject: Re: [PHP-WIN] drop down menu to a table
To: samcalc [at] yahoo.com, php-windows [at] lists.php.net
Date: Monday, March 2, 2009, 6:38 PM

Include the drop down in a form with method=3Dpost and =
action=3Dsomething.php
In something.php, write $_post['drop down name'] to the table.
Sent from my Verizon Wireless BlackBerry

-----Original Message-----
From: sam rumaizan <samcalc [at] yahoo.com>

Date: Mon, 2 Mar 2009 17:27:32
To: <php-windows [at] lists.php.net>
Subject: [PHP-WIN] drop down menu to a table


How do I insert data from a drop down menu=A0values (select box) to a =
table









--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Marien den Besten [ Di, 03 März 2009 09:44 ] [ ID #1991647 ]

Re: drop down menu to a table

--000325575a3643ab90046436fbbe
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

>
> How do you specify the value of the option?
>

Or if you are working with values from a database you could do something
simple like:

<SELECT name="name">
<?php
$q_name = "SELECT * from name_table";
$r_name = ifx_query($q_name, $connect_id) or die("couldn't execute the
query");
while ($rec_name = ifx_fetch_row($r_name)) $name[] = $rec_name;

echo "<OPTION value=\"\">--SELECT--</OPTION>\n";
foreach ($name as $n)
{
if ($n['full_name'] == $_POST['name'])
echo "<OPTION value=\"{$n['full_name']}\"
SELECTED>{$n['full_name']}</OPTION>\n";
else
echo "<OPTION
value=\"{$n['full_name']}\">{$n['full_name']}</OPTION>\n";
}
?>
</SELECT>

--000325575a3643ab90046436fbbe--
Dan Shirah [ Di, 03 März 2009 14:33 ] [ ID #1991648 ]

Re: drop down menu to a table

sam rumaizan wrote:
> How do I insert data from a drop down menu values (select box) to a table
>
>

If you start a new thread, you are more likely to get a response that
helps you.

To answer your questions is use javascript. This is a php group. Go to
the right group.

Ian




--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
pkaluski [ Fr, 06 März 2009 13:54 ] [ ID #1992451 ]
PHP » gmane.comp.php.windows » Mysql and Textarea (Please help me figure out this problem. I' m stuck. Please help me!!! )

Vorheriges Thema: php 5.3 namespace issue ...
Nächstes Thema: 2009 Credit Report America - Free Check