Witam,
Mam taki krótkie pytanie.
Czy możliwe jest że ustawić jakiś obrazek na logo w amxbans 5.0 ?
Chyba każdy zrozumie o co mi chodzi.
Proszę o szybką odpowiedź, z góry dziękuję.
|
|
Witam,
Mam taki krótkie pytanie.
Czy możliwe jest że ustawić jakiś obrazek na logo w amxbans 5.0 ?
Chyba każdy zrozumie o co mi chodzi.
Proszę o szybką odpowiedź, z góry dziękuję.
Google ? W google nawet po wpisaniu wielu kombinacji mojego pytania, i tak pierwsze 2 odnośniki to moje tematy -.- . Pierwszy to dokładnie ten temat w którym teraz piszemy,drugi to temat o takiej samej treści, który założyłem na amxx.pl ...
Posiadam amxbans 5.1 by defender, ale są podobno podobne.
1. Zaloguj się na www amxbans
2. Ustawienia
3. Pokazywać linki na stronie ? - Tak ( zaznacz na tak )
4. Gdy strona się przeładuje to na dole masz tam dodawanie bannerów / linków - tam już sb dasz radę ; )
Niestety, Też słyszałem, że Amxbans 5.0 i 5.1 są bardzo podobne, jednak różnią się, m.in. tym że w 5.0 nie ma opcji pokazywania linków na stronie.
Może jakieś pomysły z css, albo html ?
zapodaj index.php lub findex.php - nie pamiętam, ta z listą banów .
Raczej chodzi ci o findex.php, bo w index.php nie ma zbyt wiele ciekawego.
Kod:<?php /* * * AMXBans, managing bans for Half-Life modifications * Copyright (C) 2003, 2004 Ronald Renes / Jeroen de Rover * * web : http://www.xs4all.nl/~yomama/amxbans/ * mail : yomama@xs4all.nl * ICQ : 104115504 * * This file is part of AMXBans. * * AMXBans 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. * * AMXBans 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 AMXBans; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ // Start session session_start(); // Require basic site files require("include/config.inc.php"); if ($config->error_handler == "enabled") { include("$config->error_handler_path"); } require("$config->path_root/include/functions.lang.php"); require("$config->path_root/include/functions.inc.php"); // Get ban details if(isset($_GET["steamid"])) { // Make the array for the history ban list $query = "SELECT player_nick, admin_nick, ban_length, ban_created, player_id, ban_reason FROM $config->ban_history WHERE player_id = '".mysql_escape_string($_GET["steamid"])."' ORDER BY ban_created DESC"; $resource = mysql_query($query) or die(mysql_error()); if(mysql_num_rows($resource) == 0) { //trigger_error("Can't find ban with given ID: ".mysql_escape_string($_GET["steamid"] , E_USER_NOTICE); // Här behöver man inte ha nĺgot. Har bortkommenterat raden ovan. Tycker att NOTICE är onödigt för det förstör mest formatet pĺ motd sidan. } else { $unban_array = array(); while($result = mysql_fetch_object($resource)) { $date = dateMonth($result->ban_created); $player = htmlentities($result->player_nick, ENT_QUOTES); $player_id = htmlentities($result->player_id, ENT_QUOTES); $duration = $result->ban_length; $reason = htmlentities($result->ban_reason, ENT_QUOTES); $admin = htmlentities($result->admin_nick, ENT_QUOTES); if(empty($duration)) { $duration = "Permanent"; } else { $duration = $duration." mins"; } // Asign variables to the array used in the template $unban_info = array( "date" => $date, "player" => $player, "player_id" => $player_id, "duration" => $duration, "reason" => $reason, "admin" => $admin, ); $unban_array[] = $unban_info; } } } /**************************************************************** * Template parsing * ****************************************************************/ $title = lang("_BANDETAILS"); $smarty = new dynamicPage; $smarty->assign("meta",""); $smarty->assign("title",$title); $smarty->assign("working_title","home"); $smarty->assign("dir",$config->document_root); $smarty->assign("display_admin", $config->display_admin); $smarty->assign("unban_info",$unban_info); $smarty->assign("bhans",$unban_array); $smarty->assign("parsetime",$parsetime); $smarty->display('findex.tpl'); ?>
Edytuj linijkę, na początku kodu . Powinno działać .Kod php:<?php
/*
*
* AMXBans, managing bans for Half-Life modifications
* Copyright (C) 2003, 2004 Ronald Renes / Jeroen de Rover
*
* web : http://www.xs4all.nl/~yomama/amxbans/
* mail : yomama@xs4all.nl
* ICQ : 104115504
*
* This file is part of AMXBans.
*
* AMXBans 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.
*
* AMXBans 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 AMXBans; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
// Start session
session_start();
echo '<center><a href="link do odnosnika"><img src="link_do_banneru" border="0" /></a></center>'
// Require basic site files
require("include/config.inc.php");
if ($config->error_handler == "enabled")
{
include("$config->error_handler_path");
}
require("$config->path_root/include/functions.lang.php");
require("$config->path_root/include/functions.inc.php");
// Get ban details
if(isset($_GET["steamid"]))
{
// Make the array for the history ban list
$query = "SELECT player_nick, admin_nick, ban_length, ban_created, player_id, ban_reason FROM $config->ban_history WHERE player_id = '".mysql_escape_string($_GET["steamid"])."' ORDER BY ban_created DESC";
$resource = mysql_query($query) or die(mysql_error());
if(mysql_num_rows($resource) == 0)
{
//trigger_error("Can't find ban with given ID: ".mysql_escape_string($_GET["steamid"] , E_USER_NOTICE);
// Här behöver man inte ha nĺgot. Har bortkommenterat raden ovan. Tycker att NOTICE är onödigt för det förstör mest formatet pĺ motd sidan.
}
else
{
$unban_array = array();
while($result = mysql_fetch_object($resource))
{
$date = dateMonth($result->ban_created);
$player = htmlentities($result->player_nick, ENT_QUOTES);
$player_id = htmlentities($result->player_id, ENT_QUOTES);
$duration = $result->ban_length;
$reason = htmlentities($result->ban_reason, ENT_QUOTES);
$admin = htmlentities($result->admin_nick, ENT_QUOTES);
if(empty($duration))
{
$duration = "Permanent";
}
else
{
$duration = $duration." mins";
}
// Asign variables to the array used in the template
$unban_info = array(
"date" => $date,
"player" => $player,
"player_id" => $player_id,
"duration" => $duration,
"reason" => $reason,
"admin" => $admin,
);
$unban_array[] = $unban_info;
}
}
}
/****************************************************************
* Template parsing *
****************************************************************/
$title = lang("_BANDETAILS");
$smarty = new dynamicPage;
$smarty->assign("meta","");
$smarty->assign("title",$title);
$smarty->assign("working_title","home");
$smarty->assign("dir",$config->document_root);
$smarty->assign("display_admin", $config->display_admin);
$smarty->assign("unban_info",$unban_info);
$smarty->assign("bhans",$unban_array);
$smarty->assign("parsetime",$parsetime);
$smarty->display('findex.tpl');
?>
Niestety, dalej nie działa -.-.
Dodałem tę linijkę echo... w odpowiednie miejsca wstawiłem linki itd. i nic, logo nie jest pokazywane.
Spróbuj tą linijkę dać w index.php, jak to nic nie da to pomyślę co można więcej zrobić .
| « AmxBans - nick admina na www | Zombie Plague Mod 4.3 » |