Internet shortcut
An internet shortcut is the small text file Windows creates for a web link (a .url file), with a line URL=<address>. A document with the Internet Shortcut schema answers a request on a published site with a permanent redirect (HTTP 301) to that address.
The schema
Property | Value |
|---|---|
Schema name |
|
Comes with | The File storage package. See Standard packages. |
Mapped extension |
|
Fields |
|
Editor | A heading with the name and one text box with the content. |
Unlike Uploaded file and Uploaded image, Internet Shortcut is not a platform schema. In a workspace without the File storage package (or a schema of its own with this name), a .url file does not get it, and no redirect happens.
File format
[InternetShortcut]
URL=https://booking.example.com/ Docly splits Content on the text URL= and redirects to everything after it, with the line breaks at the end removed. That gives three rules:
Put the
URL=line last. Anything on the lines after it becomes part of the address.URL=must occur exactly once. Without it — a bare address typed into the editor, for example — or with it twice, the document is not redirected.The address can be absolute or relative. An absolute address (
https://…) is used as it is. A relative one is resolved against the site's own address, the way a link on the page would be:/bookinggoes to/bookingon the site's domain, andbooking(no leading slash) tobookingunder the site's root. On a site published under a path, such asexample.com/shop/,/bookingtherefore leaves the site; writebookingto stay inside it.
Create one
Upload a
.urlfile into the folder — dragging a link from the browser to the Windows desktop creates one.From the folder's New menu, choose Internet Shortcut and type the content in the format above.
With the docly CLI:
docly put "<folder path>/booking.url" booking.url --create.
A user without developer access can only add it where the folder accepts the schema.
How it is served
Request the document at its path on the published site, for example https://example.com/go/booking.url. Docly answers 301 Moved Permanently with Location: https://booking.example.com/. The redirect is decided when the document itself is served, so the site's router and access rules run first, as for any other page.
A 301 is permanent: browsers and search engines may remember it. Use it for addresses that will not change, such as a short link to a booking system.
Other ways to redirect
Need | Use |
|---|---|
A moved page inside the site, permanently (301), relative target allowed | A |
A temporary or conditional redirect (302) |
|
A short link, to another site or to a page on this one (301) | An Internet Shortcut document |