/    Sign up×
Community /Pin to ProfileBookmark

Guru help needed with forms

I have a script written in PHP that looks like this:

[code=php]<?//there is only non-pertinant info above this
while ($row=mysql_fetch_array($list))
{
?>
<FORM ACTION=”xxxxxx” METHOD=GET>
<?
echo “<FONT COLOR=”#FFCC00”><B><CENTER>List for the raid on “.$row[‘target’].” that was run by “.$row[‘host’].” at “.$row[‘raidtime’].”</FONT><BR>rn”;
echo $row[‘credit’].”</CENTER></B><BR>rn”;
?>
<CENTER><INPUT TYPE=SUBMIT NAME=”APPROVE” VALUE=”Approve Points!”> <INPUT TYPE=SUBMIT NAME=”DELETE” VALUE=”Delete Raid!”>
</FORM>

<BR><BR><BR>

<?
[/code]

The output is the following:

[code]<FORM ACTION=”xxxxxxxxxx” METHOD=GET><FONT COLOR=”#FFCC00″><B><CENTER>List for the raid on Test that was run by Shibbey at 2003-03-15 15:47:00</FONT><BR>
Shibbey, Argulace, Crepuscular, Compost</CENTER></B><BR>
<CENTER><INPUT TYPE=SUBMIT NAME=”APPROVE” VALUE=”Approve Points!”> <INPUT TYPE=SUBMIT NAME=”DELETE” VALUE=”Delete Raid!”>
</FORM>

<BR><BR><BR>

<FORM ACTION=”xxxxxxxx” METHOD=GET><FONT COLOR=”#FFCC00″><B><CENTER>List for the raid on MoK that was run by Argulace at 2003-03-15 15:54:17</FONT><BR>
Shibbey, Argulace, Solarance</CENTER></B><BR>
<CENTER><INPUT TYPE=SUBMIT NAME=”APPROVE” VALUE=”Approve Points!”> <INPUT TYPE=SUBMIT NAME=”DELETE” VALUE=”Delete Raid!”>
</FORM>

<BR><BR><BR>[/code]

xxxxxx was substituted for security reasons… How can I make the form submit the list of names? I don’t care if the names can be added to, or deleted. In fact if there is a way to set a default value to the <INPUT TYPE=TEXT> function, that would be best!

to post a comment
HTML

1 Comments(s)

Copy linkTweet thisAlerts:
@khalidali63Mar 15.2003 — If I understood your question correctly,

add this line of code in the code where you create HTML code in your PHP.

<input type="hidden" name="nameList" value="Shibbey, Argulace, Crepuscular, Compost"/>

Now when the form is submitted you will have

nameList = Shibbey, Argulace, Crepuscular, Compost

Hope this helps

Khalid
×

Success!

Help @Shibbey spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.19,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...