• 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!

Nicaw ACC Error - Please Help!

Plumsen

New Member
Joined
Dec 26, 2012
Messages
34
Reaction score
0
I have a bug when using Nicaw ACC XML . I installed it and everything is clear and I have opened ports 80, 443, are there any more ports needed maybe 3306? or is it only when you are using SQL as the database? but anyways .. this is the problem: When I go into http://localhost/ on my browser (internet explorer) so it will just chalk up a white page, which shows only.: Home:. , And nothing more, so something must surely be wrong? it is supposed to display the Home, index page, highscore, skins .. but the only thing that appears is a white page that says: .:Home:. I saw an old post where there was a guy who had exactly the same problem as me (but then it worked for me, but now i have got this bug/error) but no one had responded to how to solve this really annoying error. So I ask those who know how to fix this, help me ... I'm really grateful for all the help I can get. Try to explain as simply as it goes too .. if anyone here knows how to fix the error, was so kind and tell me ;( <_<
 
Last edited:
Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in C:\Users\sonny95\Desktop\xampp\htdocs\index.php on line 6

- - - Updated - - -

WTF?? help umm

how to fix? please

- - - Updated - - -

Godness use:
$ptitle="Home";

other error: Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in C:\Users\sonny95\Desktop\xampp\htdocs\index.php on line 7
 
aff idk sry.

umm, you don't know whats wrong? u know somebody that maybe can??

- - - Updated - - -

