Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Networking & Security
  • Search

PHP, apache, and phpmyadmin

Having problems getting connected to the internet or running a server? Wondering about securing your box? Ask here.
Post Reply
Advanced search
6 posts • Page 1 of 1
Author
Message
asciifish
n00b
n00b
Posts: 36
Joined: Fri Nov 28, 2003 6:05 pm

PHP, apache, and phpmyadmin

  • Quote

Post by asciifish » Wed Dec 17, 2003 4:24 am

I'm trying to get a webserver running. Following the directions on another post since I needed, sql and php on the server, i emerged phpmyadmin and let that install apache, mod_php, etc. I change the /etc/conf.d/apache2 to read like the following:

Code: Select all

# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /home/cvsroot/gentoo-x86/net-www/apache/files/2.0.40/apache2.confd,v 1.5 2003/09/27 04:47:18 woodchip Exp $
                                                                                
# Config file for /etc/init.d/apache2
                                                                                
# An example from /etc/apache2/conf/modules.d/40_mod_ssl.conf:
#
# <IfDefine SSL>
#  <IfModule !mod_ssl.c>
#    LoadModule ssl_module    extramodules/mod_ssl.so
#  </IfModule>
# </IfDefine>
#
# This means that the mod_ssl.so DSO module is only loaded
# into the server when you pass "-D SSL" at startup.  To
# enable WebDAV, add "-D DAV -D DAV_FS".  If you installed
# mod_php then add "-D PHP4".  For more options, please
# read the files in the /etc/apache2/conf/modules.d directory.
                                                                                
#APACHE2_OPTS="-D SSL -D SSL"
and restarted apache.

My problem is that when i view a php page, i see all the php code. What did i do wrong in the setup? What did I leave out?
Top
adpowers
n00b
n00b
Posts: 25
Joined: Tue Jan 14, 2003 8:05 pm
Contact:
Contact adpowers
Website

  • Quote

Post by adpowers » Wed Dec 17, 2003 4:34 am

Do you have any lines like this?

Code: Select all

AddType  application/x-httpd-php         .php .php4 .php3 .phtml
AddType  application/x-httpd-php-source  .phps
Andrew
Top
Chris W
l33t
l33t
User avatar
Posts: 972
Joined: Tue Jun 25, 2002 11:38 am
Location: Brisbane, Australia

  • Quote

Post by Chris W » Wed Dec 17, 2003 5:14 am

From your /etc/conf.d/apache2 as quoted above:

Code: Select all

#APACHE2_OPTS="-D SSL -D SSL"
I think what you meant to do was:

Code: Select all

APACHE2_OPTS="-D SSL -D PHP4"
as decribed in the configuration file's comments. That is, uncomment the line and enable PHP4.
Cheers,
Chris W
"Common sense: The collection of prejudices acquired by age 18." -- Einstein
Top
asciifish
n00b
n00b
Posts: 36
Joined: Fri Nov 28, 2003 6:05 pm

  • Quote

Post by asciifish » Wed Dec 17, 2003 5:16 am

Where should I put these? I added them to commonapache2.conf but i still end up looking at the php code when i try access the site.
Top
Chris W
l33t
l33t
User avatar
Posts: 972
Joined: Tue Jun 25, 2002 11:38 am
Location: Brisbane, Australia

  • Quote

Post by Chris W » Wed Dec 17, 2003 9:28 am

In /etc/conf.d/apache2. The file you posted at the thead of this thread is not correct and my comments relate to that file.
Cheers,
Chris W
"Common sense: The collection of prejudices acquired by age 18." -- Einstein
Top
spp
n00b
n00b
Posts: 27
Joined: Fri Jul 11, 2003 12:40 pm
Location: Alexandria, VA USA

  • Quote

Post by spp » Wed Dec 17, 2003 2:49 pm

There are some further steps after installing PHP that need to be done. They are listed in the ebuild post install

Code: Select all

ebuild /var/db/pkg/dev-php/mod_php/mod_php-VERSION.ebuild config
Do this and many of your problems will go away.

SP
Installing Gentoo... (Still)
Top
Post Reply

6 posts • Page 1 of 1

Return to “Networking & Security”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic