Advertisement
Guest User

Untitled

a guest
Jul 24th, 2014
233
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.31 KB | None | 0 0
  1. function myFunction(){
  2. $.messager.show({
  3. title:'My Title',
  4. msg:'The message content',
  5. showType:'fade',
  6. style:{
  7. right:'',
  8. bottom:''
  9. }
  10. });
  11. }
  12.  
  13. $('#controlID').click(myFunction);
  14.  
  15. $(document).ready(function(){
  16. $('#controlID').click(myFunction);
  17. });
  18.  
  19. $(document).ready(function(){
  20. $('#controlID').click(function(){
  21. $.messager.show({
  22. title:'My Title',
  23. msg:'The message content',
  24. showType:'fade',
  25. style:{
  26. right:'',
  27. bottom:''
  28. }
  29. });
  30. });
  31. });
  32.  
  33. $('.someclass').click(myFunction);
  34.  
  35. if(a == 3)
  36. myFunction();
  37.  
  38. myFunction();
  39.  
  40. $(function(){
  41. $('#elementID').click(function(){
  42. myFuntion(); //this will call your function
  43. });
  44. });
  45.  
  46. $(function(){
  47. $('#elementID').click( myFuntion );
  48.  
  49. });
  50.  
  51. if(something){
  52. myFunction(); //this will call your function
  53. }
  54.  
  55. $(document).ready(function(){
  56.  
  57. $('#YourControlID').click(function(){
  58. if(Check your condtion)
  59. {
  60. $.messager.show({
  61. title:'My Title',
  62. msg:'The message content',
  63. showType:'fade',
  64. style:{
  65. right:'',
  66. bottom:''
  67. }
  68. });
  69. }
  70. });
  71. });
  72.  
  73. $(document).ready(function(){
  74.  
  75. $('#YourControlID').click(function(){
  76. if(Check your condtion)
  77. {
  78. $.messager.show({
  79. title:'My Title',
  80. msg:'The message content',
  81. showType:'fade',
  82. style:{
  83. right:'',
  84. bottom:''
  85. }
  86. });
  87. }
  88. });
  89. });
  90.  
  91. $('.button).bind('click', my_fn);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement