By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
426,165 Members | 1,916 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 426,165 IT Pros & Developers. It's quick & easy.

post to an alternate non dot.net page

P: n/a
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

--
thanks (as always)
some day i''m gona pay this forum back for all the help i''m getting
kes
Feb 12 '07 #1
Share this Question
Share on Google+
4 Replies


P: n/a
On Feb 12, 8:38 pm, WebBuilder451
<WebBuilder...@discussions.microsoft.comwrote:
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
http://groups.google.com/group/micro...d71ecdf64fa50f

Feb 12 '07 #2

P: n/a
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
--
thanks (as always)
some day i''m gona pay this forum back for all the help i''m getting
kes
"Alexey Smirnov" wrote:
On Feb 12, 8:38 pm, WebBuilder451
<WebBuilder...@discussions.microsoft.comwrote:
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

http://groups.google.com/group/micro...d71ecdf64fa50f

Feb 12 '07 #3

P: n/a
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" wrote:
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
--
thanks (as always)
some day i''m gona pay this forum back for all the help i''m getting
kes
"Alexey Smirnov" wrote:
On Feb 12, 8:38 pm, WebBuilder451
<WebBuilder...@discussions.microsoft.comwrote:
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
http://groups.google.com/group/micro...d71ecdf64fa50f
Feb 12 '07 #4

P: n/a
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 [C# MVP]" wrote:
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" wrote:
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
--
thanks (as always)
some day i''m gona pay this forum back for all the help i''m getting
kes
"Alexey Smirnov" wrote:
On Feb 12, 8:38 pm, WebBuilder451
<WebBuilder...@discussions.microsoft.comwrote:
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
>
http://groups.google.com/group/micro...d71ecdf64fa50f
>
>
Feb 12 '07 #5

This discussion thread is closed

Replies have been disabled for this discussion.