i am trying to send a emailid from php page to asp page...but its does not receive
by my server. i am using form get method..but if i add # in my mail id..then its show error..other wise its ok.... its my php page coding
<form action="Default.aspx" method="GET" name="frm" title="demo" enctype="multipart/form-data">
Email<br/> <input type="text" name="email"/><br/><br/>
<input type="submit" name="submit"/>
</form>
Related
I have an html form and 2 php files, all of which work well. In the form I created a preview button that references a php file that shows the uploaded cvs in an html table as a preview. The submit button inserts it into a database.
I would like to have the form contain one button that goes to the preview page and once the info is confirmed, there would be another button that references the submitted file, but I can't seem to get that to work.
Due to the environment I'm trying to get this to work without javascript or ajax if possible, as another user gave me a javascript option.
Here is the html form:
<form method="post" action="confirm.php" enctype="multipart/form-data">
<label>Upload File</label>
<input type="file" name="file">
<input type="submit" name="submit" value="Confirm" >
</form>
<form method="post" action="upload.php" enctype="multipart/form-data">
<label>Upload File</label>
<input type="file" name="file">
<input type="submit" name="submit" value="Submit">
</form>
Each Php file corresponds as well:
if(isset($_POST['submit']))
Is there any way to go from upload to preview to submit and keep reference to $file?
I have a php page with a form which I want to search the user database from for a username match. This is my code:
<form id="searchuser" name="searchuser" method="post" action="">
Enter a username to search for:
<label>
<input type="text" name="uname" id="uname" />
</label>
<label>
<input type="submit" name="submit" id="submit" value="Search" />
</label>
<p> </p>
</form>
Do I need to put setcookie() in the action?
The action field of a form should contain URL (relative or absolute) of the php script which the browser will navigate into while passing the form fields as a POST request.
For example, you can create a php script named search.php, set action="search.php" in the form and then access the fields of the form in that script using $_POST['uname'] for example.
Not sure what you need to set the cookies for in this form but to set a cookie you need to put the setcookie() call somewhere in your php script, NOT in the HTML code. Also you need to call the setcookie() before any HTML output in your php script.
I have a chat and i would want to send files also during chat. I would want the same approach like facebook has: when you put the file it should not put into the specific textbox that comes with input=file and to not have the browse button? is this doable?
<form method="POST" name="form1" action="" id="myForm" enctype="multipart/form-data">
<input name="message" type="text" id="textb" value="" />
<input name="submit" type="submit" value="Chat" id="post_button"/>
<input type="file" name="fisier">
</form>
That's done with a combination of CSS and javascript.
Take a look at: http://www.dropzonejs.com/
My problem is this :
I got 2 forms that are supposed to send different informations to the same page (via POST method). Each form has a submit button. However when I press any of the button, information from both forms are sent to the page.
Is it normal or is there something that I do wrong ?
I can already tell you without looking at your HTML.
You have to properly close the first form before opening the second. Easy mistake to make.
<form method="post" action="page.php">
<input type="text" name="something" />
<input type="submit" value="Submit" />
</form>
<form method="post" action="page.php">
<input type="text" name="somethingelse" />
<input type="submit" value="Submit" />
</form>
I don't know if this is possible, what I want is just to get the html or the plain-text from the result of a form sent to a external page.
In this case, I have a form that send the variables to a external server and the result goes to the iframe, how I retrieve the html or text from the iframe? This is the correct way?
I'm trying to do this just to simplify a repetitive process here on my agency...
<form name="form" method="post" action="https://www.externalpage.com" target="iframe">
<input type="hidden" name="a" value="0000"/>
<input type="hidden" name="b" value="0001" />
<input type="hidden" name="c" value="0002" />
<p>
<input type="submit" id="button" value="Submit" />
</p>
</form>
<iframe name="iframe" scrollbars="no"></iframe>
Assuming from the tags you are using jquery
var myresult = $('iframe[name="iframe"]').html();
Should do the work.
//edit: just noticed the iframe is from an external domain, it might be subject to the same origin policy, in this case the above code might not work