Esuom
Guru

Okay, I had a friend write me up a few functions that I needed, the problem is, I haven't seen him in a while and the function I need, I don't understand 100% on how to use.
I am trying to use...
I know what it is supposed to do, I just can't figure out the set up.
Thanks for any help.
I am trying to use...
Code:
string GetSource(char m_strURL[])
{
if ( m_strURL == "" )
{
return "";
}
HINTERNET hINet, hFile;
hINet = InternetOpen("InetURL/1.0", INTERNET_OPEN_TYPE_PRECONFIG, NULL, NULL, 0 );
if ( !hINet )
{
return "";
}
hFile = InternetOpenUrl( hINet, m_strURL, NULL, 0, 0, 0 ) ;
string m_strContents;
if ( hFile )
{
CHAR buffer[1024];
DWORD dwRead;
while ( InternetReadFile( hFile, buffer, 1023, &dwRead ) )\
{
if ( dwRead == 0 )
break;
buffer[dwRead] = 0;
m_strContents += buffer;
}
InternetCloseHandle( hFile );
}
InternetCloseHandle( hINet );
return m_strContents;
}
I know what it is supposed to do, I just can't figure out the set up.
Thanks for any help.

