summaryrefslogtreecommitdiff
path: root/themes
diff options
context:
space:
mode:
Diffstat (limited to 'themes')
-rw-r--r--themes/default/js/comment.js19
-rw-r--r--themes/default/js/user.js38
-rw-r--r--themes/default/views/page.html.php2
3 files changed, 0 insertions, 59 deletions
diff --git a/themes/default/js/comment.js b/themes/default/js/comment.js
deleted file mode 100644
index 259b4826..00000000
--- a/themes/default/js/comment.js
+++ /dev/null
@@ -1,19 +0,0 @@
-$("document").ready(function() {
- ajaxify_comment_form();
-});
-
-function ajaxify_comment_form() {
- $("#gComments form").ajaxForm({
- complete: function(xhr, statusText) {
- $("#gComments form").replaceWith(xhr.responseText);
- if (xhr.status == 201) {
- $.get(xhr.getResponseHeader("Location"), function(data, textStatus) {
- $("#gComments .gBlockContent ul:first").append("<li>"+data+"</li>");
- $("#gComments .gBlockContent ul:first li:last").hide().slideDown();
- });
- $("#gComments form").clearForm();
- }
- ajaxify_comment_form();
- }
- });
-}
diff --git a/themes/default/js/user.js b/themes/default/js/user.js
deleted file mode 100644
index 8ee543bf..00000000
--- a/themes/default/js/user.js
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * @todo preventDefault() not working in IE 6 and 7
- * @todo Close link should be reusable
- */
-
-$("document").ready(function() {
- $("#gLoginLink").click(function(event){
- event.preventDefault();
- var url = $("#gLoginLink a").attr("href");
- $.get(url, function(data) {
- $('#gLoginLink').hide();
- $("#gLoginMenu").append('<li><a href="#">X</a></li>');
- $("#gLoginMenu li:last").addClass("gClose").show();
- $("#gLoginMenu .gClose a").click(function(){
- $("#gLoginForm").remove();
- $("#gLoginMenu .gClose").remove();
- $("#gLoginLink").show();
- $("input#gUsername").val("");
- $("input#gPassword").val("");
- });
- $("#gLoginFormContainer").html(data).hide().fadeIn();
- ajaxify_login_form();
- });
- });
-});
-
-function ajaxify_login_form() {
- $("form#gLoginForm").ajaxForm({
- target: "#gLoginFormContainer",
- success: function(responseText, statusText) {
- if (!responseText) {
- window.location.reload();
- } else {
- ajaxify_login_form();
- }
- }
- });
-}
diff --git a/themes/default/views/page.html.php b/themes/default/views/page.html.php
index 702595a6..e3da147c 100644
--- a/themes/default/views/page.html.php
+++ b/themes/default/views/page.html.php
@@ -17,8 +17,6 @@
media="screen,print,projection" />
<script src="<?= url::file("lib/jquery.js") ?>" type="text/javascript"></script>
<script src="<?= url::file("lib/jquery.form.js") ?>" type="text/javascript"></script>
- <script src="<?= $theme->url("js/user.js") ?>" type="text/javascript"></script>
- <script src="<?= $theme->url("js/comment.js") ?>" type="text/javascript"></script>
<!-- this stuff will likely be integrated into lib, possibly theme css -->
<link rel="stylesheet" type="text/css" href="<?= $theme->url("jquery/jquery.ui.css") ?>"
media="screen,print,projection" />