Guest User

Untitled

a guest
Feb 6th, 2014
136
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.77 KB | None | 0 0
  1. $(document).ready(function () {
  2. $(".con").load("views/startseite.php", function () {
  3. $(".scroll").jScrollPane({mouseWheelSpeed:20});$(".jspDrag").hide();$(".jspScrollable").mouseenter(function(){$(this).find(".jspDrag").stop(!0,!0).fadeIn()});$(".jspScrollable").mouseleave(function(){$(this).find(".jspDrag").stop(!0,!0).fadeOut()})
  4. });
  5. $("nav a").click(function (a) {
  6. a.preventDefault();
  7. a = $(this).attr("href").split("/").pop().split(".").shift();
  8. $(".con").hide().load("views/" + a + ".php", function () {
  9. $(".con").fadeIn("fast",
  10. function () {
  11. $(".scroll").jScrollPane({mouseWheelSpeed:20});$(".jspDrag").hide();$(".jspScrollable").mouseenter(function(){$(this).find(".jspDrag").stop(!0,!0).fadeIn("slow")});$(".jspScrollable").mouseleave(function(){$(this).find(".jspDrag").stop(!0,!0).fadeOut("slow")})})
  12. });
  13. document.title = "My-Domain.com | " + (a.substr(0, 1).toUpperCase() + a.substr(1));
  14. location.hash = a;
  15. return !1
  16. })
  17. $(document).on('submit', 'form.ajax', function (e) {
  18. e.preventDefault();
  19. var that = $(this),
  20. url = that.attr('action'),
  21. type = that.attr('method'),
  22. data = {};
  23. that.find('[name]').each(function (index, value) {
  24. var that = $(this),
  25. name = that.attr('name'),
  26. value = that.val();
  27. data[name] = value
  28. });
  29. $.ajax({
  30. url: url,
  31. type: type,
  32. data: data,
  33. success: function () {
  34. $(".flipbox").flippy({
  35. color_target: "",
  36. duration: "500",
  37. verso: "Anything!",
  38. onFinish: function () {
  39. $("#no-color").css("background-color", "transparent");
  40. }
  41. });
  42. }
  43. });
  44. });
  45. $(document).on('submit', 'form.lebenslauf', function (e) {
  46. e.preventDefault();
  47. var $this = $(this);
  48. $.ajax({
  49. url: './secure/secure.php',
  50. type: 'post',
  51. data: {
  52. code: $('input[name=bewerbung]').val()
  53. },
  54. success: function (resp) {
  55. if (resp.substr(0, 5) == "Error") {
  56. $('.error').html(resp);
  57. } else {
  58. $('.flipbox').flippy({
  59. duration: "500",
  60. verso: resp,
  61. onFinish: function () {
  62. $(".flipbox").css("background-color", "transparent");
  63. }
  64. });
  65. }
  66. }
  67. });
  68. });
  69. });
Advertisement
Add Comment
Please, Sign In to add comment