• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Solved Guild war system tfs 3.6 error

If i don't wrong the War System with Shields only work in TFS 0.4_DEV with the parameters enabled in compilation.
 
line 58 : foreach ($wars as $k=>$v) {
line 59 : if ($v == 1)
line 60 : {

Line 118 - 162

PHP:
foreach ($invitations as $k=>$v) {       <<<<<LINE 118

$ilogo = "default_logo.gif";
$iglogo = "default_logo.gif";

if(!empty($v[ilogo]))
$ilogo = $v[ilogo];
if(!empty($v[iglogo]))
$iglogo = $v[iglogo];

            if(is_int($number_of_rows / 2)) { $bgcolor = '#D4C0A1'; } else { $bgcolor = '#D5E1A2'; } $number_of_rows++;

    $invi .="
        <TR BGCOLOR=".$bgcolor.">
            <TD width=30%>
                <center>
                    <b>
                        <a href='index.php?subtopic=guilds&action=show&guild=" . $v[iname] . "'><font color='#5A2800'>$v[iname]</font></a>
                    </b>
                </center>
            </TD>
            <TD width=40%><center>0-0</center></TD>
            <TD width=30%>
                <center>
                    <b>
                        <a href='index.php?subtopic=guilds&action=show&guild=" . $v[igname] . "'><font color='#5A2800'>$v[igname]</font></a>
                    </b>
                </center>
            </TD>
        </TR>
        <TR BGCOLOR=".$bgcolor.">
            <TD>
                <center>
                        <img border=1 src='guilds/".$ilogo."' width='64px' height='64px'/>
                </center>
            </TD>
            <TD><center><b>Declared on:</b><br />" . date("d/m/y  H:i:s", $v[itime]) . "</center></TD>
            <TD>
                <center>
            <img border=1 src='guilds/".$iglogo."' width='64px' height='64px'/>
                </center>
            </TD>
        </TR>
    ";
}
 
I edit but i can't upload max lines.. ,so download copy paste script and try
Use paste.ots.me.
Most of the time I get that error its due to that the table im looking for isen't there. And if you are trying to use elf's warsystem, you need 0.4 if you haven't made major changes to the source code.
 
Warning: Invalid argument supplied for foreach() in C:\xampp\htdocs\pages\wars.php on line 59
Line 59: foreach ($wars as $k=>$v) {
Warning: Invalid argument supplied for foreach() in C:\xampp\htdocs\pages\wars.php on line 149
Line 149: foreach ($invitations as $k=>$v) {

This is the error that im getting. I am using the script that you posted Cronox. do you know why i do get this error?
 
Back
Top Bottom