-1

EDIT: I need to rephrase my question

I am trying to install PHP5 for Apache on Kali Linux but it is not working.

I am entering in:apt-get install libapache2-mod-php5

and am getting this error: `Package libapache2-mod-php5 is not available, but is referred to by another package.

This may mean that the package is missing, has been obsoleted, or only available from another source`

Tech Dynasty
  • 163
  • 1
  • 4
  • 11
  • Then install php? I fail to see what the issue is here, just google "How to install php5 on linux" – Epodax Sep 16 '16 at 09:31
  • I have tried to look it up. None of them tell me how to install PHP5 with apache on kali linux. I have tried to use the apt-get install command from the official php website but it cant find the packages – Tech Dynasty Sep 16 '16 at 09:33
  • What distro+version are you using? PHP in apache2 either works through mod_php or through (f)cgi. – mroman Sep 16 '16 at 09:51
  • Kali linux is for penetration testing, it is not a general purpose GNU/Linux distribution. – Jared Smith Sep 12 '18 at 01:15

1 Answers1

0

Firstly you will have to enter this command to update and upgrade the entire linux environment and tools.

apt-get clean && apt-get -y update && apt-get -y upgrade && apt-get -y dist-upgrade && apt autoremove 

After running this command, you can try to install libapache2-mod-php5 package. If that does not work, I can recommend you to install xammp which includes php, mysql, mariadb, phpadmin. I hope this will help you.

J E Carter II
  • 1,436
  • 1
  • 22
  • 39