/    Sign up×
Community /Pin to ProfileBookmark

Hi, so I’m creating my first website and I’m just trying to figure out to run the configure.php file. If I write all the connection info and parameters of the site correctly, does it connect automatically or do I need to write the config.php somewhere else in the index.html or other type of files? I had a .htaccess file but i had to remove it because it gave me an internal server error

to post a comment
PHP

2 Comments(s)

Copy linkTweet thisAlerts:
@repeater09Jul 23.2011 — put this at the beginning of your html file

include('configure.php');

//make sure you put ur path file in the ()

example my db connections are in a folder called includes so..

mine will be

<?php

include('..includes/configure.php');

?>

//then html stuff
Copy linkTweet thisAlerts:
@NogDogJul 24.2011 — If it is essential that the file be included for the rest of the script to run, then you may want to use require() instead of include().
×

Success!

Help @Cosmonautical spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.2,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,
)...