Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
inet
active_desktop
active_scrptng
asp.components
asp.db
asp.general
comctl32
comp.packaging
components.dev
dbweb
dhtml_editing
docobjects
html_authoring
html_objmodel
iis
iis.ftp
iis.security
iis.smtp_nntp
indexserver
misc
mshtml_hosting
scripting.jscript
scripting.vbscript
sdk_setup
shell_objmodel
urlmonikers
webbrowser_ctl
wininet
  
 
date: Sun, 9 Mar 2008 23:37:00 -0700,    group: microsoft.public.inetsdk.programming.webbrowser_ctl        back       


Custom Headers not sent in Navigate method   
Recently it appears that the webbrowser control has broken. I have noticed 
that if you post data to a website using the Navigate Method (c++ api) the 
additional header is ignored and not sent. 

The code below has stopped working in my current XP installation yet if I 
start an older installation of XP it works just fine. the only difference 
between the 2 os's is the older version doesnt get updates as its a virtual 
environment used for testing. (eg changes are never saved)

I am running IE 6 in my current environment and IE 7 in my test environment 
IE 6 is now failing to send the header but this was not always the case.

Unless you send the "Content-Type: application/x-www-form-urlencoded" header 
the webserver does not correctly interpret the parameters. I have confirmed 
that the headers are not present in the onbeforenavigate and not received by 
the web server

It appears to me that a recent update has broken the webbrowser control or 
somehow my installation has become corrupted. not sure which.

Upgrading to IE7 "MAY" fix the problem but as many users persist with IE 6 
myself included, I don't see it as an option to demand everyone upgrades.


Has anyone else noticed or can confirm this aberrant behavior?

// Post the information provided
TVariant postdata;

GetPostData(&postdata,PostData.c_str()); // turns a string into a variantarray

// Create the variants used when navigating (borland yes it works)
TVariant 
vUrl(url),vPd(postdata),vNull(LPCTSTR(NULL)),vHeader(L"Content-Type: 
application/x-www-form-urlencoded\r\n");
	RBSTR nurl(url.c_str());

	if (browser)
		browser->Navigate(nurl,&vNull,&vNull,&vPd,&vHeader);
date: Sun, 9 Mar 2008 23:37:00 -0700   author:   developer_chris

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us