Commit 68d5c778 authored by Nigel McNie's avatar Nigel McNie Committed by Nigel McNie
Browse files
parents cb61d2e2 d7f75f60
......@@ -31,7 +31,6 @@ require('init.php');
$smarty = smarty();
$smarty->assign('page_content', get_site_page_content('about'));
$smarty->assign('site_menu', site_menu());
$smarty->assign('searchform', searchform());
$smarty->display('sitepage.tpl');
......
......@@ -137,7 +137,6 @@ function showHideMessage(id) {
JAVASCRIPT;
$smarty = smarty(array('tablerenderer'));
$smarty->assign('site_menu', site_menu());
$smarty->assign('selectall', 'toggleChecked(\'tocheck\'); return false;');
$smarty->assign('markread', 'markread(this); return false;');
$smarty->assign('typechange', 'activitylist.doupdate({\'type\':this.options[this.selectedIndex].value});');
......
......@@ -177,7 +177,6 @@ if (!$viewusers = get_records_sql_array($sql, array($USER->get('id')))) {
}
$smarty = smarty(array('tablerenderer'));
$smarty->assign('site_menu', site_menu());
$smarty->assign('viewusers', $viewusers);
$smarty->assign('typestr', get_string('views', 'activity'));
$smarty->assign('selectall', 'toggleChecked(\'tocheck\'); return false;');
......
......@@ -87,5 +87,6 @@ $string['thisisdraftdesc'] = 'When your post is a draft, no one except you can s
$string['title'] = 'Title';
$string['viewblog'] = 'View Blog';
$string['youarenottheownerofthisblogpost'] = 'You are not the owner of this blog post';
$string['cannotdeleteblogpost'] = 'An error occured removing this blog post.';
?>
......@@ -407,6 +407,7 @@ class ArtefactTypeBlogPost extends ArtefactType {
return;
}
delete_records('artefact_blog_blogpost_file', 'blogpost', $this->id);
delete_records('artefact_blog_blogpost', 'blogpost', $this->id);
parent::delete();
......
......@@ -41,6 +41,7 @@ $enc_files = json_encode(get_string('attachedfiles', 'artefact.blog'));
$enc_delete = json_encode(get_string('delete', 'artefact.blog'));
$enc_delete_confirm = json_encode(get_string('deleteblogpost?', 'artefact.blog'));
$enc_postedon = json_encode(get_string('postedon', 'artefact.blog'));
$enc_cannotdeleteblogpost = json_encode(get_string('cannotdeleteblogpost', 'artefact.blog'));
return <<<EOJAVASCRIPT
......@@ -156,7 +157,7 @@ postlist.rowfunction = function(d, n, gd) {
}
}
else {
alert('yay');
displayMessage({$enc_cannotdeleteblogpost}, 'error');
}
},
function (error) {
......
......@@ -106,7 +106,6 @@ function contactus_submit(Pieform $form, $values) {
$smarty = smarty();
$smarty->assign('page_content', $contactform);
$smarty->assign('site_menu', site_menu());
$smarty->assign('searchform', searchform());
$smarty->display('sitepage.tpl');
......
......@@ -97,7 +97,6 @@ if (!$USER->is_logged_in()) {
$smarty->assign('login_form', $loginform);
}
$smarty->assign('page_content', get_site_page_content($pagename));
$smarty->assign('site_menu', site_menu());
$smarty->display('index.tpl');
?>
......@@ -60,7 +60,7 @@ function CollapsableTree(data, source) {
p.child = ul;
}
else {
var oops = P(null, 'omgwtfnothinghere');
var oops = P({'class': 'emptycontainer'}, get_string('nochildren'));
appendChildNodes(p, oops);
p.child = oops;
}
......
......@@ -389,7 +389,7 @@ $string['communityname'] = 'Community Name';
$string['invalidcommunity'] = 'The community doesn\'t exist';
$string['communitydescription'] = 'Community Description';
$string['membershiptype'] = 'Community Memberhsip Type';
$string['membershiptype.controlled'] = 'Controlled Memberhsip';
$string['membershiptype.controlled'] = 'Controlled Membership';
$string['membershiptype.invite'] = 'Invite Only';
$string['membershiptype.request'] = 'Request Membership';
$string['membershiptype.open'] = 'Open Membership';
......
......@@ -43,6 +43,7 @@ $string['stopdate'] = 'Access End Date/Time';
$string['stopdate'] = 'Access End Date/Time';
$string['ownerformat'] = 'Name display format';
$string['ownerformatdescription'] = 'This field controls what appears in the author field for the template you select in step 2';
$string['nochildren'] = 'no artefacts';
$string['category.all'] = 'All Templates';
$string['category.resume'] = 'Resume Templates';
......
......@@ -170,6 +170,7 @@ EOF;
$smarty->compile_dir = get_config('dataroot').'smarty/compile';
$smarty->cache_dir = get_config('dataroot').'smarty/cache';
$smarty->assign('SITEMENU', site_menu());
$smarty->assign('THEMEURL', get_config('themeurl'));
$smarty->assign('WWWROOT', $wwwroot);
......@@ -230,7 +231,12 @@ function jsstrings() {
'prevpage',
'lastpage',
)
)
),
'collapsabletree' => array(
'view' => array(
'nochildren',
),
),
);
}
......
......@@ -31,7 +31,6 @@ require('init.php');
$smarty = smarty();
$smarty->assign('page_content', get_site_page_content('privacy'));
$smarty->assign('site_menu', site_menu());
$smarty->assign('searchform', searchform());
$smarty->display('sitepage.tpl');
......
......@@ -31,7 +31,6 @@ require('init.php');
$smarty = smarty();
$smarty->assign('page_content', get_site_page_content('termsandconditions'));
$smarty->assign('site_menu', site_menu());
$smarty->assign('searchform', searchform());
$smarty->display('sitepage.tpl');
......
<div class="sidebar">
{str tag="mainmenu"}
{if $site_menu}
{if $SITEMENU}
<ul id="sitemenu">
{foreach from=$site_menu item=item}
{foreach from=$SITEMENU item=item}
<li class="{cycle values=r0,r1}"><a href="{$item.link|escape}">{$item.name}</a></li>
{/foreach}
</ul>
......
......@@ -46,7 +46,7 @@
<div class="fr"><img src="{image_path imagelocation='images/header_corner_topright.gif'}" border="0" alt=""></div>
<table cellspacing="0" class="searchbox fr">
{if !$nosearch}
{if !$nosearch && $LOGGEDIN}
<tr>
<td>{$searchform}</td>
</tr>
......
......@@ -137,7 +137,6 @@ viewlist.updateOnLoad();
JAVASCRIPT;
$smarty = smarty(array('tablerenderer'), array(), array('viewsubmittedto' => 'mahara'));
$smarty->assign('site_menu', site_menu());
$smarty->assign('INLINEJAVASCRIPT', $javascript);
$smarty->display('view/index.tpl');
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment