Go Back   DaemonForums > OpenBSD > OpenBSD Installation and Upgrading

OpenBSD Installation and Upgrading Installing and upgrading OpenBSD.

Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1   (View Single Post)  
Old 3rd June 2013
yce44 yce44 is offline
New User
Join Date: Jun 2013
Posts: 2
Default openbsd 5.3 - php not working


I can't make php works on an openbsd5.3 box. The php files are displayed as plain text files, or even worst, I'm asked if I want to download them, it seems that the server not parse at all the php code.
After installing the OS, I followed a tutorial for installing the MySQL and PHP support for it, installing the latest packages available (pkg_add). I can't post the link to it since this is my first post here .
Everything installed with no problems, I did created the suggested soft links.
I started Apache server and works. When I wanted to test php with the classic test file: <?php phpinfo(); ?> I get the file content displayed as plaint text file.

In httpd.conf I did the following changes:
- uncomment:
#AddType application/x-httpd-php .php
- add index.php to DirectoryIndex
DirectoryIndex index.html index.php

I copied the development php-5.3.ini file to /var/www/conf/php.ini

Running in term
php -v
doesn't work. I found the problem to be from the name of php binary which is /usr/local/bin/php-5.3. I created a soft link to php-5.3 as php and now
php -v
works, the output being:
PHP 5.3.21 with Suhosin-Patch (cli) (built: Feb 25 2013 20:15:10)
Copyright (c) 1997-2013 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2013 Zend Technologies
    with Suhosin v0.9.33, Copyright (c) 2007-2012, by SektionEins GmbH
What's wrong?

Thanks for anything..
Reply With Quote

apache, openbsd, php

Thread Tools
Display Modes

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

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
My keyboard is not working properly anymore in OpenBSD newbsdied OpenBSD General 2 4th November 2010 11:20 PM
Mouse:X (not-working) and tty-Console (working), in 8.0 ykt FreeBSD General 1 22nd December 2009 12:26 PM
[ OpenBSD 4.5 ] apm -C not working wraith0x2b OpenBSD Installation and Upgrading 17 6th May 2009 09:03 AM
Working around cheap SOHO routers under OpenBSD BSDfan666 Guides 1 23rd November 2008 07:44 PM
Working Configuration for Openbsd 4.0 - Postfix - SASL - TLS roundkat Guides 0 4th May 2008 05:38 PM

All times are GMT. The time now is 09:09 AM.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick