Loading...
 
Skip to main content

History: PluginAJAXLoad

Source of version: 1

Copy to clipboard
            Introduced in Tiki 14.1

Can be used to load HTML into a wiki page, from another page on the same site or an external site (when used in combination with the access_control_allow_origin pref on Admin -> General -> Settings). If JavaScript is disabled on the client browser the data will be put in an IFRAME.

{FANCYTABLE( head=> __Parameter__ ~|~ __Accepted values__ ~|~ __Default__ ~|~ __Effect__ ~|~ __Required?__ ~|~ __Since__ )}
''URL'' ~|~ A URL  ~|~  ~|~ URL of the page to load ~|~ y ~|~ 
''Selector'' ~|~ A jQuery selector ~|~ ~|~ Selector to extract part of the page only, e.g. "#page-data" ~|~ n ~|~ 
''Target'' ~|~ A jQuery selector ~|~ ~|~ Where the HTML should be displayed. Will create it's own DIV if not supplied ~|~ n ~|~ 
''Id'' ~|~ DOM Id ~|~ ~|~ Id for the DIV or IFRAME ~|~ n ~|~ 
''Class'' ~|~ CSS Class ~|~ ~|~ Class for the DIV or IFRAME ~|~ n ~|~ 
''Width'' ~|~ Pixels or percentage ~|~ ~|~ Width for the DIV or IFRAME ~|~ n ~|~ 
''Height'' ~|~ Pixels or percentage ~|~ ~|~ Height for the DIV or IFRAME ~|~ n ~|~ 
''BODY (between the AJAXLOAD tags)'' ~|~ JavaScript ~|~ ~|~ JavaScript to run when the data is loaded, the incoming HTML is in a variable called data. You can modify that variable's contents to customise the HTML ~|~ n ~|~ 
{FANCYTABLE}

Example of JavaScript for the BODY
{CODE(color="javascript")}alert(data.length + " bytes of data received");{CODE}

        

History

Advanced
Information Version
Rodriguez Nyiringabo Improve the doc 15
Rodriguez Nyiringabo Remove the doc related to the javascript pref as no modern site runs without javascript. 14
Josue Zirimwabagabo 13
Benoit Grégoire 12
Jonny Bradley 11
Jonny Bradley 10
Jonny Bradley 9
Jonny Bradley added menu example 8
lindon 7
lindon 6
lindon 5
lindon 4
lindon 3
Jonny Bradley 2
Jonny Bradley 1