2 /****************************************************************/
4 /****************************************************************/
5 /* Copyright (c) 2002-2009 */
6 /* Adaptive Technology Resource Centre / University of Toronto */
9 /* This program is free software. You can redistribute it and/or*/
10 /* modify it under the terms of the GNU General Public License */
11 /* as published by the Free Software Foundation. */
12 /****************************************************************/
13 // $Id: WeblinksExport.class.php 8119 2008-10-29 13:53:06Z hwong $
16 * A very simple class to generates a singular webcontent weblink xml file.
17 * Based on the namespace:
18 * http://www.imsglobal.org/profile/cc/ccv1p0/derived_schema/domainProfile_5/imswl_v1p0_localised.xsd
20 class WeblinksExport {
22 var $wl; //weblink obj
26 * @param mixed Weblink Object, ref Weblinks.class.php
28 function WeblinksExport($wl){
42 //assign all the neccessarily values to the template.
43 $savant->assign('title', htmlentities_utf8($wl->getTitle(), ENT_QUOTES, 'UTF-8'));
45 $savant->assign('url_href', urlencode($url['href']));
46 $savant->assign('url_target', $url['target']);
47 //TODO: not supported yet
48 //$savant->assign('url_window_features', $url['window_features']);
51 $xml = $savant->fetch(TR_INCLUDE_PATH.'classes/Weblinks/Weblinks.tmpl.php');