//regenerate html? $cacheid = 'maplarge|' . $token; //regenerate? if (!$smarty->is_cached($template, $cacheid)) { dieUnderHighLoad(); //assign overview to smarty if ($mosaic->type_or_user > 0) { $overview->type_or_user = $mosaic->type_or_user; $profile = new GeographUser($mosaic->type_or_user); $smarty->assign('realname', $profile->realname); $smarty->assign('user_id', $mosaic->type_or_user); } if ($mosaic->pixels_per_km >= 40) { //largeoverview $overview->setScale(1); list($x, $y) = $mosaic->getCentre(); $overview->setCentre($x, $y); //does call setAlignedOrigin } $overview->assignToSmarty($smarty, 'overview'); $smarty->assign('marker', $overview->getBoundingBox($mosaic)); //assign main map to smarty $mosaic->assignToSmarty($smarty, 'mosaic'); //assign all the other useful stuff $gridref = $mosaic->getGridRef(-1, -1); $smarty->assign('gridref', $gridref); $smarty->assign('mapwidth', round($mosaic->image_w / $mosaic->pixels_per_km)); preg_match("/([A-Z]+\\d)5(\\d)5\$/", $gridref, $matches); $smarty->assign('gridref2', $matches[1] . $matches[2]); if ($mosaic->pixels_per_km >= 40) { $left = $mosaic->map_x;