LoadVars.contentType Property

ActionScript for Flash MX: The Definitive Guide, 2nd Edition
By Colin Moock
Chapter 18.  ActionScript Language Reference
LoadVars.contentType Property Flash 6

the MIME type used for send( ) and sendAndLoad( ) operations read/write
loadVarsObject.contentType

Description

The contentType property is the MIME content type that is sent to a server when LoadVars.send( ) or LoadVars.sendAndLoad( ) is invoked. For most practical purposes, its default value (application/x-www-form-urlencoded) need never be changed. It is writable to allow MIME type flexibility in unique circumstances.

The LoadVars.prototype.contentType property can be used to change the MIME content type for all LoadVars instances that do not set it themselves. For example:

LoadVars.prototype.contentType = "yourContentTypeGoesHere";

Example

dataSender = new LoadVars(); trace(dataSender.contentType);  // Displays: application/x-www-form-urlencoded

See Also

LoadVars.send( ), LoadVars.sendAndLoad( )



    ActionScript for Flash MX. The Definitive Guide
    ActionScript for Flash MX: The Definitive Guide, Second Edition
    ISBN: 059600396X
    EAN: 2147483647
    Year: 2002
    Pages: 780
    Authors: Colin Moock

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net