attachments::get_attachments_url (private)

 attachments::get_attachments_url [ -base_url base_url ]

Defined in packages/attachments/tcl/attachments-procs.tcl

As 'attachments::get_url' returns the value of the attachments package 'RelativeUrl' parameter, which can change at any time, it could happen that previously mounted attachments have a different url and are not found anymore. We try our best here to find a mounted attachments package under 'base_url' to mitigate this, probably flawed, package logic. In the future, probably a better method should be used for URL resolving that is not so broken. The whole thing is even more weird, as the attachments package is currently a singleton that auto-mounts on /attachments, so i am tempted to replace this whole thing with just that, but anyway...

Switches:
-base_url (optional)
The base URL where to look for the attachments package.
Returns:
The attachments package URL under 'base_url', or "" if none is found.
See Also:

Testcases:
attachments_url_api
[ show source ]
Show another procedure: