iSTORYA.NET

Go Back   iSTORYA.NET > Science & Technology > Software & Games > Programming
: :

Register FAQ Members List Calendar Mark Forums Read

Programming :: Programming related discussions ::

Reply
LinkBack Thread Tools
  #1  
Old 06-18-2009, 06:53 PM
Junior Member
dezheavensent is offline
dezheavensent's Avatar
Join Date: Oct 2008
Gender: Female
Posts: 72
Post Need help... PHP Error

Please help me solve this PHP error:

Notice: Use of undefined constant DOCUMENT_ROOT - assumed 'DOCUMENT_ROOT' in C:\wamp\www\RAPSystem\viewer.php on line 18

I really need your help badly...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2  
Old 06-18-2009, 06:57 PM
Elite Member
bluedes is offline
bluedes's Avatar
Join Date: Jan 2009
Gender: Male
Posts: 1,943
Default

Quote:
Originally Posted by dezheavensent View Post
Please help me solve this PHP error:

Notice: Use of undefined constant DOCUMENT_ROOT - assumed 'DOCUMENT_ROOT' in C:\wamp\www\RAPSystem\viewer.php on line 18

I really need your help badly...
post imong code brad, para matrace ang imong problema..
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3  
Old 06-18-2009, 08:07 PM
Junior Member
dezheavensent is offline
dezheavensent's Avatar
Join Date: Oct 2008
Gender: Female
Posts: 72
Default Lain nasad ako error

got it solved. Lain nasad ako error:

Warning: include(C:/wamp/www/rap_admin/config.php) [function.include]: failed to open stream: No such file or directory in C:\wamp\www\RAPSystem\viewer.php on line 21

Warning: include() [function.include]: Failed opening 'C:/wamp/www/rap_admin/config.php' for inclusion (include_path='.;C:\php5\pear') in C:\wamp\www\RAPSystem\viewer.php on line 21

Warning: include(C:/wamp/www/rap_admin/settings.php) [function.include]: failed to open stream: No such file or directory in C:\wamp\www\RAPSystem\viewer.php on line 22

Warning: include() [function.include]: Failed opening 'C:/wamp/www/rap_admin/settings.php' for inclusion (include_path='.;C:\php5\pear') in C:\wamp\www\RAPSystem\viewer.php on line 22

Ni exist man ang config.php and settings.php.

Mao ni ang code:

<?php
// ////////////////////////////////////////////////////////////
// v3.0.3
// Copyright ©2007 Rapidsys_tmpl_folder in Action Profits. All Rights Reserved
//
// The sale, duplication or transfer of the script to any
// person other than the original purchaser is a violation
// of the purchase agreement and is strictly prohibited.
//
// Any alteration of the script source code or accompanying
// materials will void any responsibility of Rapid Action
// Profits regarding the proper functioning of the script.
//
// By using this script you agree to the terms and conditions
// of use of the script.
// ////////////////////////////////////////////////////////////

$configfile = $_SERVER['DOCUMENT_ROOT']."rap_admin/config.php";
$settingsfile = $_SERVER['DOCUMENT_ROOT']."rap_admin/settings.php";

include ($configfile);
include($settingsfile);

function sys_downloadlink($oto){
return "$_SERVER[PHP_SELF]?action=dwnld&oto=$oto";
}

function sys_auto_optin() {
echo ($auto_optin = "");
}

function refstats($nickname)
{
return ($html = "Reseller/JV Stats Table will Show Here");
}

function catalog($nickname)
{
return ($html = "Your Product Catalog will Show Here");
}

