I did a home-page in php (which can be seen only on https) that page relinks to 2 different internal webportal. One of the two internal webportal (MpcPanel) is on a http url.
example: home-page url: https://192.168.1.100
html code of the home-page that does not link to the correct wepportal (MpcPanel):
<div align="center" class="copyright" style="width: 400px; border: thin solid #F48C13; margin:0 auto;">
<p><a href="/cgi-bin/class/login.cgi"><strong>Accesso a MpcPanel</strong></a></p>
<p><a href="/cgi-bin/class/login.cgi"><img src="/classpba/include/images/logo.png" alt="" width="240" height="50" longdesc="/classpba/include/images/logo.png" /></a></p>
The full url I want to go is: http://192.168.1.100/cgi-bin/class/login.cgi
And the full url of the image is: http://192.168.1.100/classpba/include/images/logo.png
I dont want to put in the src= the full url becouse, I want the opportunity to change the IP of my server without having to be forced to manually change also the IP in the home-page.
You can't. Once you are in a server in HTTPS, any relative links ("/img/logo.png") will go trough the same protocol to the same server. If you want to change the protocol you have to supply the full URL there.
What you could do it's create a relay page, creating on the "https" server the page /img/logo.png, which is a program that connects to another server, picks the image and displays it.