0 of 1 found this page helpful

Uri.Parts

    Table of contents
    1. 1. Usage Restrictions
    2. 2. Parameters
    3. 3. Result
    4. 4. Samples
    Uri.Parts(uri : str) : map

    Decompose a URI into its component parts. (Obsoletes uri.parse)

    Usage Restrictions

    9.02 or later.

    Parameters

    Name Type Description
    uri str uri to decompose

    Result

    A map of the component parts of the uri

    Samples

       Output

    Get the components of a uri:

    {{uri.Parts("http://user:pass@foo:1234/a/b/c?x=y#baz")}} 

    { fragment : "baz", host : "foo:1234", password : "pass", path : [ "a", "b", "c" ], query : { x : "y" }, scheme : "http", user : "user" }

    Get the path as an array:

    {{uri.Parts("http://foo/a/b/c").path}} 

    [ "a", "b", "c" ]

     

    Was this page helpful?
    Tag page
    Viewing 1 of 1 comments: view all
    example is broken
    Posted 19:51, 9 Nov 2010
    Viewing 1 of 1 comments: view all
    You must login to post a comment.

    Copyright © 2011 MindTouch, Inc. Powered by