From e46efced1b2c19ca0f628207b70b28a30fcbc288 Mon Sep 17 00:00:00 2001 From: nicosomb Date: Tue, 9 Apr 2013 15:05:49 +0200 Subject: =?UTF-8?q?utilisation=20de=20jquery=20pour=20traitement=20ajax=20?= =?UTF-8?q?mise=20en=20page=20de=20la=20grille,=20type=20Masonry=20(m?= =?UTF-8?q?=C3=A9thode=20full=20css).=20cf=20ici=20:=20http://designshack.?= =?UTF-8?q?net/articles/css/masonry/=20r=C3=A9organisation=20des=20fichier?= =?UTF-8?q?s=20avec=20un=20fichier=20d=C3=A9di=C3=A9=20pour=20le=20traitem?= =?UTF-8?q?ent=20des=20actions=20(process.php)=20utilisation=20de=20pictos?= =?UTF-8?q?=20=C3=A0=20la=20place=20des=20codes=20h=C3=A9xas?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- js/poche.js | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 js/poche.js (limited to 'js/poche.js') diff --git a/js/poche.js b/js/poche.js new file mode 100644 index 00000000..6751920a --- /dev/null +++ b/js/poche.js @@ -0,0 +1,16 @@ +function toggle_favorite(element,id) { + $(element).toggleClass('fav-off'); + $.ajax ({ + url: "process.php?action=toggle_fav", + data:{id:id} + }); +} + + +function toggle_archive(id) { + $('#entry-'+id).toggle(); + $.ajax ({ + url: "process.php?action=toggle_archive", + data:{id:id} + }); +} -- cgit v1.2.3