Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

php and some extra help

Status
Not open for further replies.

fireburner69

Programmer
Aug 22, 2002
108
GR
i have these code
<form action=&quot; method=&quot;post&quot;>
<table border=&quot;0&quot; cellpadding=&quot;3&quot; cellspacing=&quot;1&quot; align=&quot;center&quot;>
<tr>
<td align=&quot;right&quot;><font size=&quot;2&quot;>Username:&nbsp;</font></td>
<td>
<input type=&quot;text&quot; name=&quot;username&quot; size=&quot;12&quot; maxlength=&quot;40&quot; value=&quot;&quot; />
</td>
</tr>
<tr>
<td align=&quot;right&quot;><font size=&quot;2&quot;>Password:&nbsp;</font></td>
<td>
<input type=&quot;password&quot; name=&quot;password&quot; size=&quot;12&quot; maxlength=&quot;25&quot; />
</td>
</tr>

<tr align=&quot;center&quot;>
<td colspan=&quot;2&quot;>
<table width=&quot;100%&quot; border=&quot;0&quot;>
<tr>

<td rowspan=&quot;2&quot;>
<div align=&quot;center&quot;>
<input type=&quot;hidden&quot; name=&quot;redirect&quot; value=&quot; />
<input type=&quot;submit&quot; name=&quot;login&quot; value=&quot;Login&quot; />
</div>




that post some data username and password into another file


how can i make it more automatic!can i user a single string line in the url bar like to post automatic the username and password into the login.php file?

or can i change the username input into username=&quot;demo1&quot;
and password=&quot;demo1&quot;

and how to i make the php to post immediatly with out any clicking just when i open the file to redirect with the correct data?


thanx for your help
 
Hello,

wht i can understood that u want to post the data to &quot;
so if ur form action is &quot; why ur redirecting it .
when u submit the form the login.php will get called and u can access the fields directly as $username and $password

<form action=&quot; method=&quot;post&quot;>
<table border=&quot;0&quot; cellpadding=&quot;3&quot; cellspacing=&quot;1&quot; align=&quot;center&quot;>
<tr>
<td align=&quot;right&quot;><font size=&quot;2&quot;>Username: </font></td>
<td>
<input type=&quot;text&quot; name=&quot;username&quot; size=&quot;12&quot; maxlength=&quot;40&quot; value=&quot;&quot; />
</td>
</tr>
<tr>
<td align=&quot;right&quot;><font size=&quot;2&quot;>Password: </font></td>
<td>
<input type=&quot;password&quot; name=&quot;password&quot; size=&quot;12&quot; maxlength=&quot;25&quot; />
</td>
</tr>
<input type=&quot;submit&quot; name=&quot;login&quot; value=&quot;Login&quot;>


in login.php
echo &quot;username: &quot;.$username ;
echo &quot;password: &quot;.$password ;




--------------------------------------------------------------------------
I never set a goal because u never know whats going to happen tommorow.
 
I want the user to have a php file witch only by going into these php code to enter directly into the forum!
I redirect the data because i can not fully understand the code in login.php!It is too big and too complicated!

So I want to make a autologin php page! the user not to enter anything for example
my username is demo1 and password is demo1

i want to have inside the php the username=demo1
and password demo1
and to post automatic into login.php is there a way to do that?

help for your help
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top