我有1个文件,我在PHP已经实现。 错误,我得到的是
警告:require_once():HTTP://封装在由allow_url_include服务器配置禁用= 0 /Applications/MAMP/htdocs/opencart/catalog/view/theme/default/template/payment/bank_transfer.tpl线13Warning:
问题:
我知道,我需要通过使用甲基苯丙胺允许allow_url_include = 0,在php.ini.I'm,我已经搜查中甲基苯丙胺和甲基苯丙胺临的所有文件夹来解决这个问题,但我没有找到任何行,在那里我可以该值设置为0。 我加入这行?
我读过LINK 。我担心,有使用require_once,和的fopen绝对URL一些安全问题。 是否有使用绝对URL和require_once任何安全问题?
如何指定URL的文件? 目前,它的www.example.com/opencart/admin/kzm/kzm.utils.php,我试图用相对URL /opencart/admin/kzm/kzm.utils.php,但我没有找到该文件。 我这样做对吗?
bank_transfer.tpl:
<h2><?php echo $text_instruction; ?></h2>
<div class="content">
<p><?php echo $text_description; ?></p>
<p><?php echo $bank; ?></p>
<p><?php echo $text_payment; ?></p>
<p><?php echo $orderIdKZM; ?></p>
<p>
<?php
echo $amountKZM;
$titleKZM = $titleKZM.$orderIdKZM;
echo '<br>';
require_once('http://example.com/opencart/admin/kzm/kzm.utils.php');
echo $titleKZM;
echo '<br>';
$merchantIdKZM = '10';
$currencyKZM = 'KZT';
$successUrlKZM = 'http://localhost:8888/opencart/admin/kzm/kzm_pay.php';
$erroUrlKZM = 'http://www.google.com';
$dateKZM = " ";
$signstrKZM = " ";
$verKZM = " ";
echo $merchantIdKZM.'-'.$currencyKZM.'-'.$successUrlKZM.'-'.$erroUrlKZM.'-'.$dateKZM;
?></p>
</div>
<div class="buttons">
<div class="right">
<form action="/opencart/testkzm.php" method="get">
<input type="hidden" name="merchantIdKZM" value="<?php echo $merchantIdKZM; ?>">
<input type="hidden" name="orderIdKZM" value="<?php echo $orderIdKZM; ?>">
<input type="hidden" name="amountKZM" value="<?php echo $amountKZM; ?>">
<input type="hidden" name="currencyKZM" value="<?php echo $currencyKZM; ?>">
<input type="hidden" name="successUrlKZM" value="<?php echo $successUrlKZM; ?>">
<input type="hidden" name="errorUrlKZM" value="<?php echo $errorUrlKZM; ?>">
<input type="hidden" name="signstrKZM" value="<?php echo $signstrKZM; ?>">
<input type="hidden" name="verKZM" value="<?php echo $verKZM; ?>">
<input type="submit" value="<?php echo $button_confirm; ?>" id="button-confirm" class="button" />
</form>
</div>
</div>