7

I installed apache2 and php 5.4.5.

When you start apache this error:

PHP Warning: PHP Startup: in Unknown on line 0

The extension does not work:

; extension = php_intl.dll
; extension = php_ldap.dll
; extension = php_oci8.dll
; extension = php_oci8_11g.dll
; extension = php_pdo_firebird.dll
; extension = php_pdo_oci.dll
; extension = php_pdo_pgsql.dll
; extension = php_pgsql.dll
; extension = php_pspell.dll
; extension = php_shmop.dll

And maybe more.

Extensin dir: extension_dir = "C :/ dev/prog/php5/ext /"

Path: C: \ dev \ prog \ php5

php.ini is copied to C: \ WINDOWS \

ssleay32.dll php5ts.dll and is copied to C: \ WINDOWS \ system32 \

Please simple instructions.

3
  • Have you configured extension_dir in php.ini? You'll get much more useful error messages if you just try and run the PHP CLI - open a command prompt, cd to the PHP install directory and run php -r "echo 'Hello World!';" Commented Aug 15, 2012 at 10:17
  • Yes, and copy to C:\WINDOWS ERROR in command promt: Warning: PHP Startup: Unable to load dynamic library C:\dev\prog\php5\ext\php_interbase.dll in Unkown on line 0 Commented Aug 15, 2012 at 10:19
  • are the spaces before "dev" and after "ext" a copy error? Commented Aug 15, 2012 at 10:19

10 Answers 10

4

upgrade those modules using pecl command

Also, Check extension_dir directive in php.ini

Sign up to request clarification or add additional context in comments.

1 Comment

Can not find the command for the update. Extension dir is fine.
3

I had the same problem. The issue is, that these lines are by default in php.ini

; On windows:
; extension_dir = "ext" 

I assumed, that only an uncomment of the second line and Apache restart solves this problem. But it isn't!

I had to type a full path to the ext folder, such as below:

extension_dir = "d:\php-5.4.32\ext"

After this action, and restart of the Apache web server, the problem was solved.

1 Comment

This is the most correct answer! Even for Apache 2.4+PHP 5.6. The relative path possibly only works for Linux.
2

You should check you php.ini file to make sure the extension_dir is exactly set. I had the same problem when i enable these five extensions:

extension=php_mbstring.dll
extension=php_exif.dll
extension=php_mysql.dll
extension=php_mysqli.dll
extension=php_curl.dll

The number of warnings is the same as the extensions that enabled. So i guess may be there is sth. wrong with the extension setting. When i change the extension_dir directive to the right dir, the problem resolved.

Comments

2

I found this answer in this post on the wampserver forums, and it worked for me:

Click on the Apache version that you use in the WAMPServer menu, e.g.

wampmanager -> Apache -> Version -> 2.4.9 ( just click on the version number on this menu item )

this will rebuild the SYMLINKS for the extensions that are causing the "in Unknown on line 0" error.

WAMPServer menu

The answer was given by RiggsFolly in this thread: http://forum.wampserver.com/read.php?2,128734

Comments

1

I had the same problem when I enabled extensions (see Error when enabling PHP extensions).

I resolved it adding the PHP folder to the path and restarting the computer.

Comments

1
  1. You need to download and install Aspell for Windows “GNU Aspell-0.50.3 (win32)”.

http://aspell.net/win32/

http://ftp.gnu.org/gnu/aspell/w32/Aspel ... -Setup.exe

Your Dictionaries are also here. Aspell needs at least one Dictionary to operate.

or

ftp://ftp.gnu.org/gnu/aspell/w32/

ftp://ftp.gnu.org/gnu/aspell/w32/Aspell ... -Setup.exe

ftp://ftp.gnu.org/gnu/aspell/w32/aspell-w32-0.50.3.zip

  1. Aspell should copy the “aspell-15.dll” to the “Windows/System32” directory which the php entension php_pspell.dll requires and looks for to execute. If not then locate aspell-15.dll in C:/Program Files/Aspell/bin/aspell-15.dll and copy it to C:/Windows/System 32/aspell-15.dll

  2. You only need now to uncomment this line in: xampp/apache/bin/php.ini ;extension=php_pspell.dll to this: extension=php_pspell.dll

  3. Restart Apache. (If Apache won't start paste the error message here).

  4. Check the pspell module is in place and enabled by lookin at your phpinfo() file from the menu within the XAMPP Welcome Page. http://localhost/index.php For more info visit https://community.apachefriends.org/f/viewtopic.php?p=83942

2 Comments

Hi @cmaxik if this or any answer has solved your question please consider accepting it meta.stackexchange.com/a/5235/287197 by clicking the check-mark. This indicates to the wider community that you've found a solution and gives some reputation to both the answerer and yourself. There is no obligation to do this.
I had to copy aspell-15.dll to my /PHP/ root folder to get it to work > apache to start.
1

The problem is not coming from there, the problem is from the path (I mean %PATH% for Windows users, because of %PATH% is a variable that contains many paths separated by ;). So to figure out the problem you have to:

1-make configuration in the httpd.conf file:

PHPIniDir "${path}/conf_files"

2-make configuration in your php.ini file (it must be in the same location with the httpd.conf file): change this:

extension_dir = "${path}\php\ext\"

To

extension_dir = "D:\EasyPHP5.3.0\php\ext\"

(in my case the php is installed in D:\EasyPHP5.3.0)

Optional:

if you need to execute PHP from the CLI (Command Prompt) you have to make copy of the php.ini file to the folder when the PHP is installed (in my case D:\EasyPHP5.3.0\php)

Restart/Start your web Server and enjoy!

Comments

0

I had similar problem. cURL required SSL layer. Problem was in installation of php_curl library, see http://php.net/manual/en/curl.installation.php. The firs problem: libeay32.dll and ssleay32.dll are required on PATH. I put them in apache/bin directory. The second problem is that php.ini required php_openssl loaded before php_curl so I modified ini file.

extension=php_openssl.dll
extension=php_curl.dll

Comments

0

I solved the problem on my windows 7 with two steps:

  1. set extension_dir as absolute path in php.ini

    extension_dir = "d:\php-5.4.32\ext"

  2. comment the php_curl.dll module in php.ini

    ;extension=php_curl.dll

Comments

0

Same problem was solved by changing to full path:
PHPIniDir in httpd.conf and extension_dir in php.ini.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.