Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

PHP Config File

Posted on 2012-04-08
4
Medium Priority
?
343 Views
Last Modified: 2012-04-09
I have this php web site that I have to make it run under IIS with mysql. here is the code for config.php

I cant get it run please help

in apachee server lines with define works fine but on IIS I couldnt define them correctly. what am I doing wrong. I am not a php person :(


<?php
//DIR
// DIR
// define('DIR_APPLICATION', '/home2/topo5249/public_html/kitap1/catalog/');
// define('DIR_SYSTEM', '/home2/topo5249/public_html/kitap1/system/');
// define('DIR_DATABASE', '/home2/topo5249/public_html/kitap1/system/database/');
// define('DIR_LANGUAGE', '/home2/topo5249/public_html/kitap1/catalog/language/');
// define('DIR_TEMPLATE', '/home2/topo5249/public_html/kitap1/catalog/view/theme/');
// define('DIR_CONFIG', '/home2/topo5249/public_html/kitap1/system/config/');
// define('DIR_IMAGE', '/home2/topo5249/public_html/kitap1/image/');
// define('DIR_CACHE', '/home2/topo5249/public_html/kitap1/system/cache/');
// define('DIR_DOWNLOAD', '/home2/topo5249/public_html/kitap1/download/');
// define('DIR_LOGS', '/home2/topo5249/public_html/kitap1/system/logs/');
// Config Overrides
// See: http://expressionengine.com/wiki/Config_Overrides/
// See: http://expressionengine.com/wiki/Hidden_Configuration_Variables/
$CFG->wwwroot   = 'http://www.gulver.com.tr';
$CFG->dirroot   = 'C:\Gulver Web Production\';
$CFG->DIR_SYSTEM  = 'C:\Gulver Web Production\SYSTEM';
$CFG->DIR_DATABASE  = 'C:\Gulver Web Production\SYSTEM\DATABASE';
$CFG->DIR_LANGUAGE  = 'C:\Gulver Web Production\catalog\language\';
$CFG->DIR_TEMPLATE  = 'C:\Gulver Web Production\catalog\view\theme\';
$CFG->DIR_CONFIG  = 'C:\Gulver Web Production\SYSTEM\CONFIG\';
$CFG->DIR_IMAGE  = 'C:\Gulver Web Production\IMAGE\';
$CFG->DIR_DOWNLOAD  = 'C:\Gulver Web Production\DOWNLOAD\';
$CFG->DIR_CACHE  = 'C:\Gulver Web Production\SYSTEM\CACHE\';
$CFG->DIR_LOGS  = 'C:\Gulver Web Production\SYSTEM\LOGS\';
//DB
$CFG->dbtype = 'mysql';
$CFG->dbhost = 'localhost';
$CFG->dbname = 'mydbname';
$CFG->dbuser = 'myDbSuer';
$CFG->dbpass = 'myDbPasswrd';
$CFG->dbpersist = false;
$CFG->prefix = 'mdl_';
?>
0
Comment
Question by:HASANDIZ
  • 2
4 Comments
 
LVL 17

Expert Comment

by:Anuroopsundd
ID: 37820970
please go through below link to have PHP with MYsql on IIS. their can be many other things which may be breaking.. like environment variables.

http://www.dreamincode.net/forums/topic/39791-installing-and-configuration-iisphpmysql/
0
 

Author Comment

by:HASANDIZ
ID: 37821010
my phpinfo.php works fine, but my index.php does not
http://www.gulver.com.tr/phpinfo.php
0
 

Author Comment

by:HASANDIZ
ID: 37821026
I need to make these lines to define these directories that my application uses.

// define('DIR_APPLICATION', '/home2/topo5249/public_html/kitap1/catalog/');
// define('DIR_SYSTEM', '/home2/topo5249/public_html/kitap1/system/');
// define('DIR_DATABASE', '/home2/topo5249/public_html/kitap1/system/database/');
// define('DIR_LANGUAGE', '/home2/topo5249/public_html/kitap1/catalog/language/');
// define('DIR_TEMPLATE', '/home2/topo5249/public_html/kitap1/catalog/view/theme/');
// define('DIR_CONFIG', '/home2/topo5249/public_html/kitap1/system/config/');
// define('DIR_IMAGE', '/home2/topo5249/public_html/kitap1/image/');
// define('DIR_CACHE', '/home2/topo5249/public_html/kitap1/system/cache/');
// define('DIR_DOWNLOAD', '/home2/topo5249/public_html/kitap1/download/');
// define('DIR_LOGS', '/home2/topo5249/public_html/kitap1/system/logs/');
0
 
LVL 111

Accepted Solution

by:
Ray Paseur earned 2000 total points
ID: 37821470
Add these statements to the top of your index.php script:
error_reporting(E_ALL);
ini_set('display_errors', TRUE);

Then remove the double slashes from the statements (// turns the statement into a comment).

Try it again and post back here if you're still having issues with it.
0

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
Build an array called $myWeek which will hold the array elements Today, Yesterday and then builds up the rest of the week by the name of the day going back 1 week.   (CODE) (CODE) Then you just need to pass your date to the function. If i…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Suggested Courses

877 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question