# Two Version of PHP running?



## captcurrent (Feb 18, 2019)

I am not sure is this is the right place or forum for my question, but
I am running FreeBSD 11.2 and appache 24
During a recent maintenance I upgraded (or thought I did ) from php 5.6  to php 7.3.2

I hae been trying to debug a couple of residual issue  (primaryily with font substitution)   so I have been trying to check the php configuration.   I have a test web page to present phpinfo().    
It keeps saying that the version is 5.6.32


if I run
`php - i`

from command line it get


> phpinfo()
> 
> PHP Version => 7.3.2


`pkg info`

shows version 7.32 ons installed with no reference to 5.6.32

Any thoughts or suggestions ?


----------



## kpedersen (Feb 18, 2019)

It looks like your cli version of php is 7.3.2 whereas your mod_php (Apache2 module) or php_cgi (Apache2 cgi package) is 5.6.32?

So `pkg info | grep php` doesn't show any version at 5.6.32?


----------



## SirDice (Feb 19, 2019)

`pkg install mod_php73` will fix it.


----------



## captcurrent (Feb 19, 2019)

Thanks to kpdersen..   I don't know how I missed that  I guess I dont spend enought time withFreeBSD
 SirDice since i build this server  from ports, I assume i was correct to do the installation from  /usr/ports/www/mod_php73  ?


----------



## SirDice (Feb 19, 2019)

I suggest using packages. Unless you have a need to deviate from the default options there's no reason to build from ports.


----------



## captcurrent (Feb 19, 2019)

Thanks for the suggestion...   Is there a guide to switch from ports to pkgs?     Been runnig this server since FreeBSD 9?


----------



## SirDice (Feb 20, 2019)

Just start using packages exclusively. There's nothing to "convert".


----------