I hate this... before it worked without this shit errors... ;(

- - - Updated - - -

Are there no index.php, that is 100% done already without errors? for download..?
 
<?
/*FILE INFO:
loading home.txt file*/
include ("config.php");
include ("functions.php");
$ptitle="Home - $cfg[server_name]";
include ("header.php");
?>
<div id="content">
<div class="top">.:Home:.</div>
<div class="mid">
<pre>
<?
echo htmlentities(file_get_contents("home.txt"));
// include('newseditor/show_news.php');
?>
</pre>
</div>
<div class="bot"></div>
</div>
<?include ("footer.php");?>
 
<?
/*FILE INFO:
loading home.txt file*/
include ("config.php");
include ("functions.php");
$ptitle="Home - $cfg[server_name]";
include ("header.php");
?>
<div id="content">
<div class="top">.:Home:.</div>
<div class="mid">
<pre>
<?
echo htmlentities(file_get_contents("home.txt"));
// include('newseditor/show_news.php');
?>
</pre>
</div>
<div class="bot"></div>
</div>
<?include ("footer.php");?>

an error: Parse error: syntax error, unexpected T_STRING in C:\Users\sonny95\Desktop\xampp\htdocs\config.php on line 30

- - - Updated - - -

Then Pn me with your private IP and I'll test it.

I have pm you.

- - - Updated - - -

Then Pn me with your private IP and I'll test it.

My local ip stopped work with connection when i changed skin to default...
 
Please help me with error... Parse error: syntax error, unexpected T_STRING in C:\Users\sonny95\Desktop\xampp\htdocs\config.php on line 30

in config.php
 
My Nicaw/Xampp problem in FULL DETAIL

I'm having this same issue.

Just downloaded the clean Nicaw 2.11 for 7.xx -> 8,xx from the Nicaw site.

Download Nicaw AAC from SourceForge.net

I'm using an older version of Xampp. (xampp-win-32-1.7.3)

These were my steps:

1. Extracted xampp to C: (So folder for xampp is C:\xampp)

2. Port forward for ports 80, 443, and 3306. All both TCP and UDP. Used port checker tool to make sure they were all open. They are.

3. Go through proper steps in turning on apache and mysql, they worked fine. No errors or notices.

4. Turn off apache and mysql, navigate to xampp\htdocs and delete everything in there.

5. Extract the nicaw to the xampp\htdocs location. I chose dark for my skin.

6. Start apache and mysql again, and go to localhost.

Here is the problem. White home page, with the only text being ".:Home:." in the top left corner. Not even clickable, just the word. Changed skin to conquest, same issue.

Here are my files I've seen previously asked for, and some that are just relating to them.

Index.php

PHP:
<?
/*FILE INFO:
loading home.txt file*/
include ("config.php");
include ("functions.php");
$ptitle="Home - $cfg[server_name]";
include ("header.php");
?>
<div id="content">
<div class="top">.:Home:.</div>
<div class="mid">
<pre>
<?
echo htmlentities(file_get_contents("home.txt"));
?>
</pre>
</div>
<div class="bot"></div>
</div>
<?include ("footer.php");?>

Home.txt (NOTE: It also has the carlin sword text image, but I removed it for less confusion.)

Code:
  NICAW Acc v2.11                         
                                                  
                                                    
 ~SHORT TUTORIAL~                           
                                               
 1. Open config.php in text editor       
    of your choise.                         
                                            
 2. Set data directory.  Use / to            
    separate directories, and end with /      
                                                
 3. Set your server name.                   
                                                   
 4. Scroll down... Set temple coordinates.          
                                                
 ~FINAL NOTES~                                
                                          
 #Text seen here can be edited in       
  home.txt                                 
                                            
 #Bug reports and suggestions are           
  welcome to [email protected]                     
                                                    
 #Navigation menu can be edited in navigation.xml 
                                                   
 #This is Carlin sword on the right :)


Config.php

PHP:
<?
/*
Copyright (C) 2006  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.

http://www.gnu.org/copyleft/gpl.html
*/
error_reporting(E_ALL ^ E_NOTICE);
//---------------------------- Data Dir ----------------------------------------

/*Set location of data directory
IMPORTANT! Use / to separate folders, put / in the end     */
$cfg['dirdata'] = 'C:/Users/Sable/Desktop/Chaos/data/';

//----------------------------- Website Configuration --------------------------

//look in skins folder to see available skins
$cfg['skin'] = 'conquest';

//name displayed in window title
$cfg['server_name'] = 'Chaos Rebuild Project';

/*Encrypt passwords. (true / false)
Works together with md5passwords = "yes" in server config.lua
Strongly recomended, but off by default. After changing this, existing accounts will become inaccessible!*/
$cfg['md5passwords'] = False; 

/*(true / false)
Using captcha will prevent automated sripts from flooding server with accounts. 
Note that GD library must be enabled in php.ini for this to work.
extension_loaded('gd') means "auto"*/
$cfg['use_captha'] = extension_loaded('gd'); 

/*(advanced users only) Asks user's email when registering and attempts to send greeting.
SMTP can be configured function mailex() in functions.php.
Email content can be found in new.php. You must have DNS MX record if sending from local SMTP.
Correct reverse DNS is also recomended.*/
$cfg['ask_email'] = false; 

/* Session security. Set medium if you get kicked out after loging in account.
0 - low		(no fancy stuff)
1 - medium	(users are loged out after being idle for specified time interval)
2 - high	(IPs are checked to prevent session hijacking)*/
$cfg['session_security'] = 2;

//seconds in which user is loged out. default is 10 minutes: 10*60
$cfg['session_timeout'] = 10*60; 

//allowed characters per account
$cfg['maxchars'] = 10; 

/* enable unban feature. some servers ban permanetly for pking. if this enabled players will be unbaned when generating highscores (true / false)*/
$cfg['unban_allow'] = false;

/* time in seconds after which player can be unbaned
  (2 days)     d*hh*mm*ss;  kapish? */
$cfg['unban_after'] = 2*24*60*60;

//Delete old characters?
$cfg['delete_allow'] = false;

//delete players older than (seconds)
$cfg['delete_player'] = 2*30*24*60*60; //(2 months)

//only delete players with level lower than
$cfg['delete_level'] = 20;

/* Predefined account number. 
0 - none (leave blank field), 
1 - offer (put account number, but user can change it), 
2 - force (dont allow user to select his own account number)*/
$cfg['account_number'] = 0;

//Vocation names
$cfg['voc_normal'] = array('None','Sorcerer','Druid','Paladin','Knight','Master Sorcerer','Elder Druid','Royal Paladin','Elite Knight');

//Promoted names
$cfg['voc_promoted'] = array('None','Master Sorcerer','Elder Druid','Royal Paladin','Elite Knight');

//Access level names
$cfg['positions'] = array("Player", "Tutor", "Counselor", "Gamemaster", "God");

//Access level to use admin panel
$cfg['admin_access'] = 10;

//Admin Panel - attributes to load from player file (root tag only)
$cfg['admin_attrs'] = array('name', 'account', 'sex', 'exp', 'voc', 'level', 'access', 'cap', 'maglevel', 'lastlogin', 'premticks', 'promoted', 'banned');

//generate CVS players.xml file (true/false) This is mostly needed for 7.7 servers.
$cfg['CVSplayers'] = False;

//For online status. Do not change, unless you running on diferent port.
$cfg['server_ip'] = "localhost";
$cfg['server_port'] = 7171;

//----------------------------- Highscore Configuration ------------------------

 //seconds in which highscores will be reloaded. default is 3 hours: 3*60*60
$cfg['rank_refresh'] = 3*60*60;

// this access level and above not included in ranks
$cfg['gm_access'] = 2;

//number of ranks to cache
$cfg['highscoreshow'] = 200;

//how many displayer per page
$cfg['number_per_page'] = 30;

//----------------------------- All vocations ----------------------------------
$cfg['lvl'] = 8; 	// initial level (can be float like: 8.3 or 14.7)

//whether to allow users to choose vocations. Set to false if you have Rook system
$cfg['vocation_choose'] = True; 

//Players Temple(s)

$cfg['temple']['Chaos City']['x'] = 160;
$cfg['temple']['Chaos City']['y'] = 54;
$cfg['temple']['Chaos City']['z'] = 7;




// you might want to add GM chars here
$cfg['vip_file'] = '<?xml version="1.0"?>
<vips><vip id="1" name="GM Nicaw"/></vips>';

//Depending on server, you might need to change depot configuration
$cfg['depots'] = '
<depots>
<depot depotid="1"><item id="2590"><inside><item id="2594"/></inside></item></depot>
<depot depotid="2"><item id="2590"><inside><item id="2594"/></inside></item></depot>
<depot depotid="3"><item id="2590"><inside><item id="2594"/></inside></item></depot>
<depot depotid="4"><item id="2590"><inside><item id="2594"/></inside></item></depot>
<depot depotid="5"><item id="2590"><inside><item id="2594"/></inside></item></depot>
<depot depotid="6"><item id="2590"><inside><item id="2594"/></inside></item></depot>
<depot depotid="7"><item id="2590"><inside><item id="2594"/></inside></item></depot>
</depots>
';

// Leave this stuff as it is :P
if (!defined('MALE')) define('MALE', 1);
if (!defined('FEMALE')) define('FEMALE', 0);
if (!defined('NOVOC')) define('NOVOC', 0);
if (!defined('SORCERER')) define('SORCERER', 1);
if (!defined('DRUID')) define('DRUID', 2);
if (!defined('PALADIN')) define('PALADIN', 3);
if (!defined('KNIGHT')) define('KNIGHT', 4);

//-------------------------------- Sorcerer ------------------------------------
// Looks
$cfg['look'][SORCERER][MALE] = '130';
$cfg['look'][SORCERER][FEMALE] = '138';

// HP, mana, magic level
$cfg['health'][SORCERER] = '185';
$cfg['mana'][SORCERER] = '40';
$cfg['mlvl'][SORCERER] = '0';
$cfg['cap'][SORCERER] = '470';

// Skills:               fist,	club,	sword,	axe,	dist,	shld,	fish
$cfg['skill'][SORCERER] = array(10,	15,		15,		15,		15,		15,		15);

// Eq:               helm, amul, bp,  armor, rght, left, legs, boot, ring, ammo
$cfg['equip'][SORCERER] = array(2480, 2172, 2000, 2464, 0, 2530, 2468, 2643, 0, 0);

// Backpack:
$cfg['bp'][SORCERER] = '<item id="2554"/><item id="2120"/><item id="2398"/><item id="2412"/><item id="2388"/><item id="2190"/>';

//--------------------------------- Druid --------------------------------------
// Looks
$cfg['look'][DRUID][MALE] = '130';
$cfg['look'][DRUID][FEMALE] = '138';

// HP, mana, magic level
$cfg['health'][DRUID] = '185';
$cfg['mana'][DRUID] = '40';
$cfg['mlvl'][DRUID] = '0';
$cfg['cap'][DRUID] = '470';

// Skills:               fist,	club,	sword,	axe,	dist,	shld,	fish
$cfg['skill'][DRUID] = array(10,	15,		15,		15,		15,		15,		15);

// Eq:               helm, amul, bp,  armor, rght, left, legs, boot, ring, ammo
$cfg['equip'][DRUID] = array(2480, 2172, 2000, 2464, 0, 2530, 2468, 2643, 0, 0);

// Backpack:
$cfg['bp'][DRUID] = '<item id="2554"/><item id="2120"/><item id="2398"/><item id="2412"/><item id="2388"/><item id="2182"/>';

//-------------------------------- Paladin -------------------------------------
// Looks
$cfg['look'][PALADIN][MALE] = '129';
$cfg['look'][PALADIN][FEMALE] = '137';

// HP, mana, magic level
$cfg['health'][PALADIN] = '185';
$cfg['mana'][PALADIN] = '40';
$cfg['mlvl'][PALADIN] = '0';
$cfg['cap'][PALADIN] = '470';

// Skills:               fist,	club,	sword,	axe,	dist,	shld,	fish
$cfg['skill'][PALADIN] = array(10,	15,		15,		15,		15,		15,		15);

// Eq:               helm, amul, bp,  armor, rght, left, legs, boot, ring, ammo
$cfg['equip'][PALADIN] = array(2480, 2172, 2000, 2464, 0, 2530, 2468, 2643, 0, 0);

// Backpack:
$cfg['bp'][PALADIN] = '<item id="2554"/><item id="2120"/><item id="2398"/><item id="2412"/><item id="2388"/><item id="2389" count="3"/>';

//--------------------------------- Knight -------------------------------------
// Looks
$cfg['look'][KNIGHT][MALE] = '131';
$cfg['look'][KNIGHT][FEMALE] = '139';

// HP, mana, magic level
$cfg['health'][KNIGHT] = '185';
$cfg['mana'][KNIGHT] = '40';
$cfg['mlvl'][KNIGHT] = '0';
$cfg['cap'][KNIGHT] = '470';

// Skills:               fist,	club,	sword,	axe,	dist,	shld,	fish
$cfg['skill'][KNIGHT] = array(10,	20,		20,		20,		15,		20,		15);

// Eq:               helm, amul, bp,  armor, rght, left, legs, boot, ring, ammo
$cfg['equip'][KNIGHT] = array(2480, 2172, 2000, 2464, 0, 2530, 2468, 2643, 0, 0);

// Backpack:
$cfg['bp'][KNIGHT] = '<item id="2554"/><item id="2120"/><item id="2398"/><item id="2412"/><item id="2388"/>';

//-------------------------------- No Vocation ---------------------------------
// Looks
$cfg['look'][NOVOC][MALE] = '130';
$cfg['look'][NOVOC][FEMALE] = '138';

// HP, mana, magic level
$cfg['health'][NOVOC] = '150';
$cfg['mana'][NOVOC] = '0';
$cfg['mlvl'][NOVOC] = '0';
$cfg['cap'][NOVOC] = '400';

// Skills:               fist,	club,	sword,	axe,	dist,	shld,	fish
$cfg['skill'][NOVOC] = array(1,	1,		1,		1,		1,		1,		1);

// Eq:               helm, amul, bp,  armor, rght, left, legs, boot, ring, ammo
$cfg['equip'][NOVOC] = array(0, 0, 3939, 2650, 2382, 0, 0, 0, 0, 2050);

// Backpack:
$cfg['bp'][NOVOC] = '<item id="2674"/>';

//-------------------------- NOOB SENSATIVE -----------------------------------

//relative paths hidden here from newbs. If you are one: DO NOT EDIT
$cfg['diraccount'] = $cfg['dirdata'].'accounts/';
$cfg['dirplayer'] = $cfg['dirdata'].'players/';
$cfg['dirmonster'] = $cfg['dirdata'].'monster/';
$cfg['dirvip'] = $cfg['dirdata'].'vip/';
$cfg['dirhouse'] = $cfg['dirdata'].'houses/';
$cfg['dirdeleted'] = $cfg['dirdata'].'deleted/';

//-------------------------- END OF CONFIGURATION -----------------------------

//checking if directories defined previously really exist
if (!(is_dir($cfg['dirplayer']) && is_dir($cfg['diraccount']))){
	$error = "Warning!<br/>\n Please set correct data directory in config.php";
}

//checking if IP not banned
if (file_exists('banned.txt')){
$banned_ips = file ('banned.txt');
foreach ($banned_ips as $ip){
	if ($ip == $_SERVER['REMOTE_ADDR']){
		die("Sorry, your IP is banned from the website."); 
		//ha ha ha. die die die. I love this function :D you're dead bye :P
	}
}
}

//Calculating correct exp for level
$cfg['exp'] = round(50*($cfg['lvl']-1)*($cfg['lvl']*$cfg['lvl']-5*$cfg['lvl']+12)/3);
$cfg['lvl'] = floor($cfg['lvl']);

//disable magic_quotes_gpc. ty wrzasq
if( get_magic_quotes_gpc() )
{
  $_POST = array_map('stripslashes', $_POST);
  $_GET = array_map('stripslashes', $_GET);
  $_COOKIE = array_map('stripslashes', $_COOKIE);
  $_REQUEST = array_map('stripslashes', $_REQUEST);
}

//Check for correct PHP version
if (!version_compare(phpversion(), "5.1.4", ">=") )
	$error = "You need PHP 5.1.4 or later to run this AAC. Try the latest XAMPP.";

//Check if extensions loaded
if (!extension_loaded('simplexml'))
	$error = "SimpleXML is not enabled in php.ini";
?>


php.ini (Because of length limits, I'm only posting the section mentioned earlier. There are two instances of short_open_tag. Both I have set to on.)

PHP:
; short_open_tag
;   Default Value: On
;   Development Value: Off
;   Production Value: Off

----------------------------------------------------------
;;;;;;;;;;;;;;;;;;;;
; Language Options ;
;;;;;;;;;;;;;;;;;;;;

; Enable the PHP scripting language engine under Apache.
; http://php.net/engine
engine = On

; This directive determines whether or not PHP will recognize code between
; <? and ?> tags as PHP source which should be processed as such. It's been
; recommended for several years that you not use the short tag "short cut" and
; instead to use the full <?php and ?> tag combination. With the wide spread use
; of XML and use of these tags by other languages, the server can become easily
; confused and end up parsing the wrong code in the wrong context. But because
; this short cut has been a feature for such a long time, it's currently still
; supported for backwards compatibility, but we recommend you don't use them.
; Default Value: On
; Development Value: Off
; Production Value: Off
; http://php.net/short-open-tag
short_open_tag = On

If you could help me that would be awesome. One less problem to worry about. Also if you need me to post anymore information, that would be cool.
(SIDE NOTE: Not sure if it's related, but I've already portforwarded ports 7171 and 8000 on both TCP and UDP for OTserv.)

- - - Updated - - -

Nevermind, my problem was solved. I am running a 7.6 OT.

I downgraded my xampp for 1.6.6, and the site worked. Highscore page will work when you change the IP in config.php from "localhost" to your server IP.

Problem solved for me.
 
Back
Top Bottom