4550 Commits

Author SHA1 Message Date
skodak
117987949a fixed undefined $timenow 2006-04-22 17:28:18 +00:00
skodak
54bb46f55b fixed undefined $course 2006-04-22 17:25:37 +00:00
skodak
d850b4e621 typo in switch 2006-04-22 13:38:24 +00:00
toyomoyo
2712ac665c fix for 5205 2006-04-21 07:55:57 +00:00
moodler
c125d80c3e Fixed Bug #5012 - assignment type uploadsingle does not log view actions 2006-04-21 07:01:01 +00:00
moodler
9e0f5d2abf Added save changes button at top (Bug #1043 - submit button at top of journal report) 2006-04-21 02:23:33 +00:00
gustav_delius
6037288eeb Fixed code that relied on globals hack. Fixed bug 5261 2006-04-20 23:10:45 +00:00
urs_hunkler
0e2b7205f5 removed width for multichoice feedback 2006-04-20 08:37:00 +00:00
moodler
20a730762f No need for noapprovalrequired string 2006-04-20 07:55:07 +00:00
wildgirl
4c85af7b01 Added a check for is_object($item) to prevent possible warnings in preview_ims_generate_toc
Restored use of textlib in preview_ims_generate_toc
2006-04-20 06:53:07 +00:00
wildgirl
676fb87edc Added a check for isset($this->resource->reference) to prevent warnings in resource_ims
Added a check for is_object($item) to prevent warnings in ims_generate_toc
Restored use of textlib in ims_generate_toc
2006-04-20 06:51:55 +00:00
moodler
ec536d7a48 Make sure the number is stored as a proper number 2006-04-20 04:07:50 +00:00
moodler
59f3b71781 New number field type 2006-04-20 04:02:30 +00:00
martinlanghoff
f83edcb114 mod/chat - use empty value instead of erroring out if $USER->lastIP and getremoteaddr() don't yield any interesting value
Sometimes we can't get any useful IP for the user -- and this may even be a
valid situation. So fudge an empty value -- the DB needs it as the IP field
is NOT NULL.
2006-04-19 21:22:36 +00:00
skodak
ef45822122 some extra cleaning of comments and feedback before storage. normaly the text is cleaned before display, this is just a preventive measure because I did not want to study this code all day ;-) 2006-04-19 20:21:42 +00:00
skodak
34ffb5cae2 some extra cleaning of comments and feedback before storage. normaly the text is cleaned before display, this is just a preventive measure because I did not want to study this code all day ;-) 2006-04-19 20:10:04 +00:00
skodak
d2963541e2 Security related parameter cleanup in workshop code, please test it. No bug fixes... 2006-04-19 19:48:46 +00:00
skodak
7282d18cf0 isguest() must be checked AFTER require_login() because the user may not be logged in yet ;-) 2006-04-19 19:42:47 +00:00
moodler
7b54f5636d Fix group picture in HTML mail when no CSS is used 2006-04-19 12:47:30 +00:00
gbateson
30b8cc87e1 fixed bug which prevented display of JCross clues on PHP 5.1.2 2006-04-19 06:20:37 +00:00
vyshane
feb00a54d0 Setting $data->listtemplateheader and $data->listtemplatefooter to '' if we
are resetting the listtemplate.
2006-04-19 04:21:23 +00:00
vyshane
8d4a31bd3c Removed javascript for resetting templates. We reload the page to reset
templates.
2006-04-19 02:54:07 +00:00
mjollnir_
fbc525bc0b Correcting code to remove warning originating from earlier commit
Peter Bulmer peterbulmer@catalyst.net.nz
2006-04-19 02:31:32 +00:00
martinlanghoff
930413b133 mod/chat: Normal method - introducing "Stream" updates.
This is an alternative version of jsupdate.php that acts
as a long-running daemon. It will feed/stall/feed JS updates
to the client. From the module configuration select "Stream"
updates.

The client connection is not forever though. Once we reach
CHAT_MAX_CLIENT_UPDATES (currently 1000), it will force
the client to re-fetch it.

This buys us all the benefits that chatd has, minus the setup,
as we are using apache to do the daemon handling.

Chat still defaults to the normal update method, which is now
optimised to take advantage of keepalives -- so this change is
safe. The instructions in the config page also indicate that this
mode may not be well supported everywhere. It hasn't been
tested on IIS for starters.

In terms of relative cost -- if each hit on jsupdate.php incurs
on ~20 db queries and delivers one update to the client, each hit
on jsupdate takes ~20 queries, and then roughly 2~3 queries to
serve each of the next 1000 updates. On busy sites, the difference
is huge.

