• 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 nicaw house error

carre

Advanced OT User
Joined
Apr 23, 2013
Messages
885
Solutions
1
Reaction score
161
Location
Sweden
Fatal error: Uncaught exception 'aacException'
Message: House file not found: C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063\data\world
File: houses.php on line: 23
Script was terminated because something unexpected happened. You can report this, if you think it's a bug.

Debug Backtrace:Disabled
is there way to fix it?
 
change:
C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063\data\world

to
C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063\data\world

in the config file
 
Message: House file not found: C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063\data\world

Your server path seems wrong
 
Message: House file not found: C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063\data\world

Your server path seems wrong
Then how should i am do the correct path?
 
Show me your config file where the path is set but as you can see

C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063\data\world

Seems to me that you added your path twice. Or are you using a custom script?
 
Show me your config file where the path is set but as you can see

C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063C:\Users\Carre\Desktop\tibia 7.6 rl project by carre\Avesta063\data\world

Seems to me that you added your path twice. Or are you using a custom script?
here
Code:
# Set data directory of your OT server
$cfg['dirdata'] = 'C:\Users\Carre\Desktop\otstuff\Datapack\cipsoft 7.6 rl project\data';

$cfg['house_file'] = 'C:\Users\Carre\Desktop\otstuff\Datapack\cipsoft 7.6 rl project\data\world';
 
Show me houses.php
here my house.php
Code:
<?php
/*
    Copyright (C) 2007 - 2009  Nicaw

    This program 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.

    This program 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.,
    51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
include ("include.inc.php");
$ptitle="$cfg[server_name] - Houses";
include ("header.inc.php");
if (!is_file($cfg['dirdata'].$cfg['house_file']))
    throw new aacException('House file not found: '.$cfg['dirdata'].$cfg['house_file']);
?>
<div id="content">
<div class="top">Houses</div>
<div class="left">
<div class="right">
<div class="downright">
</div>
<div class="mid">

<td width="100%"><img src="skins/conquest/line_body.gif" align="left" border="0" height="7" hspace="0" vspace="0" width="100%"></td></table>
<img src="skins/conquest/title_houses.gif" style="vertical-align: middle;" />     &nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbspHere you can see the list of all available houses, flats or guildhall.
<td width="100%"><img src="skins/conquest/line_body.gif" align="left" border="0" height="7" hspace="0" vspace="0" width="100%"></td>

<br>
<br>

<td><img src="layouts/t2/files/blank.gif" border="0" height="1" width="10"></td>
<div style="height: 500px; overflow: auto; margin: 10px;">
<table>
<tr class="color0"><td width="45%"><b>House</b></td><td width="25%"><b>Location</b></td><td width="25%"><b>Owner</b></td><td><b>Size</b></td><td><b>Price</b></td></tr>
<?php
$HousesXML = simplexml_load_file($cfg['dirdata'].$cfg['house_file']);
$MySQL = AAC::$SQL;
$MySQL->myQuery('SELECT `players`.`name`, `houses`.`id` FROM `players`, `houses` WHERE `houses`.`owner` = `players`.`id`;');

while ($row = $MySQL->fetch_array()){
    $houses[(int)$row['id']] = $row['name'];
}
foreach ($HousesXML->house as $house){
    $i++;
    $list.= '<tr '.getStyle($i).'><td>'.htmlspecialchars($house['name']).'</td><td>'.htmlspecialchars($cfg['temple'][(int)$house['townid']]['name']).'</td><td>'.$houses[(int)$house['houseid']].'</td><td>'.$house['size'].'</td><td>'. $house['size'] * 235 .'</td></tr>'."\r\n";
}
echo $list;

?>
</table>

</div>
  <br><br>
<td width="100%"><img src="skins/conquest/line_body.gif" align="left" border="0" height="7" hspace="0" vspace="0" width="100%"></td>
<p align="center"> Copyright by Illuminate real map. All rights reserved. </center>

    </div>

    <div class="bot"></div>
</div>
</div>
<?php include ("footer.inc.php");?>
 
Your error is the config values. Try this

Code:
# Set data directory of your OT server
$cfg['dirdata'] = 'C:\Users\Carre\Desktop\otstuff\Datapack\cipsoft 7.6 rl project\data';

$cfg['house_file'] = '\world\houses.xml';
 
Back
Top