mirror of
https://github.com/nextcloud/documentation.git
synced 2025-10-26 11:18:02 +00:00
added docs for abs_url
This commit is contained in:
parent
d1c68c32ee
commit
ae2b9e1cc2
@ -88,6 +88,20 @@ The App Framework comes with additional template functions for Twig to better in
|
||||
{{ url('apptemplate_advanced_params', {value: 'hi'}) }}
|
||||
|
||||
|
||||
.. js:function:: abs_url(route, params=null)
|
||||
|
||||
:param string route: the name of the route
|
||||
:param string params: the params written like a JavaScript object
|
||||
|
||||
Same as :js:func:`url` but prints an absolute URL
|
||||
|
||||
An example would be:
|
||||
|
||||
.. code-block:: js
|
||||
|
||||
{{ abs_url('apptemplate_advanced_params', {value: 'hi'}) }}
|
||||
|
||||
|
||||
.. js:function:: t(toTranslate, params=null)
|
||||
|
||||
:param string toTranslate: the string which should be translated
|
||||
|
||||
@ -151,6 +151,15 @@ class and add your methods
|
||||
Returns the URL for a route
|
||||
|
||||
|
||||
.. php:method:: getAbsoluteURL($url)
|
||||
|
||||
:param string $url: the url
|
||||
:returns string: the absolute url
|
||||
|
||||
|
||||
Makes an URL absolute
|
||||
|
||||
|
||||
.. php:method:: linkToAbsolute($file, $appName=null)
|
||||
|
||||
:param string $file: the name of the file
|
||||
|
||||
@ -14,4 +14,5 @@ row
|
||||
|
||||
.. php:method:: __construct($msg)
|
||||
|
||||
:param mixed $msg:
|
||||
:param mixed $msg:
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user