Skip to content

Commit

Permalink
SAK-23873 use headscripts includeLatestJquery instead of manual loading
Browse files Browse the repository at this point in the history
  • Loading branch information
ottenhoff committed Jul 29, 2015
1 parent 1da3129 commit 20526fe
Show file tree
Hide file tree
Showing 95 changed files with 117 additions and 182 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@ function resizeFrame(){
}
}
</script>
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery('announcements');</script>
<link href="/library/js/jquery/ui/1.11.3/themes/ui-lightness/jquery-ui.min.css" rel="stylesheet" type="text/css" />
<script type="text/javascript">
$(document).ready(function() {
Expand Down
4 changes: 2 additions & 2 deletions assignment/assignment-tool/tool/src/webapp/chef_header.vm
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
## This is here so that we can add extra bits to the <head> of the page.

#header_prepend('<link href="/sakai-assignment-tool/css/assignment.css" type="text/css" rel="stylesheet" media="all" />')
#header_append('<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>')
#header_append('<script type="text/javascript" src="/sakai-assignment-tool/js/assignments.js"></script>')
#header_append('<script type="text/javascript">includeLatestJQuery("assignment_chef_header");</script>')
#header_append('<script type="text/javascript" src="/sakai-assignment-tool/js/assignments.js"></script>')

#chef_start()
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!-- $Id$ -->
<!-- start: check_assignments_instructor_grading_submission.vm -->
#set( $H = '-' )
<script type="text/javascript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery('assignments');</script>
<link href="/library/js/jquery/ui/1.11.3/themes/ui-lightness/jquery-ui.min.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="/library/js/lang-datepicker/lang-datepicker.js"></script>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!-- $Id$ -->
<!-- start: chef_assignments_instructor_list_submissions.vm -->
#set( $H = '-' )
<script type="text/javascript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery('assignments');</script>
<link href="/library/js/jquery/ui/1.11.3/themes/ui-lightness/jquery-ui.min.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="/library/js/lang-datepicker/lang-datepicker.js"></script>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@
## Assignments - Instructor new Assignment view
#set( $H = '-' )

<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery('assignments');</script>
<link href="/library/js/jquery/ui/1.11.3/themes/ui-lightness/jquery-ui.min.css" rel="stylesheet" type="text/css" />
<link href="/sakai-assignment-tool/css/assignment.css" type="text/css" rel="stylesheet" />

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!-- $Id$ -->
<!-- start: chef_assignments_student_view_grade.vm -->
##<!-- $Header: /cvs/sakai2/legacy/tools/src/webapp/vm/assignment/chef_assignments_student_view_grade.vm,v 1.2 2005/05/19 19:39:49 gsilver.umich.edu Exp $ -->
<script type="text/javascript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery('assignments');</script>
<link href="/library/js/jquery/ui/1.11.3/themes/ui-lightness/jquery-ui.min.css" rel="stylesheet" type="text/css" />
<script type="text/javascript">
$(document).ready(function(){
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -198,8 +198,7 @@
<input type="hidden" name="sakai_csrf_token" value="$sakai_csrf_token" />
</form>
</div>
<script type="text/javascript" src="#libraryLink('js/jquery/jquery-1.9.1.min.js')">
</script>
<script type="text/javascript">includeLatestJQuery('chef_resources_more');</script>
<script type="text/javascript">
function openCopyrightWindow(theURL,winName,winSettings)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ ul.makeMenu li {
</style>
<![endif]><![endif]-->

<script type="text/javascript">includeLatestJQuery('content_filepicker');</script>
<script type="text/JavaScript">
function openCopyrightWindow(theURL,winName,winSettings)
{
Expand All @@ -51,7 +52,6 @@ ul.makeMenu li {
}
}
</script>
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"> </script>
<script type="text/javascript">
$(document).ready(function() {
jQuery('.portletBody').click(function(e) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,7 @@
## version: $Id: $
<!-- sakai_resources_list.vm, use with org.sakaiproject.content.tool.ResourcesAction.java -->
<!-- this is the new list template, which uses the resources type registry -->
<script type="text/javascript">
if ( window.jQuery ) {
window.console && console.log("jQuery already loaded "+jQuery.fn.jquery);
} else {
document.write('\x3Cscript type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js?version=">'+'\x3C/script>')
window.console && console.log("Loaded jQuery");
}
</script>
<script type="text/javascript">includeLatestJQuery('content');</script>

<script type="text/javascript" src="/library/js/bootstrap/3.1.1/js/bootstrap.min.js">
<!-- // -->
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!-- resources/sakai_dropbox_multiple_folders_upload.vm, use with org.sakaiproject.tool.content.ResourcesAction.java -->
<script type="text/javascript" src="#libraryLink('js/jquery/jquery-1.9.1.min.js')"></script>
<script type="text/javascript">includeLatestJQuery('content_dropbox_multiple');</script>

<div class="portletBody specialLink">
<h3>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
##<textarea id="debugger" rows="50" cols="100"></textarea>
<script type="text/javascript" src="#libraryLink('js/jquery/jquery-1.9.1.min.js')"></script>
<script type="text/javascript">includeLatestJQuery('content_sakai_properties');</script>
<script type="text/javascript" src="#libraryLink('js/jquery/cookie/jquery.cookie.js')"></script>
<script type="text/javascript">
<!--
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,9 @@
-->
<link rel="stylesheet" type="text/css" href="bootstrap/css/bootstrap.min.css" />
<link rel="stylesheet" type="text/css" href="bootstrap/css/bootstrap-responsive.min.css" />

<link rel="stylesheet" type="text/css" href="/library/js/jquery/ui/1.8.4/css/ui-lightness/jquery-ui-1.8.4.full.css" />
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js">
</script>
<script type="text/javascript" src="/library/js/jquery/ui/1.8.4/jquery-ui-1.8.4.full.min.js">
</script>
<script type="text/javascript" src="js/dashboard.js">
</script>
<link rel="stylesheet" type="text/css" href="/library/js/jquery/ui/1.11.3/themes/ui-lightness/jquery-ui.min.css" />
<script type="text/javascript"> includeLatestJQuery('dashboard'); </script>
<script type="text/javascript" src="js/dashboard.js"> </script>
<div id="messagePanel" style="display:none">
</div>
<div id="messageError" style="display:none">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,13 @@

<title rsf:id="msg=gradebook.add-gradebook-item.title">Gradebook</title>

<script type="text/javascript" language="JavaScript" src="/library/js/headscripts.js"></script>
<!-- vm/editor/FCKeditor/sakai_header.vm -->
<script type="text/javascript" src="/library/editor/FCKeditor/fckeditor.js"></script>

<link href="/library/skin/tool_base.css" type="text/css" rel="stylesheet" media="all"/>
<link href="/library/skin/default/tool.css" type="text/css" rel="stylesheet" media="all"/>
<script type="text/javascript" language="JavaScript" src="/library/js/headscripts.js"></script>
<script type="text/javascript" language="JavaScript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="/library/js/headscripts.js"></script>
<script type="text/javascript">includeLatestJQuery('gradebook');</script>
<link href="/sakai-assignment2-tool/content/css/assignmentsv4.css" type="text/css" rel="stylesheet" media="all" />

</head>
Expand All @@ -25,4 +24,4 @@
</ul>
</div>
</body>
</html>
</html>
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,13 @@

<title rsf:id="msg=gradebook.add-gradebook-item.title">Gradebook</title>

<script type="text/javascript" language="JavaScript" src="/library/js/headscripts.js"></script>
<!-- vm/editor/FCKeditor/sakai_header.vm -->
<script type="text/javascript" src="/library/editor/FCKeditor/fckeditor.js"></script>

<link href="/library/skin/tool_base.css" type="text/css" rel="stylesheet" media="all"/>
<link href="/library/skin/default/tool.css" type="text/css" rel="stylesheet" media="all"/>
<script type="text/javascript" language="JavaScript" src="/library/js/headscripts.js"></script>
<script type="text/javascript" language="JavaScript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="/library/js/headscripts.js"></script>
<script type="text/javascript">includeLatestJQuery('gradebook');</script>
<link href="/sakai-assignment2-tool/content/css/assignmentsv4.css" type="text/css" rel="stylesheet" media="all" />

</head>
Expand All @@ -25,4 +24,4 @@
</ul>
</div>
</body>
</html>
</html>
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,14 @@

<title rsf:id="msg=gradebook.grade-gradebook-item.title">Gradebook</title>

<script type="text/javascript" language="JavaScript" src="/library/js/headscripts.js"></script>
<!-- vm/editor/FCKeditor/sakai_header.vm -->
<script type="text/javascript" src="/library/editor/FCKeditor/fckeditor.js"></script>

<link href="/library/skin/tool_base.css" type="text/css" rel="stylesheet" media="all"/>
<link href="/library/skin/default/tool.css" type="text/css" rel="stylesheet" media="all"/>
<script type="text/javascript" language="JavaScript" src="/library/js/headscripts.js"></script>
<script type="text/javascript" language="JavaScript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" language="JavaScript" src="/sakai-gradebook-tool/content/js/grade-gradebook-item.js"></script>
<script type="text/javascript" src="/library/js/headscripts.js"></script>
<script type="text/javascript">includeLatestJQuery('gradebook');</script>
<script type="text/javascript" src="/sakai-gradebook-tool/content/js/grade-gradebook-item.js"></script>
<link href="/sakai-gradebook-tool/content/css/gradebook.css" type="text/css" rel="stylesheet" media="all" />
</head>
<body>
Expand Down Expand Up @@ -54,4 +53,4 @@ <h3 rsf:id="heading">Grade Gradebook Item</h3>
</form>
</div>
</body>
</html>
</html>
4 changes: 1 addition & 3 deletions gradebook/app/ui/src/webapp/roster.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,8 @@
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<c:set var="const" value="32"/>


<f:view>
<script type="text/javascript" language="JavaScript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" language="JavaScript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery('gradebook_roster');</script>
<script type="text/javascript" src="${pageContext.request.contextPath}/js/spreadsheetUI.js"></script>
<script type="text/javascript" src="${pageContext.request.contextPath}/js/dialog.js"></script>
<link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/dialog.css" />
Expand Down
8 changes: 1 addition & 7 deletions msgcntr/messageforums-app/src/webapp/js/messages.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,15 +76,9 @@ $(document).ready(function(){
});
});
}
// I need UI js
// I need jquery-UI js
// But we'll assume its already on the page so we don't break other scripts by loading an outdated version
loadUI();
// if (!$.progressbar) {
// $.getScript("/library/js/jquery/ui/1.11.3/jquery-ui.min.js",loadUI);
// } else {
// loadUI();

// }
});

function changeSelect(obj) {
Expand Down
3 changes: 1 addition & 2 deletions msgcntr/messageforums-app/src/webapp/jsp/compose.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@
<link rel="stylesheet" href="/library/js/jquery/select2/4.0.0/select2.css" type="text/css" />
<link rel="stylesheet" href="/messageforums-tool/css/messages.css" type="text/css" />
<link rel="stylesheet" href="/library/js/jquery/ui/1.11.3/themes/ui-lightness/jquery-ui.min.css" type="text/css" />
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<script type="text/javascript" src="/library/js/jquery/select2/4.0.0/select2.min.js"></script>
<sakai:script contextBase="/messageforums-tool" path="/js/sak-10625.js"/>
<sakai:script contextBase="/messageforums-tool" path="/js/messages.js"/>
Expand Down
2 changes: 1 addition & 1 deletion msgcntr/messageforums-app/src/webapp/jsp/dfCompose.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<h:form id="dfCompose">
<f:verbatim><input type="hidden" id="currentTopicId" name="currentTopicId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedTopic.topic.id}"/><f:verbatim>"/></f:verbatim>
<f:verbatim><input type="hidden" id="currentForumId" name="currentForumId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedForum.forum.id}"/><f:verbatim>"/></f:verbatim>
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<sakai:script contextBase="/messageforums-tool" path="/js/sak-10625.js"/>
<sakai:script contextBase="/messageforums-tool" path="/js/forum.js"/>
<sakai:script contextBase="/messageforums-tool" path="/js/messages.js"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<f:verbatim><input type="hidden" id="currentMessageId" name="currentMessageId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedMessage.message.id}"/><f:verbatim>"/></f:verbatim>
<f:verbatim><input type="hidden" id="currentTopicId" name="currentTopicId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedTopic.topic.id}"/><f:verbatim>"/></f:verbatim>
<f:verbatim><input type="hidden" id="currentForumId" name="currentForumId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedForum.forum.id}"/><f:verbatim>"/></f:verbatim>
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<script type="text/javascript">
$(document).ready(function() {
$('#openLinkBlock').hide();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<f:verbatim><input type="hidden" id="currentMessageId" name="currentMessageId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedMessage.message.id}"/><f:verbatim>"/></f:verbatim>
<f:verbatim><input type="hidden" id="currentTopicId" name="currentTopicId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedTopic.topic.id}"/><f:verbatim>"/></f:verbatim>
<f:verbatim><input type="hidden" id="currentForumId" name="currentForumId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedForum.forum.id}"/><f:verbatim>"/></f:verbatim>
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<sakai:script contextBase="/messageforums-tool" path="/js/sak-10625.js"/>
<sakai:script contextBase="/messageforums-tool" path="/js/forum.js"/>
<sakai:script contextBase="/messageforums-tool" path="/js/messages.js"/>
Expand Down
2 changes: 1 addition & 1 deletion msgcntr/messageforums-app/src/webapp/jsp/dfMoveThreads.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<f:verbatim><input type="hidden" id="currentMessageId" name="currentMessageId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedMessage.message.id}"/><f:verbatim>"/></f:verbatim>
<f:verbatim><input type="hidden" id="currentTopicId" name="currentTopicId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedTopic.topic.id}"/><f:verbatim>"/></f:verbatim>
<f:verbatim><input type="hidden" id="currentForumId" name="currentForumId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedForum.forum.id}"/><f:verbatim>"/></f:verbatim>
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<sakai:script contextBase="/messageforums-tool" path="/js/sak-10625.js"/>
<sakai:script contextBase="/messageforums-tool" path="/js/forum.js"/>
<script type="text/javascript">
Expand Down
2 changes: 1 addition & 1 deletion msgcntr/messageforums-app/src/webapp/jsp/dfMsgRevise.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<style type="text/css">
@import url("/messageforums-tool/css/msgcntr.css");
</style>
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<sakai:script contextBase="/messageforums-tool" path="/js/sak-10625.js"/>
<sakai:script contextBase="/messageforums-tool" path="/js/forum.js"/>
<sakai:script contextBase="/messageforums-tool" path="/js/messages.js"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@
</jsp:useBean>
<f:view>
<sakai:view title="#{msgs.cdfm_discussion_forum_settings}" toolCssHref="/messageforums-tool/css/msgcntr.css">
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<sakai:script contextBase="/messageforums-tool" path="/js/sak-10625.js"/>
<script type="text/javascript" src="/messageforums-tool/js/jquery.charcounter.js"> </script>
<sakai:script contextBase="/messageforums-tool" path="/js/permissions_header.js"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@
</jsp:useBean>
<f:view>
<sakai:view title="#{msgs.cdfm_discussion_topic_settings}" toolCssHref="/messageforums-tool/css/msgcntr.css">
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<sakai:script contextBase="/messageforums-tool" path="/js/sak-10625.js"/>
<script type="text/javascript" src="/messageforums-tool/js/jquery.charcounter.js"> </script>
<sakai:script contextBase="/messageforums-tool" path="/js/permissions_header.js"/>
Expand Down
2 changes: 1 addition & 1 deletion msgcntr/messageforums-app/src/webapp/jsp/dfTopicReply.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<f:verbatim><input type="hidden" id="currentMessageId" name="currentMessageId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedMessage.message.id}"/><f:verbatim>"/></f:verbatim>
<f:verbatim><input type="hidden" id="currentTopicId" name="currentTopicId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedTopic.topic.id}"/><f:verbatim>"/></f:verbatim>
<f:verbatim><input type="hidden" id="currentForumId" name="currentForumId" value="</f:verbatim><h:outputText value="#{ForumTool.selectedForum.forum.id}"/><f:verbatim>"/></f:verbatim>
<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<sakai:script contextBase="/messageforums-tool" path="/js/sak-10625.js"/>
<sakai:script contextBase="/messageforums-tool" path="/js/messages.js"/>
<!--jsp/dfTopicReply.jsp-->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
<link rel="stylesheet" href="/library/js/jquery/ui/1.11.3/themes/ui-lightness/jquery-ui.min.css" type="text/css" />
<link rel="stylesheet" href="/messageforums-tool/css/forum_rank.css" type="text/css" />

<script type="text/javascript" src="/library/js/jquery/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="/library/js/jquery/ui/1.11.3/jquery-ui.min.js"></script>
<script type="text/javascript">includeLatestJQuery("msgcntr");</script>
<script type="text/javascript" src="/messageforums-tool/js/fluidframework-min.js"></script>
<script type="text/javascript" src="/messageforums-tool/js/json2.js"></script>
<script type="text/javascript" src="/messageforums-tool/js/Scroller.js"></script>
Expand Down
Loading

0 comments on commit 20526fe

Please sign in to comment.