[Mapbender-dev] [Mapbender] #134: the same javascript may be loaded
twice in map.php
Mapbender
info at osgeo.org
Tue Nov 6 11:54:38 EST 2007
#134: the same javascript may be loaded twice in map.php
-----------------------+----------------------------------------------------
Reporter: christoph | Owner: mapbender_dev at lists.osgeo.org
Type: defect | Status: new
Priority: major | Milestone: 2.5 release
Component: core | Version: 2.4.3
Keywords: |
-----------------------+----------------------------------------------------
map.php
$mb_sql = "SELECT DISTINCT e_js_file, e_id, e_src, e_target, e_pos FROM
gui_element WHERE e_public = 1 AND fkey_gui_id = $1 ORDER BY e_pos";
$mb_v = array($_REQUEST["gui_id"]);
$mb_t = array("s");
$mb_res = db_prep_query($mb_sql, $mb_v, $mb_t);
while($row_js = db_fetch_array($mb_res)){
if($row_js["e_js_file"] != ""){
$e_id = $row_js["e_id"];
$e_id_css = $row_js["e_id"];
$e_src = $row_js["e_src"];
$e_target = $row_js["e_target"];
include($row_js["e_js_file"]);
}
}
Maybe we could just replace the include by include_once?
If we wanted to enable loading the same element multiple times, we would
really need to change the architecture...
--
Ticket URL: <http://trac.osgeo.org/mapbender/ticket/134>
Mapbender <http://www.mapbender.org/>
Mapbender
More information about the Mapbender_dev
mailing list