post to an alternate non dot.net page

G

Guest

I need to post a form to an alternate technology. I have created pop up
windows that on post back will open a new window, but this uses get. I need
to encode variables and POST to a new window on post back? Are there new
elemebts in 2.0 that allow for this, or does anyone have a solution?

Thanks
 
G

Guest

Thanks for the reply,
I did read this posting, but did not see how it would help me integrate my
dot.net site with another site with an alternate technology. I may be missing
something, but i'm not integrating with UPS. Both sites were written by me
one is dot.net the other is ColdFusion each has fairly sophistacated logon
services that i can not be access directly one from the other. My hope is to
create an HTTP post to the other with login values, I can use get with a
popup window, but that means passing url parameters.
Is there a specific section of the ups site that shows how to do this that
does not need appily to only ups?

Again, i appreciate your response and am gratful for any help you can provide
 
G

Guest

string uriString="http://otherapp/yourcfpage.cfm";
// Create a new WebClient instance.
WebClient myWebClient = new WebClient();
string postData = "name=value&name2=value2...etc"; //POST data here
myWebClient.Headers.Add("Content-Type","application/x-www-form-urlencoded");
// Apply ASCII Encoding to obtain the string as a byte array.
byte[] byteArray = Encoding.ASCII.GetBytes(postData);
// Upload the input string using the HTTP 1.0 POST method.
byte[] responseArray = myWebClient.UploadData(uriString,"POST",byteArray);
string responseText= Encoding.ASCII.GetString(responseArray));


--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net
 
G

Guest

thanks,
I've done web client requests and they work quite well, however, I'm
attempting to redirect to another page not import or display page content.
Ironically, the only solution i can see that will work is to have the
ColdFusion page read a aspx page using the CF equivilent of your suggestion.
My major problem with that is needing to add an alternative login function to
ColdFusion.
Again, thank you i appreciate you response.

(a side note: I've done CF for 11+ years now and although i perfer dot.net
because it's a programmers language, CF is still faster to code and it's
execution time with jdbc/mssql is not that much slower than sql native. I
tried to convert this system with 1.1 and had to giveup because sometimes the
web server would shut down because of the load. The 2.0 conversion is moving
along, but i'm still relying on CF for some data de-normalization that i
needed to get up and running quickly when dot.net functions kept crashing the
sqlserver and the web server.)
--
thanks (as always)
some day i''m gona pay this forum back for all the help i''m getting
kes


Peter Bromberg said:
string uriString="http://otherapp/yourcfpage.cfm";
// Create a new WebClient instance.
WebClient myWebClient = new WebClient();
string postData = "name=value&name2=value2...etc"; //POST data here
myWebClient.Headers.Add("Content-Type","application/x-www-form-urlencoded");
// Apply ASCII Encoding to obtain the string as a byte array.
byte[] byteArray = Encoding.ASCII.GetBytes(postData);
// Upload the input string using the HTTP 1.0 POST method.
byte[] responseArray = myWebClient.UploadData(uriString,"POST",byteArray);
string responseText= Encoding.ASCII.GetString(responseArray));


--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net




WebBuilder451 said:
Thanks for the reply,
I did read this posting, but did not see how it would help me integrate my
dot.net site with another site with an alternate technology. I may be missing
something, but i'm not integrating with UPS. Both sites were written by me
one is dot.net the other is ColdFusion each has fairly sophistacated logon
services that i can not be access directly one from the other. My hope is to
create an HTTP post to the other with login values, I can use get with a
popup window, but that means passing url parameters.
Is there a specific section of the ups site that shows how to do this that
does not need appily to only ups?

Again, i appreciate your response and am gratful for any help you can provide
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,436
Messages
2,571,696
Members
48,796
Latest member
Greg L.
Top