Search moodle.org's
Developer Documentation

See Release Notes
Long Term Support Release

  • Bug fixes for general core bugs in 4.1.x will end 13 November 2023 (12 months).
  • Bug fixes for security issues in 4.1.x will end 10 November 2025 (36 months).
  • PHP version: minimum PHP 7.4.0 Note: minimum PHP version has increased since Moodle 4.0. PHP 8.0.x is supported too.

Differences Between: [Versions 310 and 401] [Versions 311 and 401] [Versions 39 and 401] [Versions 401 and 402] [Versions 401 and 403]

Web Service functions for steps.

Copyright: 2016 Andrew Nicols <andrew@nicols.co.uk>
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 333 lines (12 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class


Class: tour  - X-Ref

Web Service functions for steps.

fetch_and_start_tour($tourid, $context, $pageurl)   X-Ref
Fetch the tour configuration for the specified tour.

param: int     $tourid     The ID of the tour to fetch.
param: int     $context    The Context ID of the current page.
param: string  $pageurl    The path of the current page.
return: array               As described in fetch_and_start_tour_returns

fetch_and_start_tour_parameters()   X-Ref
The parameters for fetch_and_start_tour.

return: external_function_parameters

fetch_and_start_tour_returns()   X-Ref
The return configuration for fetch_and_start_tour.

return: external_single_structure

reset_tour($tourid, $context, $pageurl)   X-Ref
Reset the specified tour for the current user.

param: int     $tourid     The ID of the tour.
param: int     $context    The Context ID of the current page.
param: string  $pageurl    The path of the current page requesting the reset.
return: array               As described in reset_tour_returns

reset_tour_parameters()   X-Ref
The parameters for reset_tour.

return: external_function_parameters

reset_tour_returns()   X-Ref
The return configuration for reset_tour.

return: external_single_structure

complete_tour($tourid, $context, $pageurl, $stepid, $stepindex)   X-Ref
Mark the specified tour as completed for the current user.

param: int     $tourid     The ID of the tour.
param: int     $context    The Context ID of the current page.
param: string  $pageurl    The path of the current page.
param: int     $stepid     The step id
param: int     $stepindex  The step index
return: array               As described in complete_tour_returns

complete_tour_parameters()   X-Ref
The parameters for complete_tour.

return: external_function_parameters

complete_tour_returns()   X-Ref
The return configuration for complete_tour.

return: external_single_structure

step_shown($tourid, $context, $pageurl, $stepid, $stepindex)   X-Ref
Mark the specified toru step as shown for the current user.

param: int     $tourid     The ID of the tour.
param: int     $context    The Context ID of the current page.
param: string  $pageurl    The path of the current page.
param: int     $stepid     The step id
param: int     $stepindex  The step index
return: array               As described in complete_tour_returns

step_shown_parameters()   X-Ref
The parameters for step_shown.

return: external_function_parameters

step_shown_returns()   X-Ref
The return configuration for step_shown.

return: external_single_structure

step_structure_returns()   X-Ref
The standard return structure for a step.

return: external_multiple_structure