$p="none";
if(isset($_REQUEST['p'])) {
$p = $_REQUEST['p'];
$sys_tmpl_folder='';
$filename = $sys_tmpl_folder.$p;

switch ($p)
{
case "zips" :
$filename = $sys_tmpl_folder."zips.html";
break;

case "squeeze" :
$filename = $sys_tmpl_folder."squeeze.html";
break;

case "download" :
$filename = $sys_tmpl_folder."download.html";
break;

case "oto" :
$filename = $sys_tmpl_folder."oto.html";
break;

case "otodownload" :
$filename = $sys_tmpl_folder."otodownload.html";
break;

case "taf" :
$filename = $sys_tmpl_folder."taf.html";
break;

case "ototaf" :
$filename = $sys_tmpl_folder."ototaf.html";
break;

case "expired" :
$filename = $sys_tmpl_folder."expired.html";
break;

case "invalid" :
$filename = $sys_tmpl_folder."invalid.html";
break;

case "invalidreferrer" :
$filename = $sys_tmpl_folder."invalidreferrer.html";
break;

case "partners" :
$filename = $sys_tmpl_folder."partners.html";
break;

case "partnerthanks" :
$filename = $sys_tmpl_folder."partnerthanks.html";
break;

case "affiliates" :
$filename = $sys_tmpl_folder."affiliates.html";
break;

case "affiliatethanks" :
$filename = $sys_tmpl_folder."affiliatethanks.html";
break;

case "soldout" :
$filename = $sys_tmpl_folder."soldout.html";
break;

case "affiliatetools" :
$filename = $sys_tmpl_folder."affiliatetools.html";
break;

case "presale" :
$filename = $sys_tmpl_folder."presale.html";
break;

case "offline" :
$filename = $sys_tmpl_folder."offline.html";
break;

case "affcenter" :
$filename = $sys_tmpl_folder."affcenter.html";
break;

case "afflogin" :
$filename = $sys_tmpl_folder."afflogin.html";
break;

case "chgaffdetails" :
$filename = $sys_tmpl_folder."chgaffdetails.html";
break;

case "getlogin" :
$filename = $sys_tmpl_folder."getlogin.html";
break;

case "goto_paypal" :
$filename = $sys_tmpl_folder."goto_paypal.html";
break;

case "from_paypal" :
$filename = $sys_tmpl_folder."from_paypal.html";
break;

case "payment_timeout" :
$filename = $sys_tmpl_folder."payment_timeout.html";
break;

case "giveaway" :
$filename = $sys_tmpl_folder."giveaway.html";
break;

case "fraud" :
$filename = $sys_tmpl_folder."fraud.html";
break;

case "comp" :
$filename = $sys_tmpl_folder."comp.html";
break;

case "subscriberoptions" :
$filename = $sys_tmpl_folder."subscriberoptions.html";
break;

default :
$filename = $sys_tmpl_folder.$p;
break;
}
}
# SHOW SELECTED TEMPLATE
# ______________________

$header = $sys_tmpl_folder."header.html";
$footer = $sys_tmpl_folder."footer.html";
if(is_file($filename))
{
@include($header);
include($filename);
@include($footer);
} else {
echo "WHAT ".$p." not recognized";
}
?>


Thanks for your speedy reply...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4  
Old 06-19-2009, 07:56 AM
Junior Member
raybanz21 is offline
raybanz21's Avatar
Join Date: Sep 2008
Gender: Male
Posts: 152
Default

Quote:
include ($configfile);
include($settingsfile);
dili pwede ani?

include ('/rap_admin/config.php'); or include ('rap_admin/config.php');
include ('/rap_admin/settings.php'); or include ('rap_admin/settings.php');

ask lng...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5  
Old 06-19-2009, 10:42 AM
Elite Member
bluedes is offline
bluedes's Avatar
Join Date: Jan 2009
Gender: Male
Posts: 1,943
Default

rap_admin lage na ang path nimo, unya sa report kay RAPSystem.. isynchronize lng ang directory names..

document root man na imong gamit, so make sure ni-exist na ang files kung asa imong document root..
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6  
Old 06-19-2009, 10:49 AM
Junior Member
junkfactory is offline
Join Date: Jun 2009
Gender: Male
Posts: 46
Default

Kutob sa mahimo, ayaw gamita ang DOCUMENT_ROOT nga global var. Kay daghan kaayo paagi pag configure sa apache. VirtualHost lang daan paksit na.

Daghan sad paagi pag solve sa imo prob. Ang nindot para nako kay sa start palang sa imo project, naa naka standard directory structure gina follow. Naay includes, controllers, ... etc folders. So pwede dayon ka mo dirname(__FILE__)/<relative_path>/config.php
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7  
Old 06-19-2009, 12:29 PM
Junior Member
dezheavensent is offline
dezheavensent's Avatar
Join Date: Oct 2008
Gender: Female
Posts: 72
Default

Na solve na cya...

Thanks for you ideas, it really helped me.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
"a disk read error occurred. press ctrl+alt+del to restart" error. help! JJ_Inspimac Software & Games 7 10-15-2009 02:23 PM
help!!!... windows explorer error/drwatson postmortem debugger error pasyano Software & Games 12 08-20-2009 12:46 AM
How reliable is an HDD after having "Data Error: Cyclic Redundancy Check" error? yarniwre Computer Hardware 5 10-20-2008 02:19 PM
system error "autolt error" pa0pa0 Software & Games 3 10-28-2007 05:18 AM
error: MICROSOFT VISUAL C++ runtime error upon opening AVI files Wayth Vader Software & Games 5 10-03-2007 06:40 PM


All times are GMT +8. The time now is 12:43 PM.


Powered by vBulletin® Version 3.7.6
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.0
(c) 2002-2009 iSTORYA.NET | Design by DrE | Modifications by BeoR