27if ( ! defined (
'ALLOWED')) die(
'Appel direct ne sont pas permis');
29if (! isset(
$_GET[
'ac'])) {
36if (isset(
$_GET[
'bookmark_add'])){
37 $count=
$cn->get_value(
"select count(*) from bookmark"
38 .
" where b_action=$1 and login=$2",
43 $cn->exec_sql(
"insert into bookmark(b_action,login) values($1,$2)",
46 $js=
"error_message('"._(
"Ce favori a déjà été ajouté").
"');";
51if (isset(
$_GET[
'bookmark_delete']) && isset (
$_GET[
'book'])){
52 $a_book=
$_GET[
'book'];
53 for (
$e=0;
$e<count($a_book);
$e++)
55 $cn->exec_sql(
"delete from bookmark where b_id=$1 and login=$2",
60$bookmark_sql=
"select distinct b_id,b_action,b_order,me_code,me_description, javascript"
62 .
"join v_menu_description_favori on (code=b_action or b_action=me_code)"
64 .
"login=$1 order by me_code";
66$url=
"do.php?gDossier=".Dossier::id().
"&ac=";
69<form
id=
"bookmark_del_frm" method=
"get" onsubmit=
"remove_bookmark();return false">
72 <
table class=
"result">
82 <
tr class=
"<?php echo (($i%2)==0?'odd':'even')?>">
91 <a
class=
'mtitle' style=
'text-decoration: underline' href=
"<?php echo $url."&ac=
".$a_bookmark[$i]['b_action']; ?>">
103 echo
HtmlInput::submit(
"bookmark_delete",_(
"Supprimez favoris sélectionnés"),
"",
"smallbutton");
107<form
id=
"bookmark_frm" method=
"get" onsubmit=
"save_bookmark();return false">
109echo _(
"Menu actuel").
" : ".
hb(
$_GET[
'ac']);
113<?php echo
HtmlInput::submit(
"bookmark_add", _(
"Ajoutez le menu actuel à vos favoris"),
"",
"smallbutton"); ?>
tr($p_string, $p_extra='')
td($p_string='', $p_extra='')
surround the string with td
global $g_user
if no group available , then stop
if(! isset($_GET['ac'])) if(isset( $_GET[ 'bookmark_add'])) if(isset($_GET['bookmark_delete']) &&isset($_GET['book'])) $bookmark_sql
create_script($p_string)
create the HTML for adding the script tags around of the script