Advertisement
Guest User

Untitled

a guest
Apr 19th, 2014
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 8.70 KB | None | 0 0
  1. <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
  2.  
  3.  
  4. <link rel="stylesheet" href="css/validationEngine.jquery.css" type="text/css"/>
  5. <link rel="stylesheet" href="css/template.css" type="text/css"/>
  6. <script src="js/jquery-1.8.2.min.js" type="text/javascript">
  7. </script>
  8. <script src="js/languages/jquery.validationEngine-en.js" type="text/javascript" charset="utf-8">
  9. </script>
  10. <script src="js/jquery.validationEngine.js" type="text/javascript" charset="utf-8">
  11. </script>
  12. <script type="text/javascript">
  13. jQuery(document).ready(function ($) {
  14. //Set default open/close settings
  15. var divs=$('.accordion>div').hide(); //Hide/close all containers
  16.  
  17. var h2s=$('.accordion>h2').click(function () {
  18. h2s.not(this).removeClass('active')
  19. //alert("TRY");
  20. $(this).toggleClass('active')
  21. divs.not($(this).next()).slideUp()
  22. $(this).next().slideToggle()
  23. return false; //Prevent the browser jump to the link anchor
  24. });
  25.  
  26. jQuery('h2.acc_trigger').show();
  27.  
  28.  
  29. $('h2.acc_trigger').click(function () {
  30. $('h2.acc_trigger .arrhead').css('content','url(images/arrowleft.png)');
  31. if($(this).hasClass('active')){
  32. $('h2.acc_trigger.active .arrhead').css('content','url(images/arrowdown.png)');
  33. $(this).hide();
  34. }else{
  35. $('h2').hasClass('h2.acc_trigger').show();
  36. }
  37.  
  38. });
  39.  
  40.  
  41.  
  42.  
  43.  
  44. });
  45. </script>
  46.  
  47. <style type="text/css">
  48. h2.acc_trigger {
  49. padding: 0;
  50. margin: 0 0 5px -42px;
  51. height: 46px;
  52. line-height: 46px;
  53. width: 800px;
  54. font-size: 21px;
  55. font-weight: normal;
  56. float: left;
  57. margin-bottom:0;
  58. }
  59.  
  60. .third{
  61. /*content: url(images/arrowleft.png);*/
  62. position: absolute;
  63. margin: 0 0 0 640px;
  64. float: left;
  65. display: block;
  66. width: 315px;
  67. }
  68.  
  69. h2.acc_trigger.active{
  70. /*content: url(images/arrowdown.png);*/
  71. }
  72.  
  73. h2.acc_trigger a {
  74. color: #222;
  75. text-decoration: none;
  76. display: block;
  77. padding: 0 0 0 50px;
  78. }
  79. h2.acc_trigger.active a {
  80. color: #FF0000;
  81. }
  82. h2.acc_trigger a:hover {
  83. color: #999;
  84. }
  85. h2.acc_trigger a:active, h2.active {
  86. color:#ED2224;
  87.  
  88. }
  89. h2.active {
  90. background-position: left bottom;
  91. /*content: url(images/arrowdown.png);*/
  92. }
  93. .acc_container {
  94. margin: 0 0 5px;
  95. padding: 0;
  96. overflow: hidden;
  97. font-size: 1.2em;
  98. width: 835px;
  99. clear: both;
  100. background: #f0f0f0;
  101. border: 1px solid #d6d6d6;
  102. -webkit-border-bottom-right-radius: 5px;
  103. -webkit-border-bottom-left-radius: 5px;
  104. -moz-border-radius-bottomright: 5px;
  105. -moz-border-radius-bottomleft: 5px;
  106. border-bottom-right-radius: 5px;
  107. border-bottom-left-radius: 5px;
  108. border-top:none;
  109. }
  110. .acc_container .block {
  111. padding: 20px;
  112. }
  113.  
  114. .accordion{
  115. width: 150px;
  116. margin: 80px 0 0 270px;
  117. }
  118.  
  119. .content{
  120. /*position:relative;*/
  121. display:block;
  122. /*margin-top:15px;*/
  123. margin-top:45px;
  124. }
  125.  
  126. .inputfield{
  127. border-radius:5px;
  128. margin-left:165px;
  129. position:relative;
  130. margin-top: -26px;
  131. width: 205px;
  132. height: 30px;
  133. display:inherit;
  134. }
  135.  
  136. .rightblock{
  137. position: relative;
  138. margin-left: 400px;
  139. /* margin-top: -78px; */
  140. bottom: 215px;
  141. }
  142.  
  143. .sec{
  144. width:620px;
  145. }
  146.  
  147. .tattoo{
  148. font-size:35px;
  149. /*text-align:center;
  150. margin-left:27px;*/
  151.  
  152. width: 150px;
  153. margin-left: 295px;
  154. }
  155. .tattoo p{
  156. font-size: 20px;
  157. margin-top: 0px;
  158. width: 150px;
  159. margin-left: 270px;
  160. }
  161.  
  162. .live{
  163. position: absolute;
  164. /* margin-top: -65px; */
  165. margin: -65px 0 0 60%;
  166. font-size: 27px;
  167. }
  168.  
  169. .note{
  170. position: absolute;
  171. width: 315px;
  172. margin: 25px 0 0 10px;
  173. text-align: center;
  174. background-color: #303030;
  175. color: white;
  176. border-radius: 5px;
  177. padding: 18px;
  178. font-size: 15px;
  179. }
  180.  
  181. .line{
  182. border: 5px black;
  183. width: 840px;
  184. background-color: black;
  185. margin: -10px 0 0 -8px;
  186. position: absolute;
  187. height: 1px;
  188. display: block;
  189. }
  190.  
  191. .submit{
  192. top: 15px;
  193. position: relative;
  194. width: 110px;
  195. height: 30px;
  196. border-radius: 5px;
  197. font-size: 18px;
  198. }
  199.  
  200. label.error{
  201. margin: -25px 0 0 394px;
  202. position: absolute;
  203. }
  204.  
  205. .error{
  206. border-color:red;
  207. color:red;
  208.  
  209. }
  210.  
  211. .title{
  212. position: absolute;
  213. left: 278px;
  214. margin-top: 20px;
  215. font-weight: bold;
  216. font-size: 25px;
  217. }
  218.  
  219. .first{
  220. position:absolute;
  221. margin-left: 60px;
  222. width: 315px;
  223. }
  224.  
  225. .second{
  226. position:absolute;
  227. margin-left: 290px;
  228. width: 315px;
  229. }
  230.  
  231. .third{
  232.  
  233. }
  234.  
  235. </style>
  236.  
  237. <script type='text/javascript'>
  238. jQuery(document).ready(function(){
  239. jQuery("#myform").validationEngine('attach', {
  240. onValidationComplete: function(form, status){
  241. alert("The form status is: " +status+", it will never submit");
  242. }
  243. })
  244. });
  245.  
  246.  
  247. </script>
  248.  
  249. <div class="title">Account Settings</div>
  250. <form action="" id="myform" method="post">
  251. <div class="accordion">
  252. <h2 class="acc_trigger"><a href="#"><label class="first">Name</label><label class="second">Juan Dela Cruz</label><label class="third">Edit</label></a></h2>
  253. <div class="acc_container">
  254. <div class="block">
  255. <div class="leftblock">
  256. <label class="content" id="username">New username: <input type="text" class="validate[required] text-input inputfield" id="inputusername" name="inputusername"></label>
  257. <label class="content" id="password">New password: <input type="text" class="validate[required] text-input inputfield" id="inputpassword" name="inputpassword"></label>
  258. <label class="content" id="password">Re-type password: <input type="text" class="validate[required] text-input inputfield" id="inputrepassword" name="inputrepassword"></label>
  259. </div>
  260. </div>
  261. </div>
  262. <h2 class="acc_trigger"><a href="#"><label class="first">Username</label><label class="second">globeJuan</label><label class="third">Edit</label></a></h2>
  263. <div class="acc_container">
  264. <div class="block">
  265. <div class="leftblock">
  266. <label class="content" id="username">New username: <input type="text" class="validate[required] text-input inputfield" id="inputusername" name="inputusername"></label>
  267. <label class="content" id="password">New password: <input type="text" class="validate[required] text-input inputfield" id="inputpassword" name="inputpassword"></label>
  268. <label class="content" id="password">Re-type password: <input type="text" class="validate[required] text-input inputfield" id="inputrepassword" name="inputrepassword"></label>
  269. </div>
  270. </div>
  271. </div>
  272. <h2 class="acc_trigger"><a href="#"><label class="first">Password</label><label class="second">password last changed on 06/13/2013</label><label class="third">Edit</label></a></h2>
  273. <div class="acc_container">
  274. <div class="block">
  275. <div class="leftblock">
  276. <label class="content" id="username">New username: <input type="text" class="validate[required] text-input inputfield" id="inputusername" name="inputusername"></label>
  277. <label class="content" id="password">New password: <input type="text" class="validate[required] text-input inputfield" id="inputpassword" name="inputpassword"></label>
  278. <label class="content" id="password">Re-type password: <input type="text" class="validate[required] text-input inputfield" id="inputrepassword" name="inputrepassword"></label>
  279. </div>
  280. </div>
  281. </div>
  282. <h2 class="acc_trigger"><a href="#"><label class="first">Email Address</label><label class="second">juandc@email.com</label><label class="third">Edit</label></a></h2>
  283. <div class="acc_container">
  284. <div class="block">
  285. <div class="leftblock">
  286. <label class="content" id="username">New username: <input type="text" class="validate[required] text-input inputfield" id="inputusername" name="inputusername"></label>
  287. <label class="content" id="password">New password: <input type="text" class="validate[required] text-input inputfield" id="inputpassword" name="inputpassword"></label>
  288. <label class="content" id="password">Re-type password: <input type="text" class="validate[required] text-input inputfield" id="inputrepassword" name="inputrepassword"></label>
  289. </div>
  290. </div>
  291. </div>
  292. <h2 class="acc_trigger"><a href="#"><label class="first">Mobile Number</label><label class="second">09271234567</label><label class="third">Edit</label></a></h2>
  293. <div class="acc_container">
  294. <div class="block">
  295. <div class="leftblock">
  296. <label class="content" id="username">New username: <input type="text" class="validate[required] text-input inputfield" id="inputusername" name="inputusername"></label>
  297. <label class="content" id="password">New password: <input type="text" class="validate[required] text-input inputfield" id="inputpassword" name="inputpassword"></label>
  298. <label class="content" id="password">Re-type password: <input type="text" class="validate[required] text-input inputfield" id="inputrepassword" name="inputrepassword"></label>
  299. </div>
  300. </div>
  301. </div>
  302. </div>
  303. </form>
  304.  
  305. $('h2') . hasClass('acc_trigger') . show();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement