473,791 Members | 3,111 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Sending POST data without Submit button or javascript.

Ok, say I have some data:

$name = "Some Name"
$email = "so**@email.com "
etc.

I'd like to send these to a page as POST data, as if they were coming
from a web form, but without having either a "submit" button or using
Javascript's submit() function.

Is there a way to do this?

--
Sugapablo - ru***********@s targate.net
http://www.sugapablo.com | ICQ: 902845

Jul 16 '05 #1
3 23208
Sugapablo wrote:
I'd like to send these to a page as POST data, as if they were coming
from a web form, but without having either a "submit" button or using
Javascript's submit() function.

Is there a way to do this?


Yes. The easiest is to use a library or class that someone else wrote
for the purpose. Check this search and see if there is anything you can
use:
http://www.phpclasses.org/search.htm...and&sort=score

Jochen

--
/**
* @author Jochen Buennagel <zang at buennagel dot com>
* @see http://www.sourceforge.net/projects/zang
*/

Jul 16 '05 #2
Jochen Buennagel wrote:
Yes. The easiest is to use a library or class that someone else wrote
for the purpose. Check this search and see if there is anything you can
use:
http://www.phpclasses.org/search.htm...and&sort=score


The cHTTP class worked wonderfully.

Thanks.

--
Sugapablo - ru***********@s targate.net
http://www.sugapablo.com | ICQ: 902845

Jul 16 '05 #3
nikonetwork
1 New Member
Jochen Buennagel wrote:
[color=blue]
> Yes. The easiest is to use a library or class that someone else wrote
> for the purpose. Check this search and see if there is anything you can
> use:
> http://www.phpclasses.org/search.htm...and&sort=score[/color]

The cHTTP class worked wonderfully.

Thanks.

--
Sugapablo - russpghREMOVE@s targate.net
http://www.sugapablo.com | ICQ: 902845
Hi, I just tryed also the cHTTP class, but didn't worked as expected for me:
When I execute my code, nothing happens. I was expecting to be redirected to the URL where I want to send data in POST.
here is my code:
<?
include("cHTTP. php");
//create instance of the class
$http = new cHTTP();
// to make posts
// clear all fields
$http->clearFields( );

$http->addField ( 'email' , 'post1' );
$http->addField ( 'password' , 'post2' );

$http->postPage("http ://www.sxmone.com/aroundme/testReader.php" );
?>

Did you do it different? How can I be redirected to "testReader.php " with my info posted?
Apr 27 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
2601
by: Person | last post by:
I have a popup window with a form: The popup window is opened like this: <SCRIPT LANGUAGE=javascript> window.open('primos.html', 'primos', config='height=300, width=400') </SCRIPT> The form on the popup window is this:
4
2193
by: Dodo | last post by:
Is it possible to create a link that can post a value to an ASP page without java?
7
2005
by: Matt | last post by:
Hi all, Not very sure about this. I have one button (not a submit button) will "post" partial page(form) info to another url(the user will also redirect to this url :-). I dont' want to change the webpage interface, so how can I POST partial form info? by using a tmp url??? TIA
2
12562
by: Matt | last post by:
When we submit the form data to another page, we usually do the following: <form action="display.aspx" method="post"> will submit the form data and open display.asp in the current browser <form action="display.aspx" method="post" target="_blank"> will submit the form data and open display.asp in a new browser
4
16284
by: dschruth | last post by:
Hello. Can anybody solve this problem? I am using a server-side language (PERL) to *try* to POST data to a HTTPS login script that doesn't have a standard "submit" button. The form appears to use javascript to submit the document via the browser's DOM. <form action='loginScript.cgi' method="post" name="loginForm">
2
2186
by: sunilthk | last post by:
Hi All, I have a question. If javascript is disabled how asp.net determines which control has caused the post back. As we know that when we clicks on the button the buttons name goes with posted data, so asp.net can detrmine which btn caused the post back. In case of dropdown lists(if auto post back is true) _doPostback javascript function is called which assigns the name of the control in _EVENTTARGET hidden variable, by this ASP.NET...
2
2300
by: rynato | last post by:
I have a form which the user fills out to enter some data. If there already exists an uncompleted session - say, the user started entering some data but had to stop to do something else - the user has the option of selecting that session from a drop-down menu (think <form><select><option>....</option></select></form>). The method for that particular form is set to 'GET' and the action is $_SERVER. The <selecttag has a bit of javascript...
7
10294
xNephilimx
by: xNephilimx | last post by:
lHi guys! I'm having a little problem that's getting on my nerves, I couldn't find a solution, I also tryed googling it and I found nothing... (my field of expertise is in AS 2 and 3, but I still lack some JavaScript solid knowdlege) The problem is that when I try to send a form's content with Ajax (I'm using the prototype library), for some reason the latin characters (accents and stuff, like áéíóú) turn a mess when I try to store them in...
8
2691
omerbutt
by: omerbutt | last post by:
hi there i have a form with multiple input (type/text ) fields and three inputs(type/file) fields i have to submit the form via ajax because i have multiple forms on this page ,you can say it is a contact_us.php page.Now i can get all the inputs at the other end else the input(type/file) i donot want a submit button what i want that some how io can send the file name and the path of the picture that is to be uploaded and send to a page via ajax...
0
9669
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9517
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10207
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10156
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9030
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6776
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5559
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4110
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2916
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.