script.js 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417
  1. (function($) { $(document).ready(function() {
  2. //console.log($('div#menu-trigger-level1'));
  3. /* accordéon pour des views pane */
  4. $('div.accordion-h2.accordion-h2-views div.view-header').click(function() {
  5. $(this).siblings('div.view-content').toggle('fast', function() {
  6. $(this).parent().parent().parent().toggleClass('accordion-h2-opened');
  7. });
  8. });
  9. /* accordéon pour des panels pane */
  10. $('div.accordion-h2.accordion-h2-panel > h2.pane-title').click(function() {
  11. $(this).siblings('div.pane-content').toggle('fast', function() {
  12. $(this).parent().toggleClass('accordion-h2-opened');
  13. });
  14. });
  15. /* accordéon auto-exclusifs pour des panels pane */
  16. $('div.accordion-h2-ex.accordion-h2-panel > h2.pane-title').click(function() {
  17. $(this).parent().siblings('div.accordion-h2-ex').children('div.pane-content').hide();
  18. $(this).parent().siblings('div.accordion-h2-ex').removeClass('accordion-h2-opened');
  19. $(this).siblings('div.pane-content').toggle('fast', function() {
  20. $(this).parent().toggleClass('accordion-h2-opened');
  21. });
  22. });
  23. /* accordéon pour des panels pane */
  24. $('div.accordion-trigger').click(function() {
  25. $(this).toggleClass('accordion-h2-opened');
  26. $(this).parent().parent().siblings('div.accordion-content').toggle('fast', function() {
  27. });
  28. $(this).siblings('div.accordion-content').toggle('fast', function() {
  29. });
  30. });
  31. $('div#menu-trigger-level1').click(function() {
  32. $('#block-menu_block-3').slideDown('slow', function() {
  33. // Animation complete.
  34. });
  35. $('div#menu-trigger-level1').hide();
  36. $('div#menu-trigger-level1-off').show();
  37. });
  38. $('div#menu-trigger-level1-off').click(function() {
  39. $('#block-menu_block-3').slideUp('slow', function() {
  40. // Animation complete.
  41. });
  42. $('div#menu-trigger-level1-off').hide();
  43. $('div#menu-trigger-level1').show();
  44. });
  45. $('.flexslider').flexslider({
  46. /*selector: 'ul > li',*/
  47. animation: "fade",
  48. animationLoop: true,
  49. itemWidth: "100%",
  50. /*itemMargin: 0,
  51. minItems: 1,*/
  52. controlNav: false, //Boolean: Create navigation for paging control of each clide? Note: Leave true for manualControls usage
  53. directionNav: false, //Boolean: Create navigation for previous/next navigation? (true/false)
  54. prevText: "Précédent", //String: Set the text for the "previous" directionNav item
  55. nextText: "Suivant",
  56. /*maxItems: 10,*/
  57. /*start: function(slider){
  58. $('body').removeClass('loading');
  59. }*/
  60. });
  61. /* AMSTERDAM */
  62. $("#point-nid-870").popover({
  63. title: false,
  64. trigger: "hover",
  65. content: "<ul>" +
  66. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  67. "</ul>"
  68. });
  69. /* BARCELONE */
  70. $("#point-nid-871").popover({
  71. title: false,
  72. trigger: "hover",
  73. content: "<ul>" +
  74. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  75. "</ul>"
  76. });
  77. /* BERLIN */
  78. $("#point-nid-872").popover({
  79. title: false,
  80. trigger: "hover",
  81. content: "<ul>" +
  82. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  83. "</ul>"
  84. });
  85. /* BIRMINGHAM */
  86. $("#point-nid-873").popover({
  87. title: false,
  88. trigger: "hover",
  89. content: "<ul>" +
  90. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  91. "</ul>"
  92. });
  93. /* BORDEAUX */
  94. $("#point-nid-869").popover({
  95. title: false,
  96. trigger: "hover",
  97. content: "<ul><li class='popsu1'><a href='/popsu1/bordeaux/presentation'>POPSU France 1</a></li>" +
  98. "<li class='popsu2'><a href='/popsu2/bordeaux/presentation-0'>POPSU France 2</a></li>" +
  99. "</ul>"
  100. });
  101. /* BRUXELLES */
  102. $("#point-nid-874").popover({
  103. title: false,
  104. trigger: "hover",
  105. content: "<ul>" +
  106. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  107. "</ul>"
  108. });
  109. /* Copenhague */
  110. $("#point-nid-875").popover({
  111. title: false,
  112. trigger: "hover",
  113. content: "<ul>" +
  114. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  115. "</ul>"
  116. });
  117. /* dordrecht */
  118. $("#point-nid-961").popover({
  119. title: false,
  120. trigger: "hover",
  121. content: "<ul>" +
  122. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  123. "</ul>"
  124. });
  125. /* dunkerque */
  126. $("#point-nid-962").popover({
  127. title: false,
  128. trigger: "hover",
  129. content: "<ul>" +
  130. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  131. "</ul>"
  132. });
  133. /* GRENOBLE */
  134. $("#point-nid-876").popover({
  135. title: false,
  136. trigger: "hover",
  137. content: "<ul>" +
  138. "<li class='popsu2'><a href='/popsu2/grenoble/presentation-0'>POPSU France 2</a></li>" +
  139. "</ul>"
  140. });
  141. /* Hambourg */
  142. $("#point-nid-963").popover({
  143. title: false,
  144. trigger: "hover",
  145. content: "<ul>" +
  146. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  147. "</ul>"
  148. });
  149. /* LAUSANNE */
  150. $("#point-nid-877").popover({
  151. title: false,
  152. trigger: "hover",
  153. content: "<ul>" +
  154. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  155. "</ul>"
  156. });
  157. /* LILLE */
  158. $("#point-nid-878").popover({
  159. title: false,
  160. trigger: "hover",
  161. content: "<ul>" +
  162. "<li class='popsu1'><a href='/popsu1/lille/presentation'>POPSU France 1</a></li>" +
  163. "<li class='popsu2'><a href='/popsu2/lille/presentation-0'>POPSU France 2</a></li>" +
  164. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  165. "</ul>"
  166. });
  167. /* LONDRES */
  168. $("#point-nid-879").popover({
  169. title: false,
  170. trigger: "hover",
  171. content: "<ul>" +
  172. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  173. "</ul>"
  174. });
  175. /* LYON */
  176. $("#point-nid-880").popover({
  177. title: false,
  178. trigger: "hover",
  179. content: "<ul>" +
  180. "<li class='popsu1'><a href='/popsu1/lyon/presentation'>POPSU France 1</a></li>" +
  181. "<li class='popsu2'><a href='/popsu2/lyon/presentation-0'>POPSU France 2</a></li>" +
  182. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  183. "</ul>"
  184. });
  185. /* MALAGA */
  186. $("#point-nid-881").popover({
  187. title: false,
  188. trigger: "hover",
  189. content: "<ul>" +
  190. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  191. "</ul>"
  192. });
  193. /* MARSEILLE */
  194. $("#point-nid-882").popover({
  195. title: false,
  196. trigger: "hover",
  197. content: "<ul>" +
  198. "<li class='popsu1'><a href='/popsu1/marseille/presentation'>POPSU France 1</a></li>" +
  199. "<li class='popsu2'><a href='/popsu2/marseille/presentation-0'>POPSU France 2</a></li>" +
  200. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  201. "</ul>"
  202. });
  203. /* mayence */
  204. $("#point-nid-964").popover({
  205. title: false,
  206. trigger: "hover",
  207. content: "<ul>" +
  208. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  209. "</ul>"
  210. });
  211. /* Montpellier */
  212. $("#point-nid-883").popover({
  213. title: false,
  214. trigger: "hover",
  215. content: "<ul>" +
  216. "<li class='popsu1'><a href='/popsu1/montpellier/presentation'>POPSU France 1</a></li>" +
  217. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  218. "</ul>"
  219. });
  220. /* Montréal */
  221. $("#point-nid-884").popover({
  222. title: false,
  223. trigger: "hover",
  224. content: "<ul>" +
  225. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  226. "</ul>"
  227. });
  228. /* Nantes */
  229. $("#point-nid-868").popover({
  230. title: false,
  231. trigger: "hover",
  232. content: "<ul>" +
  233. "<li class='popsu1'><a href='/popsu1/nantes/presentation'>POPSU France 1</a></li>" +
  234. "<li class='popsu2'><a href='/popsu2/nantes/presentation-0'>POPSU France 2</a></li>" +
  235. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  236. "</ul>"
  237. });
  238. /* Nimes */
  239. $("#point-nid-965").popover({
  240. title: false,
  241. trigger: "hover",
  242. content: "<ul>" +
  243. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  244. "</ul>"
  245. });
  246. /* Paris */
  247. $("#point-nid-885").popover({
  248. title: false,
  249. trigger: "hover",
  250. content: "<ul>" +
  251. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  252. "</ul>"
  253. });
  254. /* Rennes */
  255. $("#point-nid-886").popover({
  256. title: false,
  257. trigger: "hover",
  258. content: "<ul>" +
  259. "<li class='popsu2'><a href='/popsu2/rennes/presentation-0'>POPSU France 2</a></li>" +
  260. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  261. "</ul>"
  262. });
  263. /* Rotterdam */
  264. $("#point-nid-887").popover({
  265. title: false,
  266. trigger: "hover",
  267. content: "<ul>" +
  268. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  269. "</ul>"
  270. });
  271. /* Strasbourg */
  272. $("#point-nid-888").popover({
  273. title: false,
  274. trigger: "hover",
  275. content: "<ul>" +
  276. "<li class='popsu2'><a href='/popsu2/strasbourg/presentation-0'>POPSU France 2</a></li>" +
  277. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  278. "</ul>"
  279. });
  280. /* Stuttgart */
  281. $("#point-nid-1031").popover({
  282. title: false,
  283. trigger: "hover",
  284. content: "<ul>" +
  285. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  286. "</ul>"
  287. });
  288. /* Rome */
  289. $("#point-nid-1030").popover({
  290. title: false,
  291. trigger: "hover",
  292. content: "<ul>" +
  293. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  294. "</ul>"
  295. });
  296. /* Toulon */
  297. $("#point-nid-889").popover({
  298. title: false,
  299. trigger: "hover",
  300. content: "<ul>" +
  301. "<li class='popsu2'><a href='/popsu2/toulon/presentation-0'>POPSU France 2</a></li>" +
  302. "</ul>"
  303. });
  304. /* Toulouse */
  305. $("#point-nid-890").popover({
  306. title: false,
  307. trigger: "hover",
  308. content: "<ul>" +
  309. "<li class='popsu1'><a href='/popsu1/toulouse/presentation'>POPSU France 1</a></li>" +
  310. "<li class='popsu2'><a href='/popsu2/toulouse/presentation-0'>POPSU France 2</a></li>" +
  311. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  312. "</ul>"
  313. });
  314. /* Turin */
  315. $("#point-nid-891").popover({
  316. title: false,
  317. trigger: "hover",
  318. content: "<ul>" +
  319. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  320. "</ul>"
  321. });
  322. /* Vienne */
  323. $("#point-nid-892").popover({
  324. title: false,
  325. trigger: "hover",
  326. content: "<ul>" +
  327. "<li class='popsueurope'><a href='/popsu-europe/accueil'>POPSU Europe</a></li>" +
  328. "</ul>"
  329. });
  330. $.each($(".captioned img"), function(legend, item) {
  331. title = $(item).attr('title')
  332. if (title && title != "") {
  333. $(item).after('<p class="flex-caption"><span class="ville-title">' + title + '</span></p>');
  334. }
  335. });
  336. }); })(jQuery);