There is still room for enhancements in both keepalive and stream
update methods. I am pretty sure we can trim DB queries more.
2006-04-19 02:20:48 +00:00
mjollnir_
eb55a1bfb9 Avoiding warning in last commit:
mod/quiz/index changes to only display quiz grades when teacher allows
Changes to index.php to only allow student to view overall quiz scores when
teacher has not set options forbidding this, and it can't give away what
scores were for attempts where results should still be hidden.
Credit: Peter Bulmer peterbulmer@catalyst.net.nz
2006-04-18 22:57:28 +00:00
mjollnir_
40377b188b mod/quiz/index changes to only display quiz grades when teacher allows
Changes to index.php to only allow student to view overall quiz scores when
teacher has not set options forbidding this, and it can't give away what
scores were for attempts where results should still be hidden.
Credit: Peter Bulmer peterbulmer@catalyst.net.nz
2006-04-18 22:55:28 +00:00
mjollnir_
d78a1cf6d8 mod/quiz/locallib bugfix get_qn_options now uses more sensible defaults.
Previously get_question_options used options for
after-attempt-while-quiz-open, when called while a attempt was still in
progress.  Changed it to use options for immediately-after-attempt instead.
Credit: Peter Bulmer peterbulmer@catalyst.net.nz
2006-04-18 22:54:51 +00:00
mjollnir_
309c0d55b2 mod/quiz/view changes to only display attempt grades when teacher allows.
Changed view.php to only display grades when the teacher has not set
options forbidding it.  Further, where there is some attempts that are
allowed to be displayed, and others not, highligting of the highest score,
and printing of the overall grade allocation has been disabled to ensure
the hidden grade is not revealed.
Credit: Peter Bulmer peterbulmer@catalyst.net.nz
2006-04-18 22:54:10 +00:00
mjollnir_
15db443c87 mod/quiz/review only display grade summary if student allowed to see scores
Change to review.php so that the student will only see the grade summary
if they are allowed to view their scores - as determined by quiz options
set by the teacher.
Credit: Peter Bulmer peterbulmer@catalyst.net.nz
2006-04-18 22:50:04 +00:00
mjollnir_
9f7f01db04 mod/quiz/review quiz options loaded once per pageload, not once per qn.
Moved loading of quiz review options from loop iterating over each qn to be
displayed, to the top of the pageload.  Should give efficency gains
on quizes with long pages, as well as making the options available
earlier in the process.
Credit: Peter Bulmer peterbulmer@catalyst.net.nz
2006-04-18 22:47:56 +00:00
martinlanghoff
d13ef2fbdc mod/chat - cope with missing $USER->lastIP
$USER->lastIP is sometimes not set properly during login, fetch it if we can
or error out clearly -- we won't be able to login the user to the chat if
we don't have an IP address to match him/her against.
2006-04-18 22:40:56 +00:00
wildgirl
824c9dc7c6 resource.class.php changes:
1. Added logic to process repository paths. A repository path is marked with a # as the first character of the reference field.
2. Added a new error code for repository items not being deployed / bad reference.

ims.html change:
Added a button to link to the repository browser.

New files:
finder.php – browser for the repository
preview.php – cut down display routine from resource.class.php, forces sidemenu etc.
repository_deploy.php – deploy for repository items (same results as deploy.php)
repository_config.php (repository disabled by default)
resize.js - for iframe resizing
dummyapi.js - dummy SCORM API

(Tom's work, with help from Andy)
2006-04-18 18:04:30 +00:00
gbateson
1872962d5c corrected handling of tables within JCloze text (a lot of vertical space was being added) 2006-04-18 12:20:18 +00:00
moodler
f619f8c8ab FIx for slashes problem in bug 5222 (and some others) 2006-04-18 09:16:22 +00:00
moodler
5379d24992 A little HTML hint since styles are not working here for me somehow 2006-04-18 07:28:44 +00:00
toyomoyo
fd8d5ba75f fix for 5207 2006-04-18 07:22:18 +00:00
moodler
78c98892d1 More efficient chat listings (less database calling) 2006-04-18 07:14:21 +00:00
toyomoyo
8f23f49004 fix for 5209 2006-04-18 06:43:29 +00:00
vyshane
d553ae9f74 "Reset template" button now only resets the template textarea with the default
template. User needs to hit "Save template" to save the changes.
2006-04-18 06:11:38 +00:00
skodak
200514e282 some bugfixing and proper conversion to new xxx_param() functions - SC#148 2006-04-17 21:14:50 +00:00
martinlanghoff
a6d1886fa5 mod/chat: Normal method -- collate 2 SELECTs into one
We really don't need to ask about the user table _twice_ here. Just ask for the
right fields, and done.
2006-04-17 21:06:28 +00:00
martinlanghoff
46c859760c mod/chat: Normal method -- faster, lighter DB updates
Use set_field() keyed on PK instead of update_record() or set_field()
keyed on non-PKs.
2006-04-17 21:05:51 +00:00
martinlanghoff
c5e817f02c mod/chat - Normal method - users pane only uses keepalive when refreshing fast
To avoid wasting server resources, user's pane now only uses keepalive
when the refresh is lower than apache's timeout.
2006-04-17 21:05:17 +00:00
martinlanghoff
6169ea259a mod/chat - Normal method now supports HTTP Keep-Alive - users pane
User's pane now also uses keepalives -- if the refresh freq is below
the disconnect timeout, then it is a win. Otherwise it wastes memory
at the server end.
2006-04-17 21:04:47 +00:00
martinlanghoff
dfd1d9e272 mod/chat - Normal method now support HTTP Keep-Alive
By using output buffering, we now support HTTP Keep-Alive, which means
that each client gets tightly bound to a single apache child - this means
that we get

 + lower resource usage on the webserver
 + _much_ lower resource usage on webserver and dbserver if pconnects are used
 + a good case for further caching (memcache/mmcache)

Using ab via localhost or fast LAN using keepalives is actually slower from the
client perspective -- still lighter on the server. Via slower links (DSL/modem)
the responses are faster.
2006-04-17 21:04:19 +00:00
martinlanghoff
4d5525c650 mod/chat: make http-chat more database friendly and change msg insertion to use POST
+ we are now more conservative in the fields it asks from the db
+ also more conservative with upates to chat_users
+ messages are now added via POST requests instead of GET
2006-04-17 21:03:44 +00:00
moodler
16ad40e145 Fix for chat character sets bug 5010 2006-04-16 16:01:40 +00:00
gbateson
23efbfa15e improved readability of reg. exp. in adjust_media_urls function 2006-04-16 02:10:14 +00:00
stronk7
ff62d70dc6 Two more uses of format_string() agains entry->concept 2006-04-15 19:28:26 +00:00
stronk7
deb59b8f95 Filter one more string if filterall is enabled. 2006-04-15 19:24:44 +00:00