Results 1 to 4 of 4

Thread: Php installation

  1. #1
    Member omidkamangar's Avatar
    Join Date
    Mar 2006
    Location
    Kurdistan
    Posts
    239

    Unhappy Php installation

    Hi , I have installed Linux FC3 On my system(I have installed it complete).
    Is apache and php installed by default.I don't know how to run a php script on it. I would apreciate any help.

  2. #2
    Moderator
    Good Guru
    Compunuts's Avatar
    Join Date
    May 2001
    Location
    California
    Posts
    3,935
    I believed you can check with "rpm -q <packagename>" command.

    If not installed, you can do "yum install <packagename". In your case, it would be "yum install apache2".

    If you need further reading for how to use yum and stuff, check out here
    LinuxVillage - The truely community run Linux/Floss forum !

    No IT BS !!

  3. #3
    Moderator
    Good Guru
    Schotty's Avatar
    Join Date
    Jul 2001
    Location
    Milwaukee, WI
    Posts
    5,760
    I know jack **** about php to be honest but to find installed software you need to do the following:

    rpm -qa | grep apache
    rpm -qa | php


    That bar is the pipe symbol, and is very hady in Linux. On my keyboard it is next to the bracket key (a shift + \ ).

    Alternatively, I would see if yumex runs on FC3 (should) and use that as a rather decent yum gui. And get yum setup too, that is a must.

  4. #4
    Associate
    Join Date
    Apr 2006
    Posts
    16
    Quote Originally Posted by omidkamangar
    Hi , I have installed Linux FC3 On my system(I have installed it complete).
    Is apache and php installed by default.I don't know how to run a php script on it. I would apreciate any help.
    They usually are.

    you run a php script by typing "php" at the command prompt

    Actually you will usually follow that with the name of your script, like:

    php index.php

    Most php scripts are designed to output html code essentially so you can quickly check if index.php is doing what you want by doing the following:

    php index.php > index.html

    which will write the output to index.html (and *overwrite* any existing index.html file - be careful). You can then open index.html in your favourite browser to see if it looks the way you expect, eg:

    firefox index.html

    That's how I test my php scripts before uploading them to the webhosting servers.

    Of course, it is probably best to set up your own apache & php servers on your localhost to test the whole thing live on your local machine but I haven't done this so can't help you there.

    James

Similar Threads

  1. Installation
    By pawnbeeta in forum Linux - General Topics
    Replies: 4
    Last Post: 09-14-2007, 10:10 PM
  2. yum installation
    By aman_andromeda in forum Linux - General Topics
    Replies: 1
    Last Post: 02-28-2007, 12:38 PM
  3. Installation
    By imported_SuBSe7eN in forum Linux - General Topics
    Replies: 11
    Last Post: 10-18-2005, 05:45 AM
  4. DNS installation
    By deepak in forum Linux - General Topics
    Replies: 1
    Last Post: 06-08-2005, 07:43 PM
  5. Red Hat installation prob
    By kantplayalik in forum Linux - General Topics
    Replies: 2
    Last Post: 01-13-2005, 12:15 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •