1 /****************************************************************************
3 ** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
4 ** All rights reserved.
5 ** Contact: http://www.qt-project.org/
7 ** This file is part of the documentation of the Qt Toolkit.
9 ** $QT_BEGIN_LICENSE:FDL$
10 ** GNU Free Documentation License
11 ** Alternatively, this file may be used under the terms of the GNU Free
12 ** Documentation License version 1.3 as published by the Free Software
13 ** Foundation and appearing in the file included in the packaging of
17 ** Alternatively, this file may be used in accordance with the terms
18 ** and conditions contained in a signed written agreement between you
26 ****************************************************************************/
29 \page qdeclarativeglobalobject.html
30 \inqmlmodule QtQuick 2
31 \title QML Global Object
33 Contains all the properties of the JavaScript global object, plus:
39 The \l{QmlGlobalQtObject}{Qt object} provides useful enums and functions from Qt, for use in all QML
42 \section1 XMLHttpRequest
44 \target XMLHttpRequest
46 QML script supports the XMLHttpRequest object, which can be used to asynchronously obtain
47 data from over a network.
49 The XMLHttpRequest API implements the same \l {http://www.w3.org/TR/XMLHttpRequest/}{W3C standard}
50 as many popular web browsers with following exceptions:
52 \o QML's XMLHttpRequest does not enforce the same origin policy.
53 \o QML's XMLHttpRequest does not support \i synchronous requests.
56 Additionally, the \c responseXML XML DOM tree currently supported by QML is a reduced subset
57 of the \l {http://www.w3.org/TR/DOM-Level-3-Core/}{DOM Level 3 Core} API supported in a web
58 browser. The following objects and properties are supported by the QML implementation:
66 \o \bold {CharacterData}
112 \o isElementContentWhitespace
118 The \l{declarative/xml/xmlhttprequest}{XMLHttpRequest example} demonstrates how to
119 use the XMLHttpRequest object to make a request and read the response headers.
123 \c console.log(), \c console.debug(), \c console.time(), and \c console.timeEnd() can be used to print information
124 to the console. See \l{Debugging QML} for more information.