|
You last visited: Today at 18:55
Advertisement
[Frage]Homepage [Staff.php]
Discussion on [Frage]Homepage [Staff.php] within the Flyff Private Server forum part of the Flyff category.
11/17/2012, 13:50
|
#1
|
elite*gold: 0
Join Date: Nov 2012
Posts: 57
Received Thanks: 7
|
[Frage]Homepage [Staff.php]
Hey Elit epvpers
Ich habe ein problem :
Ich habe auf meiner website [localhost][noch] ein neues Staff.php eingefügt das ist ja alles ok aber das problem ist das wenn ich auf localhost/staff.php gehe steht das da :
Warning: odbc_exec(): in C:\xampp\htdocs\staff.php on line 23
Warning: odbc_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\staff.php on line 25
Warning: odbc_exec(): in C:\xampp\htdocs\staff.php on line 23
Warning: odbc_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\staff.php on line 25
Warning: odbc_exec(): in C:\xampp\htdocs\staff.php on line 23
Warning: odbc_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\staff.php on line 25
Warning: odbc_exec(): in C:\xampp\htdocs\staff.php on line 23
Warning: odbc_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\staff.php on line 25
Warning: odbc_exec(): in C:\xampp\htdocs\staff.php on line 23
Warning: odbc_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\staff.php on line 25
Name Rang Status Onlinezeit
Mein Staff.php Sieht so Aus :
<?php include('./inc/header.php'); ?>
<div class="main">
<img src="img/main_head.png" alt="" />
<div class="site">
<h1>Teammitglieder</h1><hr><br><center>
<table style="width: 90%;">
<tr>
<td>Name</td>
<td>Rang</td>
<td>Status</td>
<td>Onlinezeit</td>
</tr>
<tr><td><br /></td></tr>
<?php
function sectohrs($seconds) {
$Stunden = floor($seconds / 3600); $Rest1 = (($seconds / 3600) - $Stunden); $Minuten = floor($Rest1 * 60);
return $Stunden.'h '.$Minuten.'m';
}
foreach (array('P','C','D','G','H') as $authority) { // P=Admin, H=Head Gamemaster, G=Gamemaster D=Source Developer C=Community Manager
$query1 = odbc_exec($mssql, 'SELECT [m_szName], [MultiServer], [rechte], [TotalPlayTime] FROM [CHARACTER_01_DBF].[dbo].[CHARACTER_TBL] WHERE [rechte] = \''.$authority.'\' ORDER BY [m_szName] ASC');
while($result = odbc_fetch_array($query1)) {
if($result['MultiServer'] != 0){$result['status'] = '<font color="#00FF00">Online</font>';} else {$result['status'] = '<font color="#FF0000">Offline</font>';}
if($result['m_szName'] == 'Kiseku') {$result['auth'] = 'Head Admin';}
if($result['m_szName'] == '') {$result['auth'] = 'Co Admin';}
if($result['m_szName'] == '') {$result['auth'] = 'GM';}
if($result['m_szName'] == '') {$result['auth'] = 'GM';}
if($result['m_szName'] == '') {$result['auth'] = 'GM';}
echo ' <tr>
<td>'.$result['m_szName'].'</td>
<td>'.$result['auth'].'</td>
<td>'.$result['status'].'</td>
<td>'.sectohrs($result['TotalPlayTime']).'</td>
</tr>';
}
}
?>
</table>
</div>
<img src="img/main_foot.png" alt="" />
</div>
<?php include('./inc/footer.php'); ?>
Bitet hilf mir
Lg und danke fürs Lesen ~Kiseku~
|
|
|
11/17/2012, 13:58
|
#2
|
elite*gold: 0
Join Date: Oct 2012
Posts: 1,102
Received Thanks: 564
|
Tja schade wenn man andere sachen benutzt ohne sich alles mal durch zu lesen ;D
Ich habe im Release gesagt, dass man für viele Sachen von mir neue Spalten in der MsSQL braucht. Für die staff.php brauchst du 1 spalte in der Charackter_TBL mit dem Namen "Rechte" Dort muss man der Buchstabe 'P','C','D','G','H eingefügt werden ;-)
|
|
|
11/17/2012, 14:02
|
#3
|
elite*gold: 4
Join Date: Mar 2010
Posts: 3,148
Received Thanks: 1,535
|
PHP Code:
<?php include('./inc/header.php'); ?> <div class="main"> <img src="img/main_head.png" alt="" /> <div class="site"> <h1>Teammitglieder</h1><hr><br><center> <table style="width: 90%;"> <tr> <td>Name</td> <td>Rang</td> <td>Status</td> <td>Onlinezeit</td> </tr> <tr><td><br /></td></tr> <?php function sectohrs($seconds) { $Stunden = floor($seconds / 3600); $Rest1 = (($seconds / 3600) - $Stunden); $Minuten = floor($Rest1 * 60); return $Stunden.'h '.$Minuten.'m'; }
foreach (array('P','M','L') as $authority) { // P=Admin, H=Head Gamemaster, G=Gamemaster D=Source Developer C=Community Manager
$query1 = odbc_exec($mssql, 'SELECT [m_szName], [MultiServer], [m_chAuthority], [TotalPlayTime] FROM [CHARACTER_01_DBF].[dbo].[CHARACTER_TBL] WHERE [m_chAuthority] = \''.$authority.'\' ORDER BY [m_szName] ASC');
while($result = odbc_fetch_array($query1)) { if($result['MultiServer'] != 0){$result['status'] = '<font color="#00FF00">Online</font>';} else {$result['status'] = '<font color="#FF0000">Offline</font>';}
echo ' <tr> <td>'.$result['m_szName'].'</td> <td>'.$result['status'].'</td> <td>'.sectohrs($result['TotalPlayTime']).'</td> </tr>';
} } ?>
</table> </div> <img src="img/main_foot.png" alt="" /> </div> <?php include('./inc/footer.php'); ?>
|
|
|
11/17/2012, 14:07
|
#4
|
elite*gold: 0
Join Date: Nov 2012
Posts: 57
Received Thanks: 7
|
Quote:
Originally Posted by Chyukαsame
Tja schade wenn man andere sachen benutzt ohne sich alles mal durch zu lesen ;D
Ich habe im Release gesagt, dass man für viele Sachen von mir neue Spalten in der MsSQL braucht. Für die staff.php brauchst du 1 spalte in der Charackter_TBL mit dem Namen "Rechte" Dort muss man der Buchstabe 'P','C','D','G','H eingefügt werden ;-)
|
LOL Skyline Meinte das ist sein o.o sry ich habe den thread nicht sehen :P auch nicht der hat gesagt er ich webdev und kennt sich gut aus !
entschuldigung
|
|
|
11/17/2012, 14:13
|
#5
|
elite*gold: 0
Join Date: Oct 2012
Posts: 577
Received Thanks: 139
|
Im Thread stand doch dabei welche Spalten du adden musst
|
|
|
11/17/2012, 14:16
|
#6
|
elite*gold: 0
Join Date: Nov 2012
Posts: 57
Received Thanks: 7
|
habe den thread nicht gelesen weil mir das .php script geschickt wurde in skype :O
schreib mal bitte welche :P
|
|
|
11/17/2012, 14:23
|
#7
|
elite*gold: 0
Join Date: Oct 2012
Posts: 1,102
Received Thanks: 564
|
in der CHARACTER_TBL die spalte char(1) und für jeden Charakter der jetz im Team ist musst du den Buchstaben rein schreiben den du haben möchtest.
foreach (array('P','C','D','G','H') as $authority) {
Allerdings habe ich im Script nicht alles richtig eingstellt und die Buchstaben sind nur für Reihenfolge nötig. Also kannst du auch A,B,C,D,E nehmen wenn du sie dann einträgst.
foreach (array(A','B','C','D','E') as $authority) {
Die Namen für die Team liste müssen dann noch mal Manuel eingegeben werden, dies sieht dann so aus
PHP Code:
if($result['m_szName'] == 'Snox') {$result['auth'] = 'Projektleitung';} if($result['m_szName'] == 'Chyukasame') {$result['auth'] = 'Web Development';}
Ich hoffe ich konnte helfen 
Denn das, was Jopsi332 geschrieben hat ist MÜLL und kann nicht verwendet werden. Zumindest nicht brauchbar
|
|
|
11/17/2012, 15:16
|
#8
|
elite*gold: 0
Join Date: Nov 2012
Posts: 57
Received Thanks: 7
|
Jo thx habs hinbekommen
kann geclosed werden :=) Danke An :Chyukαsame
@Chyukαsame
habe den sein "Zitat" nichtmal angeschaut xD
|
|
|
11/17/2012, 15:22
|
#9
|
elite*gold: 0
Join Date: Oct 2012
Posts: 1,102
Received Thanks: 564
|
Kein Problem 
Wenn du noch weiter Probleme hast, schreib mich in Skype an
|
|
|
 |
Similar Threads
|
[FRAGE] Eine Kleine HomePage Frage
10/06/2010 - Metin2 Private Server - 4 Replies
Gameserver-Datenbank
SQL-Server (Gameserver)
SQL-User (Gameserver)
SQL-Passwort (Gameserver)
Homepage-Datenbank
|
[staff apply] looking for staff/developers (co , eo , Zo)
06/16/2010 - EO PServer Hosting - 0 Replies
hi all
as my main developer is taking a break is it neccesary for me to look for other developers at this moment
unlucky , i do not have the time for myself to develop the game (got other stuff to do ) so i am looking for developers and in game staff
before you apply , please note that i am looking for developers that know what they are doing and that can take the responsibility to taking care of a server (o no again 10 bug reports i quit ?? , thats not the kind i am looking for )
...
|
:) WTS 118 Staff Summoner With +7 115 Staff (Trieste)
06/12/2009 - Dekaron Trading - 0 Replies
Pm me
|
Frage an den Staff
02/24/2007 - Main - 3 Replies
Ich habe den Forenstyle für das WBB2 von den Affenjungs (die WoW-Gilde). Darf ich den hier weitergeben oder nicht?
|
All times are GMT +1. The time now is 18:55.
|
|