Log of /moodle/lib/pagelib.php
Parent Directory
Revision
1.173 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Feb 11 21:27:03 2010 WST (5 weeks, 1 day ago) by
skodak
Branch:
MAIN
CVS Tags:
HEAD
Changes since
1.172: +1 -1 lines
Diff to
previous 1.172
MDL-20204 the ultimate fix for our frames (theyare not accessbile, but anyway); instead of adding the target to each element when creating html we use yui to set the target from page footer via JS - this fixes the links and forms in all elements in pages with frametop layout
Revision
1.172 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jan 28 11:19:21 2010 WST (7 weeks, 1 day ago) by
samhemelryk
Branch:
MAIN
Changes since
1.171: +45 -8 lines
Diff to
previous 1.171
NOBUG: Updated the docs for the moodle_page class to cover the magic get functions
Revision
1.171 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sun Jan 17 17:50:56 2010 WST (2 months ago) by
skodak
Branch:
MAIN
Changes since
1.170: +2 -2 lines
Diff to
previous 1.170
MDL-21233 escaped parameter is far more importatnt than the overrideparams in out() method - especially all JS urls should be converted to out(false); also it is possible to create new url with overrided parameters in constructor which might be actually work around the double encoding problems in the url (we should never use the out() in moodle_url constructor itself!)
Revision
1.170 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sun Jan 17 17:37:30 2010 WST (2 months ago) by
skodak
Branch:
MAIN
Changes since
1.169: +1 -1 lines
Diff to
previous 1.169
MDL-21233 finally removed the omitquerystring parameters from the out method because: 1/ the least used parameter should nto be first, 2/ it is colliding with the other two paramters, now we have separate funtion for that instead
Revision
1.167 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jan 8 04:17:38 2010 WST (2 months, 1 week ago) by
mudrd8mz
Branch:
MAIN
Changes since
1.166: +4 -1 lines
Diff to
previous 1.166
Fixed a typo in loginas.php + added a parameter control in moodle_url::set_url() to discover similar issues in the future
Revision
1.165 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sun Dec 27 20:02:05 2009 WST (2 months, 3 weeks ago) by
skodak
Branch:
MAIN
Changes since
1.164: +5 -3 lines
Diff to
previous 1.164
MDL-20790 more page layouts -see base theme for full list; also added new css body class for describing current layout; base layout is now default for beter BC; require_login() now sets 'incourse' layout automatically
Revision
1.162 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Dec 23 10:45:23 2009 WST (2 months, 3 weeks ago) by
samhemelryk
Branch:
MAIN
Changes since
1.161: +1 -1 lines
Diff to
previous 1.161
question MDL-21169 removed update_module_button calls from question these are now added by the module extending the navigation if there is a module specified for question pages.
Also fixed bug in moodle_url object coding_error to coding_exception
Revision
1.161 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Dec 18 06:43:27 2009 WST (3 months ago) by
skodak
Branch:
MAIN
Changes since
1.160: +3 -2 lines
Diff to
previous 1.160
MDL-21148 geenral support for rendering targets, this should give us more flexibility; please propose improvements in the tracker if necessary, thanks
Revision
1.158 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Dec 17 21:45:55 2009 WST (3 months ago) by
skodak
Branch:
MAIN
Changes since
1.157: +11 -1 lines
Diff to
previous 1.157
MDL-21143 theme renderers related refactoring, it should detect more problems now, there is also a list of core renderer subtypes, hopefully the api changes are improvements
Revision
1.156 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Dec 17 02:01:11 2009 WST (3 months ago) by
skodak
Branch:
MAIN
Changes since
1.155: +30 -34 lines
Diff to
previous 1.155
MDL-20204 first batch of major theme changes, some regressions are still there, expect more changes and improvements soon; see tracker for details and list of subtasks
Revision
1.153 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Sep 23 14:05:36 2009 WST (5 months, 3 weeks ago) by
samhemelryk
Branch:
MAIN
Changes since
1.152: +4 -0 lines
Diff to
previous 1.152
navigation MDL-20332 MDL-20324 Modifications to fix the following issues:
* If no active node is found when the navigation is called upon then we attempt to find a best match active node
* Links are now produced with frame breakout actions
* Links ending with / are presumed index.php for matching purposes
Revision
1.152 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sun Sep 6 01:32:10 2009 WST (6 months, 1 week ago) by
mudrd8mz
Branch:
MAIN
Changes since
1.151: +1 -1 lines
Diff to
previous 1.151
NOBUG: Fixed bug in $PAGE->set_url() when moodle_url passed
When moodle_url was passed as a param to set_url(), the str_replace() kept
the leading '/' in the $shorturl. This then led to the <body> classes
like '-mod-workshop' instead of correct 'mod-workshop' (the slash
replaced with minus sign).
Revision
1.147 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Aug 28 16:47:31 2009 WST (6 months, 3 weeks ago) by
samhemelryk
Branch:
MAIN
Changes since
1.146: +40 -0 lines
Diff to
previous 1.146
navigation MDL-14632 Very significant navigation commit
This patch introduces two new blocks global_navigation_tree and settings_navigation_tree
both of which have been designed to make full use of the new navigation objects available through
the $PAGE object.
Bulk of this code is within lib/navigationlib.php
Revision
1.146 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jul 30 00:38:40 2009 WST (7 months, 2 weeks ago) by
mudrd8mz
Branch:
MAIN
Changes since
1.145: +1 -1 lines
Diff to
previous 1.145
MDL-19956 $PAGE->set_url(...) passes the same arguments to the legacy page object
Credit goes to Tim Hunt, thanks for explaining this to me.
Revision
1.143 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Jul 21 21:58:47 2009 WST (7 months, 4 weeks ago) by
tjhunt
Branch:
MAIN
Changes since
1.142: +7 -2 lines
Diff to
previous 1.142
Fix new install with developer debug on.
Can't print context name in the page footer before DB tables exist!
Also, show page generaltype in the footer.
Revision
1.135 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jul 9 15:35:06 2009 WST (8 months, 1 week ago) by
tjhunt
Branch:
MAIN
Changes since
1.134: +7 -4 lines
Diff to
previous 1.134
themes & blocks - MDL-19077 & MDL-19010 blocks are now printed by the theme
The code to print blocks in now in theme layout.php files. (Or in
moodle_core_renderer::handle_legacy_theme)
Code for printing blocks everywhere else has been stripped out.
(Total diffstat 1225 insertions, 2019 deletions)
The way the HTML for a block instance is generated has been cleaned
up a lot. Now, the block_instance generates a block_contents
object which gives a structured representation of the block,
and then $OUTPUT->block builds all the HTML from that.
How theme config.php files specify the layout template and block
regions by page general type has been changed to be even more flexible.
Further refinement for how the theme and block code gets initialised.
Ability for scrits to add 'pretend blocks' to the page. That is,
things that look like blocks, but are not normal block_instances.
(Like the add a new block UI.)
Things that are still broken:
* some pages in lesson, quiz and resource. I'm working on it.
* lots of developer debug notices pointing out things that
need to be updated.
Revision
1.128 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Jul 1 13:54:27 2009 WST (8 months, 2 weeks ago) by
tjhunt
Branch:
MAIN
Changes since
1.127: +200 -11 lines
Diff to
previous 1.127
themes: MDL-19077 change how the theme is initialised and CSS is served.
This is part of http://docs.moodle.org/en/Development:Theme_engines_for_Moodle%3F
$THEME is now initialised at the same time as $OUTPUT. Old functions like
theme_setup are deprecated in favour of methods on $PAGE. There is a new
theme_config class in outputlib.php that deals with loading the theme config.php file.
CSS used to be served by themes styles.php files calling a function in weblib.php.
Now it works by each theme's styles.php file doing
$themename = basename(dirname(__FILE__));
require_once(dirname(__FILE__) . '/../../theme/styles.php');
which is less code to be copied into each theme. (Old-style styles.php files still
work thanks to some code in deprecatedlib.php.)
Admin UI for choosing a theme cleaned up.
A couple of theme-specific hard-coded hacks like $THEME->cssconstants and
$THEME->CSSEdit have been replaced by a more generic $THEME->customcssoutputfunction
hook. See examples at the end of outputlib.php
Also:
* Fix setting the theme in the URL, which seems to have been broken since 1.9.
* Fix up errors on a few pages caused by the new initialisation order.
* MDL-19097 moodle_page::set_course should not set $COURSE unless it is $PAGE.
* httpsrequired() from moodlelib.php moved to $PAGE->https_required().
* Move has_started() method to the renderer base class.
* Further fixes to display of early errors.
* Remove print_header/footer_old from weblib. I did not mean to commit them before.
Revision
1.126 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Jun 30 15:57:41 2009 WST (8 months, 2 weeks ago) by
samhemelryk
Branch:
MAIN
Changes since
1.125: +35 -0 lines
Diff to
previous 1.125
output MDL-19077 Implemented periodic refresh to meta refresh by delay
Also created layout-popup.php for standardwhite theme to provide a simpler template
Revision
1.124 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jun 26 17:06:17 2009 WST (8 months, 3 weeks ago) by
tjhunt
Branch:
MAIN
Changes since
1.123: +159 -28 lines
Diff to
previous 1.123
themes: MDL-19077 new $OUTPUT->header/footer to replace print_header/footer.
Also, part of the change from weblib.php functions to $OUTPUT-> methods.
This is part of http://docs.moodle.org/en/Development:Theme_engines_for_Moodle%3F
This is a big change, and the result is not perfect yet. Expect some debugging output
on some pages.
The main part of these changes are that $OUTPUT->header now looks for a file
in the theme called layout.php, rather than header.html and footer.html. Also
you can have special templates for certain pages like layout-home.php. There is
fallback code for Moodle 1.9 themes, so they still work.
A few of the old arguments to print_header are no longer supported. (You get an
exception if you try to use them.) Sam H will be cleaning those up.
All the weblib functions that have been replaced with $OUTPUT-> have version in
deprecatedlib, so existing code will go on working for the foreseeable future.
Revision
1.122 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jun 18 18:43:13 2009 WST (9 months ago) by
tjhunt
Branch:
MAIN
Changes since
1.121: +17 -2 lines
Diff to
previous 1.121
themes: MDL-19077 implement the renderer_factory instrastructure.
This is part of http://docs.moodle.org/en/Development:Theme_engines_for_Moodle%3F
The concept is that all the print_... functions in weblib get replaced by methods
on a moodle_core_renderer class. Then, the theme can choose whether to
use the standard moodle_core_renderer class, or another implemenatation of
its own choosing, to generate different HTML.
Also, becuase Moodle is modular, we may need a moodle_mod_forum_renderer
and so on.
In order for the theme to be able to choose which renderers get created, we
introduce the concept of a renderer factory, as in the factory design pattern.
The theme will choose which factory should be used, and that then creates
the renderer objects based on the module name.
This commit includes 4 types of factory:
* standard_renderer_factory
* custom_corners_renderer_factory
* theme_overridden_renderer_factory
* template_renderer_factory
All this with unit tests and PHP doc comments.
Note, this new code is not actually used yet. Still todo:
1. actually define the moodle_core_renderer class, and deprecate a lot of weblib functions.
2. make theme_setup initialise everything, so it is used.
Revision
1.119 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jun 12 20:13:08 2009 WST (9 months ago) by
tjhunt
Branch:
MAIN
Changes since
1.118: +1 -1 lines
Diff to
previous 1.118
ajaxlib/require_js: MDL-16693 $PAGE->requires->... deprecates require_js etc.
There is a new implementation of require_js in lib/deprecatedlib.php,
based on $PAGE->requires.
There were a few other recently introduced functions in lib/weblib.php,
namely print_js_call, print_delayed_js_call, print_js_config and
standard_js_config. These have been removed, since they were never in
a stable branch, and all the places that used them have been changed
to use the newer $PAGE->requires->... methods.
get_require_js_code is also gone, and the evil places that were calling
it, even though it is an internal function, have been fixed.
Also, I made some minor improvements to the code I committed yesterday
for MDL-16695.
All that remains is to update all the places in core code that are
still using require_js.
(This commit also fixes the problem where the admin tree would not
start with the right categories expanded.)
Revision
1.118 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jun 12 11:13:29 2009 WST (9 months, 1 week ago) by
tjhunt
Branch:
MAIN
Changes since
1.117: +15 -0 lines
Diff to
previous 1.117
ajaxlib: MDL-16695 New page_requirements_manager class. Soon to replace require_js.
This new class does the work that require_js used to do, and more.
It can track a number of different things that may be required to
be output somewhere on the page, including:
* Links to JS files
* Links to CSS files
* Links to YUI libraries (this class knows about the dependancies between the different libs).
* Skip links that go from the top of <body> to various places in the content.
* Calls to JavaScript functions (for example to initialise things)
* Bits of data from PHP that need to be available to JavaScript
* As a special case of that, an easy way to pass language strings to JS.
The new API looks like
$PAGE->requires->css('mod/mymod/styles.css');
$PAGE->requires->js('mod/mymod/script.js');
$PAGE->requires->js('mod/mymod/small_but_urgent.js')->in_head();
$PAGE->requires->js_function_call('init_mymod', array($data))->on_dom_ready();
$PAGE->requires is the canonical instances of this new class.
The commit also includes unit tests, and hopefully the PHP doc comments are
clear enough that it is easy to understand.
Revision
1.116 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu May 7 16:55:11 2009 WST (10 months, 1 week ago) by
tjhunt
Branch:
MAIN
Changes since
1.115: +3 -2 lines
Diff to
previous 1.115
blocks: MDL-19010 Fix further blocks-related breakage, including removing all references to blocks_insance_old outside blocklib.php
Revision
1.115 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu May 7 15:05:22 2009 WST (10 months, 1 week ago) by
tjhunt
Branch:
MAIN
Changes since
1.114: +16 -51 lines
Diff to
previous 1.114
blocklib: MDL-19010 fix new install.
* Fix the blocks bit of build_context_path
* Replace blocks_repopulate_page
* Make starting_output work during setup
Revision
1.93 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed May 6 16:55:55 2009 WST (10 months, 1 week ago) by
tjhunt
Branch:
MAIN
Changes since
1.92: +69 -101 lines
Diff to
previous 1.92
moodle_page: MDL-12212 Kill legacy url_... and blocks_... methods
Start calling $PAGE->set_url in all the places it will be necessary
Start of a stub implementation of $PAGE->blocks to stop other things breaking
Remove some of the special case methods in admin_page
Revision
1.83 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed May 6 16:38:56 2009 WST (10 months, 1 week ago) by
tjhunt
Branch:
MAIN
Changes since
1.82: +77 -54 lines
Diff to
previous 1.82
moodle_page: MDL-12212 kill $CFG->pagepath (use $PAGE->set_pagetype)
deprecate $PAGE->get_format_name (use $PAGE->pagetype)
deprecate page_id_and_class (use $PAGE->pagetype)
Revision
1.78 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed May 6 16:29:23 2009 WST (10 months, 1 week ago) by
tjhunt
Branch:
MAIN
Changes since
1.77: +116 -3 lines
Diff to
previous 1.77
moodle_page: MDL-12212 start of new moodle_page class
* has course and status fields
* $PAGE->status updated by print_header and footer
* $PAGE->set_course now replace course_setup function
* global $PAGE created in setup.php
* unit tests for functionality so far
* Moodle still seems to work after this commit!
Revision
1.76 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Apr 15 11:24:25 2009 WST (11 months ago) by
tjhunt
Branch:
MAIN
Changes since
1.75: +25 -4 lines
Diff to
previous 1.75
pagelib: Fixing start-of-file comments in CVS to avoid merge problems when I switch to git.
Revision
1.62.2.8 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jan 25 17:34:37 2008 WST (2 years, 1 month ago) by
scyrma
Branch:
MOODLE_19_STABLE
CVS Tags:
MOODLE_19,
MOODLE_191,
MOODLE_192,
MOODLE_193,
MOODLE_194,
MOODLE_195,
MOODLE_196,
MOODLE_197,
MOODLE_19_MERGED,
MOODLE_19_WEEKLY
Changes since
1.62.2.7: +4 -8 lines
Diff to
previous 1.62.2.7
, to
branch point 1.62
, to
next main 1.173
Start on MDL-12730 .. fixes some E_STRICT messages for 1.9 (removing __construct in
this branch only, to stay compatible with PHP4)
Revision
1.68 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Dec 29 01:13:09 2007 WST (2 years, 2 months ago) by
mchurch
Branch:
MAIN
Changes since
1.67: +8 -3 lines
Diff to
previous 1.67
MDL-12744 - Add ability to pass an extra button for use in print header for modules that use the course page to display themselves with blocks.
Revision
1.52.2.3 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Dec 28 06:25:19 2007 WST (2 years, 2 months ago) by
mchurch
Branch:
MOODLE_18_STABLE
CVS Tags:
MOODLE_1810,
MOODLE_1811,
MOODLE_184,
MOODLE_185,
MOODLE_186,
MOODLE_187,
MOODLE_188,
MOODLE_189,
MOODLE_18_MERGED,
MOODLE_18_WEEKLY
Changes since
1.52.2.2: +8 -3 lines
Diff to
previous 1.52.2.2
, to
branch point 1.52
, to
next main 1.173
MDL-12744 - Add ability to pass an extra button for use in print header for modules that use the course page to display themselves with blocks.
Revision
1.64 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Oct 17 04:44:55 2007 WST (2 years, 5 months ago) by
tjhunt
Branch:
MAIN
Changes since
1.63: +4 -4 lines
Diff to
previous 1.63
MDL-11794 - Blocks editing on button is not XHTML Strict when produced by page_generic_activity. Merged from MOODLE_19_STABLE.
Revision
1.62.2.1 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Oct 13 00:09:45 2007 WST (2 years, 5 months ago) by
tjhunt
Branch:
MOODLE_19_STABLE
Changes since
1.62: +6 -12 lines
Diff to
previous 1.62
MDL-11741 - Convert core modules to take advantage of recent improvements to build_navigation.
This check-in removes about 400 lines of code. I hope I have not screwed anything up. I would be grateful if people could review this change, and keep an eye on the navigation bar in modules.
Any navigation bar bugs you find in the near future, feel free to file them in the tracker and assign them to me. Thanks.
If not to many problems are found, I think I would like to backport this to 1.9 stable, but I am not sure that is a good idea. Opinions to the General Developer Forum please. I am about to start a thread there.
Backported from head. Will update merged tags in a few hours. I am late for orchestra. Sorry.
Revision
1.63 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Oct 12 23:55:52 2007 WST (2 years, 5 months ago) by
tjhunt
Branch:
MAIN
Changes since
1.62: +6 -12 lines
Diff to
previous 1.62
MDL-11741 - Convert core modules to take advantage of recent improvements to build_navigation.
This check-in removes about 400 lines of code. I hope I have not screwed anything up. I would be grateful if people could review this change, and keep an eye on the navigation bar in modules.
Any navigation bar bugs you find in the near future, feel free to file them in the tracker and assign them to me. Thanks.
If not to many problems are found, I think I would like to backport this to 1.9 stable, but I am not sure that is a good idea. Opinions to the General Developer Forum please. I am about to start a thread there.
Revision
1.62 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Sep 19 14:53:09 2007 WST (2 years, 6 months ago) by
martinlanghoff
Branch:
MAIN
CVS Tags:
MOODLE_19_BETA
Branch point for:
MOODLE_19_STABLE
Changes since
1.61: +44 -6 lines
Diff to
previous 1.61
pagelib: Course page - preload child contexts and smarter user_allowed_editing()
With this patch we preload the child contexts for the course
and hold on to them. This means that in one DB query we have all the contexts
we are going to need.
The checks for user_allowed_editing() move from weblib:update_icon() to
user_allowed_editing(), where we cache the result, and in the process save
50% of the cap checks by testing separately blocks from modules (doh!).
Still, the cap checks here are very inefficient...
With the last 3 patches, a course page with default blocks and 9 modinstances
goes from 157 to 86 db queries when logged in as a non-editing user (guest,
student). As admin it drops from 88 to 81.
Conflicts:
lib/pagelib.php
Revision
1.60 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Aug 25 19:28:38 2007 WST (2 years, 6 months ago) by
skodak
Branch:
MAIN
Changes since
1.59: +6 -24 lines
Diff to
previous 1.59
MDL-10635 improved performance of update_course_icon() and friends; fixed parameter of iseditting() - removed $userid which was not used and did not make much sense there anyway
Revision
1.56 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Apr 17 04:48:48 2007 WST (2 years, 11 months ago) by
mattc-catalyst
Branch:
MAIN
Changes since
1.55: +46 -23 lines
Diff to
previous 1.55
Breadcrumbs: pagelib changes
- Modified page class to use build_navigation for creating breadcrumbs.
- Added print_header method to page_generic_activity to make derived
classes print the page headers the correct way.
Author: Matt Clarkson <mattc@catalyst.net.nz>
Committer: Matt Clarkson <mattc@catalyst.net.nz>
Revision
1.55 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Mar 26 10:55:03 2007 WST (2 years, 11 months ago) by
toyomoyo
Branch:
MAIN
Changes since
1.54: +6 -4 lines
Diff to
previous 1.54
patching up module level manageactivies capability so that you only need it assigned at mod level to update an activity
Revision
1.53 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Feb 16 16:57:24 2007 WST (3 years, 1 month ago) by
toyomoyo
Branch:
MAIN
Changes since
1.52: +23 -3 lines
Diff to
previous 1.52
made some changes so that if a user has any roles assigned in context_module or context_block with moodle/site:manageblocks or moodle/course:manageactivities, he will see the "turn editting on" button without needing to have a role assigned at context_course with moodle/course:manageactivies capability. Of course this user would not be able to edit any blocks or modules he/she is not supposed to edit. Ajax for these users with partial editing privilages are locked. Please report bugs asap as we are looking at backporting this change to 1.8. Cheers.
Revision
1.52 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Jan 30 06:29:28 2007 WST (3 years, 1 month ago) by
skodak
Branch:
MAIN
CVS Tags:
MOODLE_18_BETA
Branch point for:
MOODLE_18_STABLE
Changes since
1.51: +5 -5 lines
Diff to
previous 1.51
MDL-8343 reorganize frontpage settings in admintree - admin tree now allows to specify context together with required capability for each entry
MDL-8352 Fully separate CONTEXT_COURSE, SITEID from COURSE_SYSTEM - first part of cleanup related to frontpage
Revision
1.49 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Sep 21 17:16:41 2006 WST (3 years, 5 months ago) by
moodler
Branch:
MAIN
CVS Tags:
MOODLE_17_BETA
Branch point for:
MOODLE_17_STABLE
Changes since
1.48: +3 -3 lines
Diff to
previous 1.48
New "Switch Role" functionality to replace the old "Student view".
It's not well-tested yet and probably doesn't quite work. I will keep debugging this tonight from home.
Revision
1.48 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Sep 18 01:32:45 2006 WST (3 years, 6 months ago) by
skodak
Branch:
MAIN
Changes since
1.47: +8 -7 lines
Diff to
previous 1.47
fixed non-working edit button on course page for teachers, added explanation comments
Revision
1.45 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Sep 12 04:05:31 2006 WST (3 years, 6 months ago) by
skodak
Branch:
MAIN
Changes since
1.44: +3 -3 lines
Diff to
previous 1.44
old admin block not added into frontpage during installation anymore, it is not removed during upgrade.
Revision
1.39 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Mar 17 11:17:44 2006 WST (4 years ago) by
mjollnir_
Branch:
MAIN
Changes since
1.38: +5 -2 lines
Diff to
previous 1.38
Stickyblocks: fool pagelib into thinking it is course-view when it needs to be, rather than admin-stickyblocks
Revision
1.34 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jul 21 01:23:07 2005 WST (4 years, 7 months ago) by
defacer
Branch:
MAIN
Changes since
1.33: +3 -3 lines
Diff to
previous 1.33
Merging from STABLE:
Fix for bug 3637:
Certain obscure cases of using PHP accelerators (probably has to do with
OS and PHP version as well, but it's not certain) caused an error to be
displayed when importing data from "local pagelib" files with "debug" turned
on. The error was bogus, but error() stopped the page from being displayed.
Thanks to James P. Dugal the from University of Louisiana at Lafayette for
identifying and helping to solve the problem!
Revision
1.33.2.1 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jul 21 01:22:13 2005 WST (4 years, 7 months ago) by
defacer
Branch:
MOODLE_15_STABLE
CVS Tags:
MOODLE_153
Changes since
1.33: +3 -3 lines
Diff to
previous 1.33
Fix for bug 3637:
Certain obscure cases of using PHP accelerators (probably has to do with
OS and PHP version as well, but it's not certain) caused an error to be
displayed when importing data from "local pagelib" files with "debug" turned
on. The error was bogus, but error() stopped the page from being displayed.
Thanks to James P. Dugal the from University of Louisiana at Lafayette for
identifying and helping to solve the problem!
Revision
1.31 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Feb 28 12:16:41 2005 WST (5 years ago) by
defacer
Branch:
MAIN
Changes since
1.30: +12 -3 lines
Diff to
previous 1.30
Adding caching to page_import_types. Actually the caching is REQUIRED for the
function to work, because otherwise it would barf on duplicate class declaration
the second time it was called with the same arguments.
Revision
1.30 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Feb 28 12:01:30 2005 WST (5 years ago) by
defacer
Branch:
MAIN
Changes since
1.29: +17 -2 lines
Diff to
previous 1.29
Library function which returns the page types used for a specific directory
in the Moodle distro structure. As generic as it gets.
Revision
1.28 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Feb 10 09:59:11 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.27: +3 -78 lines
Diff to
previous 1.27
Bringing Quiz in line with Martin's "make Chat into a showcase for pages" idea.
Revision
1.25 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Feb 9 23:39:07 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.24: +73 -3 lines
Diff to
previous 1.24
New class that models the behavior of a chat activity!
Isn't it so small and cute? ;-)
Revision
1.24 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Feb 9 23:22:16 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.23: +54 -40 lines
Diff to
previous 1.23
Putting all things that are common among activities into a new class
page_generic_activity. Then we can inherit almost all of the desired
behavior and just override a couple of functions to get going with page
support in a new activity.
Revision
1.22 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Feb 8 10:59:44 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.21: +8 -12 lines
Diff to
previous 1.21
Changing the way that applicable formats for each block are defined:
The format for each page is now the same as the id attribute of the
BODY tag, which in turn is a simple function of the script's relative path:
The format for e.g. a quiz view page is "mod-quiz-view". The format for the
site index is "site-index". Exception: the format for courses is not just
"course-view", but "course-view-weeks" etc.
Obviously the applicable_formats() override for each block should now take
this into account. The matching rules now are:
* You can specify the full format, e.g. "mod-quiz-view" => true
will allow the block to be added in quizzes
* Prefixes match the full page format, e.g. "mod" matches ALL activities
* You can use "*" as a wildcard, e.g. "mod-*-view" matches just the view.php
page of all activities
* These rules interoperate, thus "mod-*" is the same as "mod"
* "all" remains as a catch-all situation
Revision
1.21 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Feb 5 04:27:54 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.20: +4 -2 lines
Diff to
previous 1.20
Fix for bug 2492: Notices thrown by pagelib.php.
It was an oversight on my part. Thanks Gustav!
Revision
1.20 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Feb 2 10:32:40 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.19: +23 -29 lines
Diff to
previous 1.19
Utilizing page_id_and_class(), make a factory function page_create_instance()
that does not need the page type as an argument (autodetects from the URL).
Revision
1.18 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Feb 1 15:34:17 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.17: +14 -10 lines
Diff to
previous 1.17
Fixing all the details in the block instance configuration screen.
That wasn't so hard!
Revision
1.17 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Feb 1 15:12:39 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.16: +174 -3 lines
Diff to
previous 1.16
Added a new class page_quiz, modelling the behavior of a quiz view page.
Not everything is quite right now, a few details (e.g. correct breadcrumbs)
have been ignored but most of the functionality is there.
Blocks in quizzes, here we come!
Revision
1.16 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Jan 31 10:18:15 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.15: +14 -7 lines
Diff to
previous 1.15
Dropping the use of MOODLE_PAGE_COURSE <gasp>!
The new constant is PAGE_COURSE_VIEW, and it's more streamlined with the
new CSS-related ids for 1.5. There are great possibilities for the future
here, so we 're getting ready.
On the other hand, this has to be the ugliest hack I 've ever inflicted
on any program (look at pagelib.php). Thankfully it will only stay for just
a little while.
Revision
1.14 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jan 28 13:42:19 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.13: +2 -12 lines
Diff to
previous 1.13
Removing the extra debug info now that bug 2431 was fixed.
I can't believe that this insignificant workaround actually solved the
problem. This is most probably a bug with PHP and static initialization
of array variables.
Revision
1.13 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jan 28 11:52:56 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.12: +11 -5 lines
Diff to
previous 1.12
A small change for the static initialization in page_map_class,
and more debug added just before init is done.
Revision
1.12 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jan 28 07:56:46 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.11: +9 -3 lines
Diff to
previous 1.11
Bugfix: when configuring a block in the site index, the site name was
being displayed twice in the breadcrumbs.
Revision
1.11 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Jan 26 23:33:50 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.10: +56 -2 lines
Diff to
previous 1.10
Adding that nifty BODY id and class detection code to pages... I have the
feeling that this is the way to go, as more Moodle things will be converted
to use $PAGE in the future.
Revision
1.10 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Jan 26 03:13:09 2005 WST (5 years, 1 month ago) by
defacer
Branch:
MAIN
Changes since
1.9: +10 -2 lines
Diff to
previous 1.9
Adding some extra debug output when a specific error() occurs to help track
down a problem which has been reported in the forums (it is NOT a bug though).
THIS SHOULD BE REMOVED BEFORE 1.5 IS RELEASED!
Revision
1.9 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Jan 5 03:43:09 2005 WST (5 years, 2 months ago) by
defacer
Branch:
MAIN
Changes since
1.8: +7 -3 lines
Diff to
previous 1.8
Fix for bug 2336:
I accidentally removed the editing button from courses when fixing bug 2328.
Fortunately, Gustav was on the lookout.
Revision
1.8 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sun Jan 2 23:20:15 2005 WST (5 years, 2 months ago) by
defacer
Branch:
MAIN
Changes since
1.7: +25 -7 lines
Diff to
previous 1.7
Fix for bug 2328:
* When configuring a block instance, "Turn editing off" button is not
shown anymore.
* When configuring a block instance, the breadcrumbs are now better,
providing a link to the course page. This could be done in a much
better way if we had a comprehensive template system but it will
suffice for now.
Revision
1.6 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Nov 29 12:19:05 2004 WST (5 years, 3 months ago) by
defacer
Branch:
MAIN
Changes since
1.5: +52 -50 lines
Diff to
previous 1.5
Fix for bug 2241:
I hope this time I got everything changed to the new Page interface! I 'm
really sorry for messing up and breaking new installations... :(
Also moved the only two functions of the API outside the page_base class.
Revision
1.5 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Nov 26 01:23:57 2004 WST (5 years, 3 months ago) by
defacer
Branch:
MAIN
Changes since
1.4: +11 -11 lines
Diff to
previous 1.4
Somehow I forgot to commit these and the whole page setup wasn't working
after renaming MoodlePage => page_base.
Revision
1.3 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Nov 13 02:39:25 2004 WST (5 years, 4 months ago) by
defacer
Branch:
MAIN
Changes since
1.2: +107 -21 lines
Diff to
previous 1.2
Pages/blocks code updates:
NEW: The code now supports dynamically plugging your own Pages and block position
identifiers into Moodle without messing with the main libraries at all.
UPDATE: Many functions in blocklib now use pass-by-reference for speed.
UPDATE: Class MoodlePage has been made more presentable and robust.
Revision
1.1 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Nov 9 03:36:07 2004 WST (5 years, 4 months ago) by
defacer
Branch:
MAIN
MAJOR CHANGES:
--------------
Brand-new pagelib.php at your disposal! It slices, it dices, it makes your coffee.
It still doesn't understand women... Read the comments in pagelib.php for a first
impression. Feedback highly encouraged!
Blocks code has undergone significant changes to work with Pages. Flexibility is its
middle name, since I think (without having tried it) that adding e.g. a third
placeholder for "center" blocks in courses, with full support for moving around etc,
will now take about 15 lines of new or edited code. If you are not impressed yet, I
suggest watching a documentary on solar physics. :P
MINOR CHANGES:
--------------
Added instance_allow_config() in the blocks class hierarchy to supplement per-instance
configuration options. You can override it to return true and thus get configuration
amenities without allowing multiple instances.
Minor polishing to comments and documentation (whatever caught my eye was game).
Tightened up some code here and there by utilizing all the new features.
BUGFIXES:
---------
A bug in restore_execute.html caused hidden blocks to not be restored at all.
This form allows you to request diffs between any two revisions of this file.
For each of the two "sides" of the diff,
select a symbolic revision name using the selection box, or choose
'Use Text Field' and enter a numeric revision.