mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
Needed to have a nice structured cookbook dir in the docs Includes: Move the data-module tests under the data dir Move the frame tests under the ui dir Rename the dialog.md file to dialogs.md Fix the web-view title Add previous_url attributes to each article for SEO Rename the style dir to styling to match the reference Fix the frame-tests path
37 lines
867 B
Markdown
37 lines
867 B
Markdown
---
|
|
nav-title: "http How-To"
|
|
title: "http"
|
|
description: "Examples for using http"
|
|
previous_url: /ApiReference/http/HOW-TO
|
|
---
|
|
# Http module
|
|
Using http methods requires to load "http" module.
|
|
<snippet id='http-require'/>
|
|
|
|
### Get string from URL
|
|
<snippet id='http-get-string'/>
|
|
|
|
### Get JSON from URL
|
|
<snippet id='http-get-json'/>
|
|
|
|
### Get Image from URL
|
|
<snippet id='http-get-image'/>
|
|
|
|
### Get File from URL. By default the file will be saved in Documents folder.
|
|
<snippet id='http-get-urlfile'/>
|
|
|
|
### Get content as File from URL. You can specify where the file should be saved.
|
|
<snippet id='http-get-urlfile-content'/>
|
|
|
|
### Get response status code
|
|
<snippet id='http-get-response'/>
|
|
|
|
### Get response headers
|
|
<snippet id='http-get-response-headers'/>
|
|
|
|
### Get response content
|
|
<snippet id='http-get-response-content'/>
|
|
|
|
### Post JSON
|
|
<snippet id='http-post-json'/>
|