[Server-devel] Offline moodle notes in moodle.org

Tony Anderson tony_anderson at usa.net
Fri Oct 17 04:44:37 EDT 2008


Hi,

First, gears is a browser plugin. It provides a capability to 
'go_offline' by copying web pages and resources (jpg, pdf, ...) to a 
local SQLite database based on a manifest. While offline, gears provides 
a local proxy server which responds to http requests by supplying the 
page (with links to resources) from the local database. It is limited in 
that it can only handle urls which exactly match those in the manifest. 
For offline moodle, we need to intercept urls which call php modules 
server side and respond to them from local javascript. This can be done 
by ajax requests. Greasemonkey is a temporary prop to convert the normal 
form 'actions' to invoke local javascript. Later, it should be possible 
to have the pages generated with the 'onclick' javascript calls and 
eliminate the need for greasemonkey.

A way to think about this is that in offline moodle, the server side php 
scripts are replaced by client side javascript.

Tony

Ludo (Marc Alier) wrote:
> "This discussion should move to devel at l.o, as it refers to software
> running on the laptop, not the server."
> 
> I disagree. The Gears plugin may run on the laptop, but all the code of 
> the application ( javscript and the php that generates it) is executed 
> and maintained on the server: Moodle in this case.
> 
> 
> On Tue, Oct 14, 2008 at 10:08 PM, John Watlington <wad at laptop.org 
> <mailto:wad at laptop.org>> wrote:
> 
> 
>     This discussion should move to devel at l.o, as it refers to software
>     running on the laptop, not the server.
> 
>     Some context for my comment:  I had told them that we were
>     working with schools that were completely offline (although
>     with servers).   The problem might have been a mismatch with
>     their business model more than a mismatch of technologies.
> 
>     I'm looking for the name/address of the software architect I was
>     speaking to.   But, SJ already brought up this question on devel
>     back in February, and cc'ed a gears developer (attached).
> 
>     cheers,
>     wad
> 
>         From: "Samuel Klein" <sj at laptop.org <mailto:sj at laptop.org>>
>         Date: February 16, 2008 1:21:36 PM EST
>         To: "edward baafi" <edwardbaafi at gmail.com
>         <mailto:edwardbaafi at gmail.com>>, "OLPC Devel" <devel at laptop.org
>         <mailto:devel at laptop.org>>
>         Cc: Ben Lisbakken <lisbakke at google.com
>         <mailto:lisbakke at google.com>>, Luke Closs
>         <luke.closs at socialtext.com <mailto:luke.closs at socialtext.com>>,
>         Marco Pesenti Gritti <mpg at redhat.com <mailto:mpg at redhat.com>>,
>         Dan Bricklin <danb at bricklin.com <mailto:danb at bricklin.com>>
>         Subject: Re: using the browser as an activity platform : pyxpcom
>         / hulahop / Gears
> 
>         The core use here is being able to use the browser as activity
>         platform -- letting web developers good at JS code and test on most
>         any platform, and develop something that can be a first-class
>         activity
>         within Sugar.  One example is Dan's javascript spreadsheet,
>         anothe ris
>         a dynamic library (see for instance
>         http://wiki.laptop.org/go/Dynamic_library), another is an
>         existing web
>         service online that one might want to run locally.
> 
>         In addition to pyxpcom, let me add Google Gears as a useful piece of
>         this platform, especially when offering local use of popular online
>         tools.  Off the top of my head, MediaWiki, MindMeister, I copy Ben
>         Lisbakken, a gears maintainer, who reports that there is a Gears
>         patch
>         to make it work without extension support...  Ben, I'll also
>         introduce
>         you to marcopg separately.
> 
> 
> 
> 
> -- 
> ---
> Ludo ( Marc Alier)
> UPC - granludo at gmail.com <mailto:granludo at gmail.com> - Tel. +34-934137885
> http://orangoodling.blogspot.com - http://www.dfwikilabs.org -
> http://ososdeviaje.dfwikilabs.org - http://mossegalapoma.cat



More information about the Server-devel mailing list