Dobrý den. Stáhl jsem si galerii v php na svojí stránku,všecho funguje jak má,až na to,že na všech stránkách se mi zobrazuje nějaký text. Viz
.
V kódu index.php žádný takový text není a v žádném jiném souboru také ne ,takže nevím jak to zpravit.
V php začínám a tak se musím zeptat vás,profíků.Díky moc za každou radu,nashledaneou.
tady je kód ze souboru index.php
<?php
/********************************************************************* **
Copyright (C) 2006 Aizu Ikmal Ahmad (aizu@ikmal.com.my)
This file is part of iFoto.
iFoto is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published
by the Free Software Foundation; either version 2 of the License,
or (at your option) any later version.
iFoto is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston,
MA 02111-1307 USA
********************************************************************** **/
require('config.php');
define('SORT_BY', $sort_thumbs_by);
define('SORT_ORDER', $sort_thumbs_order);
define('STRIP_SORT_NUMBER', $strip_sort_number);
define('DISPLAY_HOMEPAGE_LAST_ADDTION', $display_home_last_addition);
define('THUMBS_PER_PAGE', $thumbs_per_page);
define('TILE_STYLE', $tile_style);
require('includes/functions.php');
require('includes/thumbnailer.php');
requirement_checker();
$template = 'default';
if(!is_file('templates/'.$template.'.html')){ errorMsg('Sorry, template '.$template.' does not exist.'); }
require('templates/'.$template.'.html');
function home_page(){
?>
<div id="homepage">
<h3><font color="#FF6600">i</font>Foto</h3>
My Simple Photo Gallery
<br /><br />
Click on the left category to view photos.
<br /><br />
Current release : 1.0 (Non-MySQL)
<?php if(DISPLAY_HOMEPAGE_LAST_ADDTION){html_LastAddition();} ?>
</div>
<?php
}
function html_stat(){
}
function html_nav(){
echo '<ul>';
echo '<li class="home_button"><a href="?">Home</a></li>';
map_dirs('gallery/',0);
echo '</ul>';
$style_on_current = '';
}
function map_dirs($path,$level) {
if(is_dir($path)) {
if($contents = opendir($path)) {
while(($node = readdir($contents)) !== false) {
if($node!="." && $node!="..") {
for($i=0;$i<$level;$i++) echo " ";
if(is_dir($path."/".$node)){
if((urldecode(get_param('dir')) == str_replace('gallery//','',$path).'/'.$node) OR urldecode(get_param('dir')) == $node){$style_on_current = 'class="active"';}else{$style_on_current = '';}
if($i == 0){
echo '<li '.$style_on_current.'><a href="?dir='.urlencode($node).'" title="'.$node.'">'.$node.'</a></li>';
}else{
echo '<li '.$style_on_current.' style="margin-left:10px;"><a href="?dir='.str_replace('gallery//','',$path)."/".urlencode($node).'" title="'.$node.'" style="font-weight:normal;">'.$node.'</a></li>';
}
}
map_dirs("$path/$node",$level+1);
}
}
}
}
}
function html_contents(){
if(get_param('pic')){
if(!get_param('dir')){ exit('<pre>Get dir error.</pre>'); }
$current_image_list = readDirectory(get_param('dir'), true);
$current_image_list = multi_array_sort($current_image_list, SORT_BY, SORT_ORDER);
$total_images = count($current_image_list);
$search_key = multi_array_search(get_param('pic'), $current_image_list);
//pre($current_image_list);
$current_key = $search_key[0];
@$curr_image = $current_image_list[$current_key];
@$prev_image = $current_image_list[$current_key-1];
@$next_image = $current_image_list[$current_key+1];
$max_width = 560;
/* to avoid small image getting as big as $max_width */
if($curr_image['width'] > $max_width){
$img_width = $max_width;
}else{
$img_width = $curr_image['width'];
}
$curr_image_meta_id = str_replace('.jpg','',str_replace('data/thumbdata_','',$curr_image['th umb']));
if(file_exists('data/desc_'.$curr_image_meta_id.'.desc')){
$current_image_description = '<div class="description">'.implode ('', file ('data/desc_'.$curr_image_meta_id.'.desc')).'</div>';
}else{
$current_image_description = '';
}
?>
<script language="JavaScript">
<!-- Begin Image Preload
image_prev = new Image();
image_prev.src = "gallery/<?php echo $prev_image['dir']; ?>/<?php echo $prev_image['filename']; ?>";
image_next = new Image();
image_next.src = "gallery/<?php echo $next_image['dir']; ?>/<?php echo $next_image['filename']; ?>";
// End -->
</script>
<div id="fullsize">
<div class="menu">
<div class="left">
Photo <?php echo $current_key+1 ; ?> from <?php echo $total_images; ?>
</div>
<div class="right">
<?php if($current_key != 0){ ?><a href="?dir=<?php echo urlencode(get_param('dir')); ?>&pic=<?php echo urlencode($prev_image['title']); ?>" title="<?php echo $prev_image['title'];?>">Prev</a> | <?php }else{ ?> Prev | <?php }; ?>
<?php if($current_key+1 != $total_images){ ?><a href="?dir=<?php echo urlencode(get_param('dir')); ?>&pic=<?php echo urlencode($next_image['title']); ?>" title="<?php echo $next_image['title'];?>">Next</a><?php }else{ ?> Next <?php }; ?>
</div>
<div class="clear"> </div>
</div>
<div class="image_wrapper">
<div class="shadow"> </div>
<div class="image">
<a href="gallery/<?php echo urldecode($curr_image['dir']); ?>/<?php echo urldecode($curr_image['filename']); ?>" rel="lightbox">
<img src="gallery/<?php echo urldecode($curr_image['dir']); ?>/<?php echo urldecode($curr_image['filename']); ?>" width="<?php echo $img_width; ?>px" border="0">
</a>
</div>
</div>
<div class="title"><?php echo $curr_image['title']; ?></div>
<?php echo $current_image_description;?>
<div class="footer">
<div class="thumb_wrapper prev">
<div class="content">
<div class="shadow"> </div>
<div class="thumb">
<?php if($current_key != 0){ ?>
<a href="?dir=<?php echo urlencode($prev_image['dir']); ?>&pic=<?php echo urlencode($prev_image['title']);?>" title="<?php echo $prev_image['title'];?>"><img src="<?php echo $prev_image['thumb'];?>" border="0"/></a>
<?php }else{ ?>
<img src="templates/default/first.jpg">
<?php } ?>
</div>
</div>
</div>
<div class="desc">
<ul>
<li><b>Filename :</b> <?php echo $curr_image['filename']; ?></li>
<li><b>Original Size :</b> <?php echo $curr_image['width']; ?>x<?php echo $curr_image['height']; ?> </li>
<li><b>Uploaded :</b> <?php echo date('l, j F Y',$curr_image['modified']); ?></li>
<li><b>Filesize :</b> <?php echo number_format($curr_image['filesize']/1024, 2, '.', '').' kb'; ?></li>
</ul>
</div>
<div class=