Author |
|
h4ckler
Joined: 07 Aug 2009 Posts: 5 Location: Midwest
|
Posted: Fri 07 Aug '09 5:15 Post subject: PHP Pre-configuration failed. |
|
|
I tried my best to avoid having to register on a board and clog it with what may be a worthless question, but here goes.
I'm teaching myself PHP5 + MySQL. Everything was going great until I needed to place mysqli_connect() into my codes. I am now aware of other ways to connect to MySQL but the book I am using is using mysqli commands. The original setup was giving me fits as it was a hack job that my friend and I just cut/paste until the thing worked.
So I uninstalled PHP/APACHE. I figured starting from scractch and actually learning things could help me.
I've downloaded apache_2.2.11-win32-x86-openssl-0.9.8i.msi and php-5.2.10-nts-Win32-VC6-x86.zip; and I am running Vista Prof.
So here's my dilema.
I've got everything configured the way it needs to be (I believe), but now I go to run the server and it fails to start.
I've ran the test config and it tells me the following:
"[crit] Apache is running a threaded MPM, but your PHP Module is not compiled to be threadsafe. You need to recompile PHP.
Pre-configuration failed"
...and now I have a few questions.
What is "threadsafe"?
(and) How do I fix this so I can get back to learning?
I've finally broken down and posted a question after roughly 6 hours of searching and trying to figure it out.
Thanks ahead of time! |
|
Back to top |
|
h4ckler
Joined: 07 Aug 2009 Posts: 5 Location: Midwest
|
Posted: Fri 07 Aug '09 5:20 Post subject: |
|
|
Figured it out...
I thought. When I run htt://localhost i get the "it works" page. But I cannot get a page i made with phpinfo() to run. I just see the markup. |
|
Back to top |
|
h4ckler
Joined: 07 Aug 2009 Posts: 5 Location: Midwest
|
Posted: Fri 07 Aug '09 5:57 Post subject: |
|
|
I've got a page that displayed phpinfo()
BUT, under Loaded Configuration File is "none" and none of my created .php files will run when I call them from a browser.
|
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7373 Location: Germany, Next to Hamburg
|
Posted: Fri 07 Aug '09 12:13 Post subject: |
|
|
Well, you downloaded the NTS == Non thread safe version of PHP. You should download the thread safe version
Zip
After unpacking the Zip you can rename the php.ini-recommend to php.ini and customize your ini. Else PHP will run with default values. |
|
Back to top |
|
h4ckler
Joined: 07 Aug 2009 Posts: 5 Location: Midwest
|
Posted: Wed 12 Aug '09 3:52 Post subject: |
|
|
Ok I've checked everything and I'm good. I run my script and I get a blank page and not the results/confirmation that my a database entry was made.
Is apache just not speaking with MySQL? I'm some what lost.
(thanks again) |
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7373 Location: Germany, Next to Hamburg
|
Posted: Wed 12 Aug '09 20:14 Post subject: |
|
|
Can you please post a sample code snippet? |
|
Back to top |
|
h4ckler
Joined: 07 Aug 2009 Posts: 5 Location: Midwest
|
Posted: Thu 13 Aug '09 4:17 Post subject: |
|
|
Thanks, but I gave up and download xampp. |
|
Back to top |
|
Pierre
Joined: 23 Dec 2008 Posts: 23
|
Posted: Sun 16 Aug '09 12:01 Post subject: |
|
|
h4ckler wrote: | Thanks, but I gave up and download xampp. |
Well, it was a common mistake. You fetched the NTS (non thread safe) builds but apache requires the thread safe version. |
|
Back to top |
|