path( )


Gets the path of the current page's URL.

The path for a regular page is after the baseUrl If the page is a dynamic page or router page, the prefix appears after the base URL, before the path.

Premium sites: Path for a regular page, without a prefix: Premium site path Path for a dynamic or router page with a prefix: Premium site path

Free sites: Path for a regular page, without a prefix: Free site path Path for a dynamic or router page with a prefix: Free site path

Method Declaration
Copy
Request
This method does not take any parameters
Returns
Return Type:Promise<Array<string>>
Get the path of the current page's URL
JavaScript
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?