disinclined.org
/
git
/
dylansserver.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
6800ac4
)
Got rid of console.log()s and improved formatting
author
Dylan Lloyd
<dylan@psu.edu>
Thu, 10 Mar 2011 09:17:53 +0000
(
04:17
-0500)
committer
Dylan Lloyd
<dylan@psu.edu>
Thu, 10 Mar 2011 09:17:53 +0000
(
04:17
-0500)
includes/ajax.js
patch
|
blob
|
history
index.php
patch
|
blob
|
history
diff --git
a/includes/ajax.js
b/includes/ajax.js
index
2bc9cce
..
10d532d
100644
(file)
--- a/
includes/ajax.js
+++ b/
includes/ajax.js
@@
-35,7
+35,8
@@
$(document).ready(function() {
}
});
} else {
}
});
} else {
- console.log('reCAPTCHA said you\'re not human.');
+ var error = "<span style='font-weight:bold;font-family:sans-serif;color:red;margin-top:15px;'>reCAPTCHA said you're not human</span>";
+ $('#comment').append(error);
}
},
error: function() {
}
},
error: function() {
@@
-46,7
+47,8
@@
$(document).ready(function() {
}
});
} else {
}
});
} else {
- console.log('but you didn\'t write anything!');
+ var error = "<span style='font-weight:bold;font-family:sans-serif;color:red;margin-top:15px;'>but you didn't write anything!<br></span>";
+ $('#submit').before(error);
}
return false;
});
}
return false;
});
diff --git
a/index.php
b/index.php
index
b773705
..
56b216a
100644
(file)
--- a/
index.php
+++ b/
index.php
@@
-489,13
+489,13
@@
END_OF_FORM;
if ($this->failed_captcha) {
echo <<<END_OF_FORM
<span style='font-weight:bold;font-family:sans-serif;color:red;margin-top:15px;'>reCAPTCHA said you're not human,</span>
if ($this->failed_captcha) {
echo <<<END_OF_FORM
<span style='font-weight:bold;font-family:sans-serif;color:red;margin-top:15px;'>reCAPTCHA said you're not human,</span>
- <input class="submit" type="submit" value="try again?">
+ <input
id="submit"
class="submit" type="submit" value="try again?">
</form>
</div>
END_OF_FORM;
} else {
echo <<<END_OF_FORM
</form>
</div>
END_OF_FORM;
} else {
echo <<<END_OF_FORM
- <input class="submit" type="submit" value="post comment">
+ <input
id="submit"
class="submit" type="submit" value="post comment">
</form>
</div>
END_OF_FORM;
</form>
</div>
END_OF_FORM;