PDA

View Full Version : VB_AREA or THIS_SCRIPT must be defined to continue...


khan3332
10-11-2005, 07:44 PM
<?php

require("../testforum/includes/functions_login.php");

require('../testforum/includes/init.php');

echo verify_authentication("hahayo", "hahayoyoyo", "", "", true, true);

?>

im trying to use the verify_auth function, but when i run the script from another directory, it gives me

VB_AREA or THIS_SCRIPT must be defined to continue

what does this mean....

Andreas
10-11-2005, 07:45 PM
It does mean that either VB_AREA or THIS_SCRIPT must be defined in order to continue script execution :)

khan3332
10-11-2005, 07:53 PM
does anyone know what i actually need to include to get this function working
from a custom script?

verify_authentication in /includes/functions_login.php

im going crazy =(

Andreas
10-11-2005, 07:56 PM
init.php and functions_login.php should be fine.

khan3332
10-11-2005, 08:00 PM
but then i get the error

VB_AREA or THIS_SCRIPT must be defined to continue

where do i define...

Andreas
10-11-2005, 08:04 PM
In your Script :)


define('VB_AREA', 'Forum');


before init.php for example.

khan3332
10-11-2005, 08:13 PM
more pain =*( one of the require in init.php doesn't use the right path

Warning: main(/usr/local/psa/home/vhosts/something.com/httpdocs/myapp/includes/class_core.php): failed to open stream: No such file or directory in /usr/local/psa/home/vhosts/something.com/httpdocs/testforum/includes/init.php on line 34

Fatal error: main(): Failed opening required '/usr/local/psa/home/vhosts/something.com/httpdocs/myapp/includes/class_core.php' (include_path='.:/usr/local/psa/apache/lib/php') in /usr/local/psa/home/vhosts/something.com/httpdocs/testforum/includes/init.php on line 34

Andreas
10-11-2005, 08:17 PM
define('CWD', '/usr/local/psa/home/vhosts/something.com/httpdocs/testforum');

before init.php

khan3332
10-11-2005, 08:26 PM
OH MY GOD it works now!! =)

thank youuuu