Adding content_top and content_bottom in the template system when using the Display::display_header() function

skala
Julio Montoya 14 years ago
parent 71ec07a0b9
commit 02d193083d
  1. 68
      main/template/default/agenda/month.tpl
  2. 15
      main/template/default/layout/layout_1_col.tpl
  3. 26
      main/template/default/layout/layout_2_col.tpl
  4. 1
      main/template/default/layout/main_footer.tpl
  5. 19
      main/template/default/layout/main_header.tpl
  6. 16
      main/template/default/layout/page_body.tpl
  7. 8
      main/template/default/layout/show_footer.tpl

@ -268,11 +268,23 @@ $(document).ready(function() {
$("#dialog-form").dialog({
buttons: {
{"Edit"|get_lang} : function() {
'{"ExportiCalConfidential"|get_lang}' : function() {
url = "ical_export.php?id=" + calEvent.id+'&course_id='+calEvent.course_id+"&class=confidential";
window.location.href = url;
},
'{"ExportiCalPrivate"|get_lang}': function() {
url = "ical_export.php?id=" + calEvent.id+'&course_id='+calEvent.course_id+"&class=private";
window.location.href = url;
},
'{"ExportiCalPublic"|get_lang}': function() {
url = "ical_export.php?id=" + calEvent.id+'&course_id='+calEvent.course_id+"&class=public";
window.location.href = url;
},
'{"Edit"|get_lang}' : function() {
var bValid = true;
bValid = bValid && checkLength( title, "title", 1, 255 );
//bValid = bValid && checkLength( content, "content", 1, 255 );
bValid = bValid && checkLength( title, "title", 1, 255 );
var params = $("#add_event_form").serialize();
$.ajax({
@ -293,7 +305,7 @@ $(document).ready(function() {
}
});
},
{"Delete"|get_lang}: function() {
'{"Delete"|get_lang}': function() {
$.ajax({
url: delete_url,
success:function() {
@ -325,47 +337,21 @@ $(document).ready(function() {
$("#simple_content").html(calEvent.description);
$("#simple-dialog-form").dialog("open");
$("#simple-dialog-form").dialog({
buttons: {
{"Export"|get_lang} : function() {
var params = $("#add_event_form").serialize();
$.ajax({
url: url+'&'+params,
success:function() {
calEvent.title = $("#title").val();
calEvent.start = calEvent.start;
calEvent.end = calEvent.end;
calEvent.allDay = calEvent.allDay;
calEvent.description = $("#content").val();
calendar.fullCalendar('updateEvent',
calEvent,
true // make the event "stick"
);
$("#dialog-form").dialog("close");
}
});
'{"ExportiCalConfidential"|get_lang}' : function() {
url = "ical_export.php?id=" + calEvent.id+'&course_id='+calEvent.course_id+"&class=confidential";
window.location.href = url;
},
{"Export"|get_lang}: function() {
$.ajax({
url: delete_url,
success:function() {
calendar.fullCalendar('removeEvents',
calEvent
);
calendar.fullCalendar("refetchEvents");
calendar.fullCalendar("rerenderEvents");
$("#dialog-form").dialog( "close" );
}
});
'{"ExportiCalPrivate"|get_lang}': function() {
url = "ical_export.php?id=" + calEvent.id+'&course_id='+calEvent.course_id+"&class=private";
window.location.href = url;
},
'{"ExportiCalPublic"|get_lang}': function() {
url = "ical_export.php?id=" + calEvent.id+'&course_id='+calEvent.course_id+"&class=public";
window.location.href = url;
}
},
close: function() {
}
});

@ -7,17 +7,10 @@
{/block}
{* 1 column *}
{block name=body}
<div class="span12">
{if !empty($plugin_content_top)}
<div id="plugin_content_top">
{$plugin_content_top}
</div>
{/if}
{include file="default/layout/page_body.tpl"}
<section id="main_content">
{* Main content *}
{$content}
</section>
<div class="span12">
{include file="default/layout/page_body.tpl"}
{* Content bottom *}
{if !empty($plugin_content_bottom)}
<div class="clear"></div>
<div id="plugin_content_bottom">

@ -14,15 +14,7 @@
{include file="default/layout/sniff.tpl"}
{/if}
<div class="span9">
{* Content top*}
{if !empty($plugin_content_top)}
<div id="plugin_content_top">
{$plugin_content_top}
</div>
{/if}
<div class="span9">
{* ?? *}
<section id="home_page">
{$home_page_block}
@ -31,12 +23,7 @@
{* ?? *}
{$sniff_notification}
{include file="default/layout/page_body.tpl"}
{* Main content*}
<section id="main_content">
{$content}
</section>
{include file="default/layout/page_body.tpl"}
{* Announcements *}
<section id="announcements_page">
@ -48,13 +35,16 @@
{include file="default/layout/hot_courses.tpl"}
{* fix the bug where the login is at the left side*}
&nbsp;
</section>
</section>
{if !empty($plugin_content_bottom)}
{* Content bottom *}
{if !empty($plugin_content_bottom)}
<div class="clear"></div>
<div id="plugin_content_bottom">
{$plugin_content_bottom}
</div>
{/if}
{/if}
</div>
{* Right column *}

@ -1,4 +1,3 @@
</div> <!-- end of #row" -->
</div> <!-- end of #main" -->
<div class="push"></div>

@ -101,8 +101,7 @@
/* <![CDATA[ */
function createCookie(name, value, days) {
if (days)
{
if (days) {
var date = new Date();
date.setTime(date.getTime()+(days*24*60*60*1000));
var expires = "; expires="+date.toGMTString();
@ -110,8 +109,7 @@
else var expires = "";
document.cookie = name+"="+value+expires+"; path=/";
}
function readCookie(name)
{
function readCookie(name) {
var nameEQ = name + "=";
var ca = document.cookie.split(';');
for (var i = 0; i < ca.length; i++)
@ -122,14 +120,12 @@
}
return null;
}
function swap_menu()
{
function swap_menu() {
toolnavlist_el = document.getElementById('toolnavlist');
center_el = document.getElementById('center');
swap_menu_link_el = document.getElementById('swap_menu_link');
if (toolnavlist_el.style.display == 'none')
{
if (toolnavlist_el.style.display == 'none') {
toolnavlist_el.style.display = '';
if (center_el)
{
@ -137,9 +133,7 @@
}
swap_menu_link_el.innerHTML = '<?php echo get_lang('Hide'); ?> &raquo;&raquo;';
createCookie('dokeos_menu_state',1,10);
}
else
{
} else {
toolnavlist_el.style.display = 'none';
if (center_el)
{
@ -154,7 +148,6 @@
</script>
<div class="span12">
{$show_course_navigation_menu}
</div>
</div>
{/if}
{/if}

@ -1,3 +1,11 @@
{* Content top *}
{if !empty($plugin_content_top)}
<div id="plugin_content_top">
{$plugin_content_top}
</div>
{/if}
{* Actions *}
{if (!empty($actions)) }
<div class="actions">
@ -15,4 +23,10 @@
{* Show messages*}
<section id="messages">
{$message}
</section>
</section>
{* Main content*}
<section id="main_content">
{$content}
</section>

@ -5,4 +5,12 @@
{if $show_header}
</div>
{/if}
{* Content bottom *}
{if !empty($plugin_content_bottom)}
<div class="clear"></div>
<div id="plugin_content_bottom">
{$plugin_content_bottom}
</div>
{/if}
{include file="default/layout/main_footer.tpl"}
Loading…
Cancel
Save