spacer

Webref WebRef   Sitemap · Experts · Tools · Services · Newsletters · About i.com

home / experts / javascript / column50


Using JavaScript in HomeSite 4.0, Part III

Developer News
News Flash: Adobe Has iPhone Workaround
Adobe's Flash 10.1 Goes Mobile (Minus iPhone)
A Salute to Visionary CEOs

The HTTPProvider Object's Methods, Part I

The HTTPProvider object supports a handful of methods:

Get()None

Performs the HTTP GET method request. You have to set all appropriate HTTPProvider object's properties to set the HTTP request parameters such as username, password, proxy server and settings, etc. The following script issues the Get() method and then prints the HTTPProvider object's properties:

var app = Application;
function Main() {
  app.HTTPProvider.URL = "http://www.webreference.com/js";
  app.HTTPProvider.Get();
  app.MessageBox( 
    "Agent='" + app.HTTPProvider.Agent + "'\n" +
    "AuthorizationRequest='" + app.HTTPProvider.AuthorizationRequest + "'\n"+
    "ContentLength='" + app.HTTPProvider.ContentLength + "'\n" +
    "ContentType='" + app.HTTPProvider.ContentType + "'\n" +
    "ContentTypePost='" + app.HTTPProvider.ContentTypePost + "'\n" +
    "Cookie='" + app.HTTPProvider.Cookie + "'\n" +
    "DocName='"	+ app.HTTPProvider.DocName + "'\n" +
    "Location='" + app.HTTPProvider.Location + "'\n" +
    "ModifiedSince='"	+ app.HTTPProvider.ModifiedSince + "'\n" +
    "MultiThreaded='"	+ app.HTTPProvider.MultiThreaded + "'\n" +
    "NoCache='" + app.HTTPProvider.NoCache + "'\n" +
    "Password='" + app.HTTPProvider.Password + "'\n" +
    "Proxy='"	+ app.HTTPProvider.Proxy + "'\n" +
    "ProxyPassword='" + app.HTTPProvider.ProxyPassword + "'\n" +
    "ProxyPort='" + app.HTTPProvider.Proxyport + "'\n" +
    "ProxyUsername='" + app.HTTPProvider.ProxyUsername + "'\n" +
    "RcvdCount='"	+ app.HTTPProvider.RcvdCount + "'\n" +
    "ReasonPhrase='" + app.HTTPProvider.ReasonPhrase + "'\n" +
    "Reference='"	+ app.HTTPProvider.Reference + "'\n" +
    "Sender='" + app.HTTPProvider.Sender + "'\n" +
    "SentCount='"	+ app.HTTPProvider.SentCount + "'\n" +
    "State='"	+ app.HTTPProvider.State + "'\n" +
    "StatusCode='" + app.HTTPProvider.StatusCode + "'\n" +
    "URL='"	+ app.HTTPProvider.URL + "'\n" + 
    "Username='" + app.HTTPProvider.Username + "'\n",
    "HTTP Provider Diagnostics", 0); 
  app = null;
}

Here is how this MessageBox looks:

http://www.internet.com

Produced by Yehuda Shiran and Tomer Shiran

internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Reprints, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs

webref The latest from WebReference.com Browse >
Building a Banking Application Home Page with OOP · Mixing Scripting Languages · Review: phpFox, a Social Networking CMS with all the Bells and Whistles
Sitemap · Experts · Tools · Services · Email a Colleague · Contact FREE Newsletters 
 The latest from internet.com
Enterprise 2.0: Social Networking in the Cloud · BroadSoft Marketplace Hastens Pace of Telephony Innovation · Review: HTC Hero for Sprint


Created: October 11, 1999
Revised: October 15, 1999

URL: http://www.webreference.com/js/column50/httpmeth1.html