source: spip-zone/_plugins_/ajax_callback/head.php @ 117558

Last change on this file since 117558 was 6269, checked in by cedric@…, 14 years ago

"rendre compatible ajax_callback avec la 1,9,1"

File size: 536 bytes
Line 
1<?php
2function ajaxcallback_insert_head($flux){
3        if (!defined(_DIR_JAVASCRIPT)){
4                $p=explode(basename(_DIR_PLUGINS)."/",str_replace('\\','/',realpath(dirname(__FILE__))));
5                define('_DIR_PLUGIN_AJAXCALLBACK',(_DIR_PLUGINS.end($p)));
6                $flux .= '<script src="'._DIR_PLUGIN_AJAXCALLBACK.'/layer.js" type="text/javascript"></script>';
7        }
8        else    $flux .= '<script src="'._DIR_JAVASCRIPT.'layer.js" type="text/javascript"></script>';
9
10        return $flux.'<script src="'.find_in_path('ajaxCallback.js').'" type="text/javascript"></script>';
11}
12
13?>
Note: See TracBrowser for help on using the repository browser.