Link
class Link
Link Helper
This class should be capable of creating a resource which is modrewrite-capable
Example:
//Open "Singleton-Tunnel" to access all Lib and Helperclasses $XF = XF::instance(); //Initiate and set environment for Link-Helper $linkhelper = $XF->lib->link($default_view = 'newsletter',$default_page = 'default'); $this->infolink = $linkhelper -> print_link(array( "label" => "info", "cmd" => "info" ));
//Example for Breadcrumb Call $history[] = array("label" => "Home", "view" => "default", "page" => "default"); $history[] = array("label" => "Newsletter", "cmd" => "default");
Properties
| $_view | |||
| $_page | |||
| $_cmd | |||
| $_navid | |||
| $_params | |||
| $context | |||
| $context_id | |||
| $context_counter | |||
| $dep_params |
Methods
Link constructor.
No description
Check Header
Decode Special Chars like [/,#=]
Encode Special Chars like [/,#=]
Generate Context Menu (WebComponent)
Return the current Request URI, without access checks Allows to pass custom query Params Filter XELOS a_ params from URL
Returns the current domain name with TLD.
Modify a Request URI, without access checks Allows to pass custom query Params Filter XELOS a_ params from URL
No description
No description
No description
Return Link as Ressource-Array using the parameters of the current page call
No description
No description
No description
Returns the host with protocol and port if is not the default port.
No description
Return Link as Ressource-Array
GET URL
Parse URL and retrieve information
Init Default Vars
Is the given URL considered an external URI? Or internal (absolute with same host or relative URI)
No description
No description
If the passed URL is an internal URL this helper returns a relative URL. Otherwise the full url is returned
Display Context Links
Print current full HTML Link
Print current URL Link
Print full HTML Link
Print URL Link
No description
Callback used by replace_link_vars
Sets the proxy parameters for a cURL resource if they are set in the config custom.
GPVars that should be overwiritten, when building links from GPVars
Declare Default Settings
No description
Details
at line 76
__construct(string $view = "undefined", string $page = "undefined", string $cmd = "undefined", bool $navid = false)
Link constructor.
at line 409
cb_clean_arguments(string $value, string $key, array $exclude)
No description
at line 1472
int
check_header(mixed $curl_session, string $header_data)
Check Header
at line 1190
decode_special_chars(string $link_param, $decode_hash = true)
Decode Special Chars like [/,#=]
at line 1176
mixed
encode_link_param(string $link_param, bool $encode_hash = false)
Encode Special Chars like [/,#=]
at line 790
string
getContextMenu(MenuList $menuList, MenuOptions|null $menuOptions = null)
Generate Context Menu (WebComponent)
at line 1527
string
getCurrentRequestURI(array $queryParams = [])
Return the current Request URI, without access checks Allows to pass custom query Params Filter XELOS a_ params from URL
Main Purpose for this function is to act for redirects when user is not logged in yet (e.g. for API or Auth Calls)
at line 1103
string
getDomain()
Returns the current domain name with TLD.
For example "xelos.net"
at line 1543
string
getModifiedRequestURI(string $uri, array $queryParams = [])
Modify a Request URI, without access checks Allows to pass custom query Params Filter XELOS a_ params from URL
Main Purpose for this function is to act for redirects when user is not logged in yet (e.g. for API or Auth Calls)
at line 1162
int
get_context_counter()
No description
at line 1144
string
get_context_hidden_field()
No description
at line 1153
string
get_context_id()
No description
at line 342
array
get_current_link(array $args = array(), array $options = array(), string $location = 'GET')
Return Link as Ressource-Array using the parameters of the current page call
at line 259
string
get_current_url(array $args = array())
No description
at line 173
get_defaults()
No description
at line 1115
array
get_filtered_GPvars(array $GPvars, string $link_identifier)
No description
at line 1078
string
get_host()
Returns the host with protocol and port if is not the default port.
at line 1207
get_internal_url_info($url)
No description
at line 432
array
get_link(array $args = array())
Return Link as Ressource-Array
at line 248
string
get_url(array $args = array())
GET URL
at line 1274
array|false
get_url_info(string $url)
Parse URL and retrieve information
at line 112
init($reset_params = true)
Init Default Vars
at line 1568
bool
isExternalURI(string $uri)
Is the given URL considered an external URI? Or internal (absolute with same host or relative URI)
at line 974
bool
is_request_authentic()
No description
at line 966
bool
is_request_secure()
No description
at line 1582
string
makeInternalURIRelative(string $uri)
If the passed URL is an internal URL this helper returns a relative URL. Otherwise the full url is returned
at line 834
string
print_context_menu(array $params, array $context_links, bool $current_link = false, bool $no_js_fallback = true, bool $onMouseOver = false)
deprecated
deprecated
Display Context Links
at line 270
string
print_current_link(array $args = array(), $options = array(), $location = 'GET')
Print current full HTML Link
at line 282
string
print_current_url(array $args = array(), $options = array(), $location = 'GET')
Print current URL Link
at line 224
string
print_link(array $args = array())
Print full HTML Link
at line 235
string
print_url(array $args = array())
Print URL Link
at line 295
array
replace_link_vars(array $link_array, array $variables)
No description
at line 327
replace_link_vars_cb($match)
Callback used by replace_link_vars
at line 1487
setCurlProxyOptions(CurlHandle|resource $curlResource)
Sets the proxy parameters for a cURL resource if they are set in the config custom.
at line 1601
void
setOverwriteGPVars(array $GPVars)
GPVars that should be overwiritten, when building links from GPVars
at line 160
void
set_defaults(string $view = null, string $page = null, string|array $cmd = null)
Declare Default Settings
at line 186
void
set_instance_context(string $id, bool $context = false)
No description