| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886 |
- <?xml version="1.0" encoding="iso-8859-1"?>
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <!-- template designed by Marco Von Ballmoos -->
- <title>Docs For Class SloodleRequest</title>
- <link rel="stylesheet" href="../media/stylesheet.css" />
- <script src="../media/lib/classTree.js"></script>
- <script language="javascript" type="text/javascript">
- var imgPlus = new Image();
- var imgMinus = new Image();
- imgPlus.src = "../media/images/plus.png";
- imgMinus.src = "../media/images/minus.png";
-
- function showNode(Node){
- switch(navigator.family){
- case 'nn4':
- // Nav 4.x code fork...
- var oTable = document.layers["span" + Node];
- var oImg = document.layers["img" + Node];
- break;
- case 'ie4':
- // IE 4/5 code fork...
- var oTable = document.all["span" + Node];
- var oImg = document.all["img" + Node];
- break;
- case 'gecko':
- // Standards Compliant code fork...
- var oTable = document.getElementById("span" + Node);
- var oImg = document.getElementById("img" + Node);
- break;
- }
- oImg.src = imgMinus.src;
- oTable.style.display = "block";
- }
-
- function hideNode(Node){
- switch(navigator.family){
- case 'nn4':
- // Nav 4.x code fork...
- var oTable = document.layers["span" + Node];
- var oImg = document.layers["img" + Node];
- break;
- case 'ie4':
- // IE 4/5 code fork...
- var oTable = document.all["span" + Node];
- var oImg = document.all["img" + Node];
- break;
- case 'gecko':
- // Standards Compliant code fork...
- var oTable = document.getElementById("span" + Node);
- var oImg = document.getElementById("img" + Node);
- break;
- }
- oImg.src = imgPlus.src;
- oTable.style.display = "none";
- }
-
- function nodeIsVisible(Node){
- switch(navigator.family){
- case 'nn4':
- // Nav 4.x code fork...
- var oTable = document.layers["span" + Node];
- break;
- case 'ie4':
- // IE 4/5 code fork...
- var oTable = document.all["span" + Node];
- break;
- case 'gecko':
- // Standards Compliant code fork...
- var oTable = document.getElementById("span" + Node);
- break;
- }
- return (oTable && oTable.style.display == "block");
- }
-
- function toggleNodeVisibility(Node){
- if (nodeIsVisible(Node)){
- hideNode(Node);
- }else{
- showNode(Node);
- }
- }
- </script>
- </head>
- <body>
- <div class="page-body">
- <h2 class="class-name"><img src="../media/images/Class_logo.png"
- alt=" Class"
- title=" Class"
- style="vertical-align: middle"> SloodleRequest</h2>
- <a name="sec-description"></a>
- <div class="info-box">
- <div class="info-box-title">Description</div>
- <div class="nav-bar">
- <span class="disabled">Description</span> |
- <a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
- | <a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
-
- </div>
- <div class="info-box-body">
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Handles incoming HTTP requests, typically from LSL if dealing with Second Life.</p>
- <p class="description"><p>This class will perform much of the complex and repetitive processing required for handling HTTP requests.</p></p>
- <ul class="tags">
- <li><span class="field">uses:</span> <a href="../sloodle/SloodleUser.html">SloodleUser</a> - Stores and processes user data incoming from an HTTP request</li>
- <li><span class="field">uses:</span> <a href="../sloodle/SloodleResponse.html">SloodleResponse</a> - Outputs error messages in appropriate format if an error occurs.</li>
- </ul>
- <p class="notes">
- Located in <a class="field" href="_sloodle---lib---io.php.html">/sloodle/lib/io.php</a> (line <span class="field"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a768">768</a></span>)
- </p>
-
-
- <pre></pre>
-
- </div>
- </div>
- <a name="sec-var-summary"></a>
- <div class="info-box">
- <div class="info-box-title">Variable Summary</span></div>
- <div class="nav-bar">
- <a href="#sec-description">Description</a> |
- <span class="disabled">Vars</span> (<a href="#sec-vars">details</a>)
- |
- <a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
-
- </div>
- <div class="info-box-body">
- <div class="var-summary">
- <div class="var-title">
- <img src="../media/images/PrivateVariable.png" alt=" " />
- <span class="var-type">bool</span>
- <a href="#$request_data_processed" title="details" class="var-name">$request_data_processed</a>
- </div>
- <div class="var-title">
- <img src="../media/images/Variable.png" alt=" " />
- <span class="var-type">object</span>
- <a href="#$_session" title="details" class="var-name">$_session</a>
- </div>
- </div>
- </div>
- </div>
- <a name="sec-method-summary"></a>
- <div class="info-box">
- <div class="info-box-title">Method Summary</span></div>
- <div class="nav-bar">
- <a href="#sec-description">Description</a> |
- <a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
-
- |
- <span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
- </div>
- <div class="info-box-body">
- <div class="method-summary">
-
- <div class="method-definition">
- <img src="../media/images/Constructor.png" alt=" "/>
- <span class="method-result">SloodleRequest</span>
- <a href="#SloodleRequest" title="details" class="method-name">SloodleRequest</a>
- (<span class="var-type"></span> <span class="var-name">&$_session</span>, <span class="var-type"><a href="../sloodle/SloodleUser.html">SloodleUser</a></span> <span class="var-name">$_session</span>)
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">string|null</span>
- <a href="#get_avatar_name" title="details" class="method-name">get_avatar_name</a>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">string|null</span>
- <a href="#get_avatar_uuid" title="details" class="method-name">get_avatar_uuid</a>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">int|null</span>
- <a href="#get_controller_id" title="details" class="method-name">get_controller_id</a>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">int|null</span>
- <a href="#get_course_id" title="details" class="method-name">get_course_id</a>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">object A</span>
- <a href="#get_course_module_instance" title="details" class="method-name">get_course_module_instance</a>
- ([<span class="var-type">string</span> <span class="var-name">$type</span> = <span class="var-default">''</span>], [<span class="var-type">bool</span> <span class="var-name">$require</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">object A</span>
- <a href="#get_course_record" title="details" class="method-name">get_course_record</a>
- ([<span class="var-type">bool</span> <span class="var-name">$require</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">int|null</span>
- <a href="#get_module_id" title="details" class="method-name">get_module_id</a>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">string|mixed</span>
- <a href="#get_param" title="details" class="method-name">get_param</a>
- (<span class="var-type">string</span> <span class="var-name">$parname</span>, <span class="var-type">bool</span> <span class="var-name">$required</span>, [<span class="var-type">mixed</span> <span class="var-name">$default</span> = <span class="var-default">null</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">string|null</span>
- <a href="#get_password" title="details" class="method-name">get_password</a>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">string|null</span>
- <a href="#get_request_descriptor" title="details" class="method-name">get_request_descriptor</a>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">string|null</span>
- <a href="#get_server_access_level" title="details" class="method-name">get_server_access_level</a>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">bool</span>
- <a href="#is_object_request" title="details" class="method-name">is_object_request</a>
- ()
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">bool</span>
- <a href="#is_request_data_processed" title="details" class="method-name">is_request_data_processed</a>
- ()
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">string|mixed</span>
- <a href="#optional_param" title="details" class="method-name">optional_param</a>
- (<span class="var-type">string</span> <span class="var-name">$parname</span>, [<span class="var-type">mixed</span> <span class="var-name">$default</span> = <span class="var-default">null</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">bool</span>
- <a href="#process_request_data" title="details" class="method-name">process_request_data</a>
- ([<span class="var-type">bool</span> <span class="var-name">$require_auth</span> = <span class="var-default">true</span>], [<span class="var-type">bool</span> <span class="var-name">$require_user</span> = <span class="var-default">true</span>])
- </div>
-
- <div class="method-definition">
- <img src="../media/images/Method.png" alt=" "/>
- <span class="method-result">string</span>
- <a href="#required_param" title="details" class="method-name">required_param</a>
- (<span class="var-type">string</span> <span class="var-name">$parname</span>)
- </div>
- </div>
- </div>
- </div>
- <a name="sec-vars"></a>
- <div class="info-box">
- <div class="info-box-title">Variables</div>
- <div class="nav-bar">
- <a href="#sec-description">Description</a> |
- <a href="#sec-var-summary">Vars</a> (<span class="disabled">details</span>)
-
-
- |
- <a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
-
- </div>
- <div class="info-box-body">
-
- <a name="var$request_data_processed" id="$request_data_processed"><!-- --></A>
- <div class="oddrow">
- <div class="var-header">
- <img src="../media/images/PrivateVariable.png" />
- <span class="var-title">
- <span class="var-type">bool</span>
- <span class="var-name">$request_data_processed</span>
- = <span class="var-default"> false</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a788">788</a></span>)
- </span>
- </div>
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Indicates whether or not the basic request data has already been processed.</p>
- <p class="description"><p>This is used to ensure data is processed.</p></p>
- <ul class="tags">
- <li><span class="field">access:</span> private</li>
- </ul>
-
-
-
-
- </div>
- <a name="var$_session" id="$_session"><!-- --></A>
- <div class="evenrow">
- <div class="var-header">
- <img src="../media/images/Variable.png" />
- <span class="var-title">
- <span class="var-type">object</span>
- <span class="var-name">$_session</span>
- = <span class="var-default"> null</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a780">780</a></span>)
- </span>
- </div>
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Reference to the containing <a href="../sloodle/SloodleSession.html">SloodleSession</a> object.</p>
- <p class="description"><p>If null, then this module is being used outwith the framework. <strong>Always check the status of the variable before using it!</strong> Note: if not provided, then this object will not render any response information.</p></p>
- <ul class="tags">
- <li><span class="field">access:</span> protected</li>
- </ul>
-
-
-
-
- </div>
-
- </div>
- </div>
-
- <a name="sec-methods"></a>
- <div class="info-box">
- <div class="info-box-title">Methods</div>
- <div class="nav-bar">
- <a href="#sec-description">Description</a> |
- <a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
- <a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
-
- </div>
- <div class="info-box-body">
- <A NAME='method_detail'></A>
- <a name="methodSloodleRequest" id="SloodleRequest"><!-- --></a>
- <div class="oddrow">
-
- <div class="method-header">
- <img src="../media/images/Constructor.png" />
- <span class="method-title">Constructor SloodleRequest</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a902">902</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description"><em>Constructor</em><ul><li>initialises the <a href="../sloodle/SloodleSession.html">SloodleSession</a> object.</li></ul></p>
- <p class="description"><p>If the session parameter is null, then this object simply does not render response information.</p></p>
-
- <div class="method-signature">
- <span class="method-result">SloodleRequest</span>
- <span class="method-name">
- SloodleRequest
- </span>
- (<span class="var-type"></span> <span class="var-name">&$_session</span>, <span class="var-type"><a href="../sloodle/SloodleUser.html">SloodleUser</a></span> <span class="var-name">$_session</span>)
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type"><a href="../sloodle/SloodleUser.html">SloodleUser</a></span>
- <span class="var-name">$_session</span><span class="var-description">: A reference to the <a href="../sloodle/SloodleSession.html">SloodleSession</a> object which this request should use, or null</span> </li>
- <li>
- <span class="var-type"></span>
- <span class="var-name">&$_session</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_avatar_name" id="get_avatar_name"><!-- --></a>
- <div class="evenrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_avatar_name</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a857">857</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Fetches the avatar name request parameter.</p>
- <ul class="tags">
- <li><span class="field">return:</span> The avatar name provided in the request parameters, or null if there wasn't one</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">string|null</span>
- <span class="method-name">
- get_avatar_name
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$required</span><span class="var-description">: If true (default) then the function will terminate the script with an error message if the HTTP request parameter was not specified.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_avatar_uuid" id="get_avatar_uuid"><!-- --></a>
- <div class="oddrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_avatar_uuid</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a847">847</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Fetches the avatar UUID request parameter.</p>
- <ul class="tags">
- <li><span class="field">return:</span> The avatar UUID provided in the request parameters, or null if there wasn't one</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">string|null</span>
- <span class="method-name">
- get_avatar_uuid
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$required</span><span class="var-description">: If true (default) then the function will terminate the script with an error message if the HTTP request parameter was not specified.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_controller_id" id="get_controller_id"><!-- --></a>
- <div class="evenrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_controller_id</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a827">827</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Fetches the controller ID request parameter.</p>
- <ul class="tags">
- <li><span class="field">return:</span> The controller ID provided in the request parameters, or null if there wasn't one</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">int|null</span>
- <span class="method-name">
- get_controller_id
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$required</span><span class="var-description">: If true (default) then the function will terminate the script with an error message if the HTTP request parameter was not specified.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_course_id" id="get_course_id"><!-- --></a>
- <div class="oddrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_course_id</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a817">817</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Fetches the course ID request parameter.</p>
- <ul class="tags">
- <li><span class="field">return:</span> The course ID provided in the request parameters, or null if there wasn't one</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">int|null</span>
- <span class="method-name">
- get_course_id
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$required</span><span class="var-description">: If true (default) then the function will terminate the script with an error message if the HTTP request parameter was not specified.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_course_module_instance" id="get_course_module_instance"><!-- --></a>
- <div class="evenrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_course_module_instance</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a1023">1023</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Get a course module instance for the module specified in the request Uses the ID specified in $module_id.</p>
- <ul class="tags">
- <li><span class="field">return:</span> database record if successful, or false if not (e.g. if instance is not found, is not visible, or is not of the correct type)</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">object A</span>
- <span class="method-name">
- get_course_module_instance
- </span>
- ([<span class="var-type">string</span> <span class="var-name">$type</span> = <span class="var-default">''</span>], [<span class="var-type">bool</span> <span class="var-name">$require</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">string</span>
- <span class="var-name">$type</span><span class="var-description">: specifies the name of the module type (e.g. 'forum', 'choice' etc.) - ignored if blank (default).</span> </li>
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$require</span><span class="var-description">: If true, the function will NOT return failure. Rather, it will terminate the script with an error message.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_course_record" id="get_course_record"><!-- --></a>
- <div class="oddrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_course_record</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a967">967</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Gets a database record for the course identified in the request.</p>
- <p class="description"><p>(Note: this function does not check whether or not the user is enrolled in the course)</p></p>
- <ul class="tags">
- <li><span class="field">return:</span> record directly from the database, or null if the course is not found.</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">object A</span>
- <span class="method-name">
- get_course_record
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$require</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$require</span><span class="var-description">: If true, the function will NOT return failure. Rather, it will terminate the script with an error message.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_module_id" id="get_module_id"><!-- --></a>
- <div class="evenrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_module_id</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a837">837</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Fetches the module ID request parameter.</p>
- <ul class="tags">
- <li><span class="field">return:</span> The module ID provided in the request parameters, or null if there wasn't one</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">int|null</span>
- <span class="method-name">
- get_module_id
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$required</span><span class="var-description">: If true (default) then the function will terminate the script with an error message if the HTTP request parameter was not specified.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_param" id="get_param"><!-- --></a>
- <div class="oddrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_param</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a1131">1131</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Obtains a named HTTP request parameter, optionally requiring it or not</p>
- <ul class="tags">
- <li><span class="field">return:</span> The raw value of the HTTP parameter if found, or the value of parameter $default if it was not found and parameter $require was false</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">string|mixed</span>
- <span class="method-name">
- get_param
- </span>
- (<span class="var-type">string</span> <span class="var-name">$parname</span>, <span class="var-type">bool</span> <span class="var-name">$required</span>, [<span class="var-type">mixed</span> <span class="var-name">$default</span> = <span class="var-default">null</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">string</span>
- <span class="var-name">$parname</span><span class="var-description">: The name of the parameter to get</span> </li>
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$required</span><span class="var-description">: Indicates whether or not to 'require' the parameter (if it is required, but cannot be found, then the script is terminated with an error message)</span> </li>
- <li>
- <span class="var-type">mixed</span>
- <span class="var-name">$default</span><span class="var-description">: If the $require parameter is false, and the HTTP parameter cannot be found, then this value will be returned instead</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_password" id="get_password"><!-- --></a>
- <div class="evenrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_password</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a807">807</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Fetches the password request parameter.</p>
- <ul class="tags">
- <li><span class="field">return:</span> The password provided in the request parameters, or null if there wasn't one</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">string|null</span>
- <span class="method-name">
- get_password
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$required</span><span class="var-description">: If true (default) then the function will terminate the script with an error message if the HTTP request parameter was not specified.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_request_descriptor" id="get_request_descriptor"><!-- --></a>
- <div class="oddrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_request_descriptor</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a867">867</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Fetches the request descriptor request parameter.</p>
- <ul class="tags">
- <li><span class="field">return:</span> The request descriptor provided in the request parameters, or null if there wasn't one</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">string|null</span>
- <span class="method-name">
- get_request_descriptor
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$required</span><span class="var-description">: If true (default) then the function will terminate the script with an error message if the HTTP request parameter was not specified.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodget_server_access_level" id="get_server_access_level"><!-- --></a>
- <div class="evenrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">get_server_access_level</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a888">888</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Fetches the server access level parameter, if specified.</p>
- <ul class="tags">
- <li><span class="field">return:</span> The server access level provided in the request parameters, or null if there wasn't one</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">string|null</span>
- <span class="method-name">
- get_server_access_level
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$required</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$required</span><span class="var-description">: If true (default) then the function will terminate the script with an error message if the HTTP request parameter was not specified.</span> </li>
- </ul>
-
-
- </div>
- <a name="methodis_object_request" id="is_object_request"><!-- --></a>
- <div class="oddrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">is_object_request</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a876">876</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Checks the parameters to determine if the request relates to an object rather than a user</p>
- <ul class="tags">
- <li><span class="field">return:</span> True if the request seems to have come from an object, or false otherwise.</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">bool</span>
- <span class="method-name">
- is_object_request
- </span>
- ()
- </div>
-
-
-
- </div>
- <a name="methodis_request_data_processed" id="is_request_data_processed"><!-- --></a>
- <div class="evenrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">is_request_data_processed</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a797">797</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Checks whether or not the request data has already been processed.</p>
-
- <div class="method-signature">
- <span class="method-result">bool</span>
- <span class="method-name">
- is_request_data_processed
- </span>
- ()
- </div>
-
-
-
- </div>
- <a name="methodoptional_param" id="optional_param"><!-- --></a>
- <div class="oddrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">optional_param</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a1092">1092</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Obtains a named HTTP request parameter, or NULL if it has not been provided.</p>
- <p class="description"><p>Return values are always strings.</p></p>
- <ul class="tags">
- <li><span class="field">return:</span> The raw parameter value (will be a string if the parameter was found, or the value of parameter $default otherwise)</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">string|mixed</span>
- <span class="method-name">
- optional_param
- </span>
- (<span class="var-type">string</span> <span class="var-name">$parname</span>, [<span class="var-type">mixed</span> <span class="var-name">$default</span> = <span class="var-default">null</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">string</span>
- <span class="var-name">$parname</span><span class="var-description">: The name of the parameter to fetch</span> </li>
- <li>
- <span class="var-type">mixed</span>
- <span class="var-name">$default</span><span class="var-description">: The value to return if the parameter cannot be found</span> </li>
- </ul>
-
-
- </div>
- <a name="methodprocess_request_data" id="process_request_data"><!-- --></a>
- <div class="evenrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">process_request_data</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a916">916</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Process all of the standard data provided by the HTTP request, and write it into our <a href="../sloodle/SloodleSession.html">SloodleSession</a> object.</p>
- <p class="description"><p>Requires that a <a href="../sloodle/SloodleSession.html">SloodleSession</a> object was provided at construction, and is stored in the $_session member. NOTE: this does not load the module part of the session. That must be done separately, using the <a href="../sloodle/SloodleSession.html#methodload_module">SloodleSession::load_module()</a> member function.</p></p>
- <ul class="tags">
- <li><span class="field">return:</span> True if successful, or false otherwise.</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">bool</span>
- <span class="method-name">
- process_request_data
- </span>
- ([<span class="var-type">bool</span> <span class="var-name">$require_auth</span> = <span class="var-default">true</span>], [<span class="var-type">bool</span> <span class="var-name">$require_user</span> = <span class="var-default">true</span>])
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$require_auth</span><span class="var-description">: If true, then the function will terminate the script with an error message if it cannot authenticate the request through a course, controller and password</span> </li>
- <li>
- <span class="var-type">bool</span>
- <span class="var-name">$require_user</span><span class="var-description">: If true, then the function will terminate the script with an error message if a legitimate user was not identified or could not be auto-registered</span> </li>
- </ul>
-
-
- </div>
- <a name="methodrequired_param" id="required_param"><!-- --></a>
- <div class="oddrow">
-
- <div class="method-header">
- <img src="../media/images/Method.png" />
- <span class="method-title">required_param</span> (line <span class="line-number"><a href="../__filesource/fsource_sloodle__sloodlelibio.php.html#a1107">1107</a></span>)
- </div>
-
- <!-- ========== Info from phpDoc block ========= -->
- <p class="short-description">Obtains a named HTTP request parameter, or terminates with an error message if it has not been provided.</p>
- <p class="description"><p>Note: for linker scripts, this should *always* be used instead of the standard Moodle function, as this will render appropriately formatted error messages, which scripts can understand. Also note that this function always returned values in the string type. They must be cast.</p></p>
- <ul class="tags">
- <li><span class="field">return:</span> The raw parameter value</li>
- </ul>
-
- <div class="method-signature">
- <span class="method-result">string</span>
- <span class="method-name">
- required_param
- </span>
- (<span class="var-type">string</span> <span class="var-name">$parname</span>)
- </div>
-
- <ul class="parameters">
- <li>
- <span class="var-type">string</span>
- <span class="var-name">$parname</span><span class="var-description">: The name of the HTTP request parameter to get.</span> </li>
- </ul>
-
-
- </div>
-
- </div>
- </div>
-
- <p class="notes" id="credit">
- Documentation generated on Mon, 16 Jun 2008 15:56:24 +0100 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.4.0</a>
- </p>
- </div></body>
- </html>
|