source: spip-zone/_plugins_/_dev_/google_ajax_search/googleajaxsearch_pipeline.php @ 10573

Last change on this file since 10573 was 10573, checked in by erational@…, 14 years ago

ajout lien doc + support de balise dynamique #FORMULAIRE_RECHERCHE_GOOGLE{requete}

File size: 967 bytes
Line 
1<?php
2
3// --------------------------------
4// partie privee
5// --------------------------------
6
7function googleajaxsearch_ajouterBoutons($boutons_admin) {
8        // admin ?
9        if ($GLOBALS['connect_statut'] == "0minirezo") {
10            $boutons_admin['configuration']->sousmenu['googleajaxsearch']= new Bouton(
11                    _DIR_PLUGIN_GOOGLEAJAXSEARCH.'img_pack/google_but.png', _T('googleajaxsearch:config_plug'));
12        }
13        return $boutons_admin;
14}
15
16
17// --------------------------------
18// partie publique
19// --------------------------------
20function googleajaxsearch_insert_head($flux){
21   
22    $adresse_site = $GLOBALS['meta']['adresse_site'];
23    $google_key = $GLOBALS['meta']['google_key'];
24               
25                $flux.='
26    <!-- google ajax api search -->
27    <link href="http://www.google.com/uds/css/gsearch.css" type="text/css" rel="stylesheet"/>
28    <script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&key='.$google_key.'" type="text/javascript"></script>';
29       
30        return $flux;
31}
32       
33?>
Note: See TracBrowser for help on using the repository browser.