Jump to content

How to use a link to fill in <input></input> Forms


carefree

Recommended Posts

Is it possible to use a link to fill in <input></input> Forms??

 

When clicked the "Basic_Free_Account" Should show up in the input box below. But this dosent work for me.

 

Heres my link:

 

http://www.mysite.com/partnerform.php?name=Basic_Free_Account

 

 

Heres my form input:

 

 

<input name="name" maxlength="500" style="width:150px; float:left" size="500" />

 

All pages are in php

 

Anyone have any ideas??

Link to comment
https://forums.phpfreaks.com/topic/72752-how-to-use-a-link-to-fill-in-forms/
Share on other sites

hehe  ???

 

$_GET is the url parameters, not a database:

 

so when your link goes to http://www.blah.com/page.php?name=myname

 

$_GET["name"] would = myname

 

in your case

<?php
//..... code code code
echo "<input name=\"name\" maxlength=\"500\" style=\"width:150px; float:left\" size=\"500\" value='{$_GET["name"]}' />

... should do the trick

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.