Printing a Database Record | Moodle v2.3

Printing a Database Record | Moodle v2.3

by Francois Evans -
အကြောင်းပြန်မှု အရေအတွက်: 6

The Database activity includes template settings for each record. Is it possible to retain that formatting to print out a record from a database? At the moment when I try, it prints out the whole web page (blocks & all).


The Database does export to Excel /Open Office spreadsheet, but I'm concerned that formatting will be lost. - Any advice?

ပျှမ်းမျှအဆင့်သတ်မှတ်ချက်များ: -
Francois Evans ထံသို့ အကြောင်းပြန်ရာတွင်

Re: Printing a Database Record | Moodle v2.3

by Itamar Tzadok -

You can add css (to the css tab of the activity) to clean up unwanted parts when using the browser's print option. See http://moodle.org/mod/forum/discuss.php?d=207434&parent=906542 for a related example of the css. You can also use the ##export## tag (with portfolios enabled site wide) to allow exporting an entry to html file. hth ပြုံး

Itamar Tzadok ထံသို့ အကြောင်းပြန်ရာတွင်

Re: Printing a Database Record | Moodle v2.3

by Francois Evans -

Thanks Itamar.

In the css example you've given at the web link: http://moodle.org/mod/forum/discuss.php?d=207434&parent=906542

...you say: You need to check the actual selectors in the designated page as they may differ between themes. (My emphasis.)

What is an 'actual selector in the designated page' mean and how should I programme this? Thanks again for your useful tips. ရှက်သွေးဖြန်း

Francois Evans ထံသို့ အကြောင်းပြန်ရာတွင်

Re: Printing a Database Record | Moodle v2.3

by Itamar Tzadok -

The selectors are those names which identify the page's html elements for css. For example div#page-header is a div element with id="page-header". If you have such an element on the page you can apply to it css by reference to that selector.

You can use firebug or your browser's web inspector to inspect the html and css of the designated page to find the selectors of the elements you want to hide in printing, and add the selectors to the @media print css rules.

See illustration of using firebug.

Itamar Tzadok ထံသို့ အကြောင်းပြန်ရာတွင်

Re: Printing a Database Record | Moodle v2.3

by Francois Evans -
Francois Evans ထံသို့ အကြောင်းပြန်ရာတွင်

Re: Printing a Database Record | Moodle v2.3

by Frank Ralf -