- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
- 31
- 32
- 33
- 34
- 35
- 36
- 37
- 38
- 39
- 40
- 41
- 42
- 43
- 44
<?php
session_start();
define('_JEXEC', 1);
$host = $_SERVER['DOCUMENT_ROOT'];
include $host.'/admin/function.php';
include $host.'/data/conf.php';
include $host.'/data/settings.php';
$templates = $system['templates'];
$content = file_get_contents($host.'/design/'.$templates.'/index.tpl');
$result = mysql_query(" SELECT * FROM news WHERE section='index' ");
$myrow = mysql_fetch_array($result);
$result2 = mysql_query(" SELECT * FROM slogan ");
$myrow2 = mysql_fetch_array($result2);
$index_news = $myrow['news'];
$title = $myrow['title'];
$description = $myrow['description'];
$keywords = $myrow['keywords'];
$menu='';
function callback($s) {$GLOBALS['menu'].=$s; }
ob_start('callback');
include $host.'/data/site_content/menu.php';
ob_end_flush();
$menu="$menu";
$content=str_replace('{templates}', $templates, $content);
$content=str_replace('{menu}', $menu, $content);
$content=str_replace('{content}', $index_news, $content);
$content=str_replace('{slogan_name}', $myrow2['slogan_name'], $content);
$content=str_replace('{slogan}',$myrow2['slogan'], $content);
$content=str_replace('{title}', $title, $content);
$content=str_replace('{description}', $description, $content);
$content=str_replace('{keywords}', $keywords, $content);
echo $content;
?>
достойные ученики лердорфа - часть 2: возрождение
Джумла такая Джумла, ломаный же ворд.
чтобы враг не догадался?
хотя и это не поможет учитывая что некоторе удолбаны эмулируют register_globals в своих продуктах в начале работы скрипта.
и
только в первом куске запись короче
Лучше бы в пхп были встроены prepared statements
ну ок, чо