That is an invalid VirtualHost, you are missing a ServerName directive and stll, your Action clause is wrong (but its not executed anyway, as this VirtualHost does not have a ServerName, therefore Apache cannot decide when to choose it).

Forget about the ports, use Port 80 always, VirtualHosts do not work as you expect, please provide proper ServerName instead and copy my VirtualHost declaration. I cannot help you if you are messing aroung instead of taking my advice. Its on you, of course i immediately can stop here and let you alone. Both your VirtualHosts dont work. They are also lacking the Directory clause including "Require all granted" for the DocumentRoot.

You also should find the configuration for the PHP Module 5.6 and comment it out, do not use Module and CGI both.

Still wrong Action. In both VirtualHosts. You also should read the error_log, probably none your VirtualHosts are recognized. You still have PHP Moduled running, that collides with CGI. As you (again) do not show fuil configuration, i have no clue whats wrong. Actually, i am pretty sure that your VirtualHosts declarations arent recognized (as already said). Dont know why (maybe missing include or so), but for me it looks so. You would get 403/404 Errors in case of recognized VirtualHosts.

Therefore: Sorry - but this is now my last posting on that, i give up. Good luck.

Hi Ronnie.I mentionned that I did not changed the apache.conf and posted the 2 vhost files content. I think you have my all config ( apache.conf from the previous - previous post and module with changes now ). If there is somehting missing let me knowI obviously do not understand what you are saying that my action is not good. I posted you all path of the php version. what should I put then as action ? not the php exec file ( cgi one ? )When you say : php moduled running : I disabled php5.6 with "A2dismod php5.6". should I do something else ?I'm sorry if my english is not good

If your English is bad, no problem, there are sites like deepl.com. I'm using deepl.com now because it's easy.

You say you haven't changed apache.conf. That doesn't tell me anything, you obviously mistakenly believe that I know your installation. Here is the XAMPP forum and actually I only help XAMPP installations, but I tried to help other installations as well. But I don't have the slightest idea what you have installed and how it works.

But I know that the VirtualHosts don't work, not one of them here. I don't know why not, you have to figure that out for yourself.

All in all, however, I think that your project and your wishes exceed your knowledge far too much. I don't know why you want to realize something so demanding, but I know that you won't be able to do it. That is too much for your knowledge, which is unfortunately very very small. Why do you have to do it like this, I suggested you do two installations in two VirtualBox and I'm still convinced it's a good solution. Why isn't that enough for you? What is your problem?

The fact is that I can't help you anymore, I've given so many hints and you keep ignoring things, it's just too exhausting for me. I have such an environment, but I am also a highly qualified professional and I know what I have to do. But it's too exhausting to explain it to you, you do so much wrong that it's just annoying.

Why do you have to do something that a professional administrator normally has to do?

Ok, I understand.My config is one server only. I can not run 2 or virtual machines. the 2nd requirement is that I need to have 2 version of PHP running at the same time ( so 5.6 and 7.2 )The machine is a ubuntu 18.04.Initial config was a apache , running php 5.6 for a Freepbx application ( which is working no issues )Now , we need to add a Joomla. The joomla requires PHP 7.2 version. This is the explanation of the "why" I have 2 root directories the one existings : /var/www/html where the freepbx files are I created a new one to put joomla files : /var/www/html2My initial post was regarding the php.ini which was not taken into account with FCM configuration ( I followed a tutorial ) and it was working. I was not just able to define the post_max_size of the files Then you explained it was not ok and suggested your CGI config .This is all the whyon top of this, you have my bad enbglish in explanation and understand

Why do YOU(!) need that? This forum is for private people only, that cannot afford professional help. It is NOT meant for companies to give free support. So still, why do YOU need this configuration? At home?? Why cant you simply install two VirtualBoxes on your PC?

I think I found the problemThere was a script from freepbx monitoring the apache server. each time I was stopping it and restart, the script was stoping and replacing with a config specific to freepbx.Now, when I stop apache, it is stopped.I confirm what you were saying : Vhosts are not working.When I enter in browser : joomla.mydomain.comI have the following error : -------

You can run it on port 80, 81, 58 ... no issues, and create multiple Vhost on multiple ports with any version of php ( in my case 5.6 or 7.2 )You can change the php.ini for each php version and they are taken into account... no issues...