PHP - https - This endpoint should be made available over a secure connection.


Материал из Wiki - Iphoster - 'the best ever support'

Перейти к: навигация, поиск

PHP - https - This endpoint should be made available over a secure connection.

На странице регистрации (reg.php), авторизации(auto.php) и напоминании пароля(remind.php) в связи с переходом на https:// видим ошибку:

Mixed Content: The page at 'https://domain.com/?p=auto' was loaded over a secure connection, but contains a form which targets an insecure endpoint 'http://domain.com/modules/autoreg/ajax.php'. This endpoint should be made available over a secure connection.


Проверяем код скрипта и видим в файлах:

modules/autoreg/reg.php:<form action="<?php echo host(); ?>modules/autoreg/ajax.php" method=POST target="a_target">
modules/autoreg/auto.php:<form action="<?php echo host(); ?>modules/autoreg/ajax.php" method=POST target="a_target">
modules/autoreg/remind.php:<form action="<?php echo host(); ?>modules/autoreg/ajax.php" method=POST target="a_target">


заменяем на https:// :

# replace "<?php echo host(); ?>" "https://domain.com/" -- modules/autoreg/reg.php
# replace "<?php echo host(); ?>" "https://domain.com/" -- modules/autoreg/auto.php
# replace "<?php echo host(); ?>" "https://domain.com/" -- modules/autoreg/remind.php
Индекс цитирования