我正在开发一个 Joomla 模块,它有几个参数来定义它的工作方式。我在模块区域中有按钮,并且按钮必须与这些参数交互。这是模块PHP代码:
<?php
defined('_JEXEC') or die('Direct Access to this location is not allowed.');
$AdVisualV2jMODPHP_ver='0.3.0070';
$Station_ID = $params->get('Station_ID');
$Verbose = $params->get('Verbose');
$Bk_ColorODD = $params->get('Bk_ColorODD');
$Bk_ColorEVEN = $params->get('Bk_ColorEVEN');
$Ink_ColorODD = $params->get('Ink_ColorODD');
$Ink_ColorEVEN = $params->get('Ink_ColorEVEN');
$PicCol_Title = $params->get('PicCol_Title');
$TxtCol_Title = $params->get('TxtCol_Title');
$EvPic_Heightpx = $params->get('EvPic_Heightpx');
$EvPic_Widhtpx = $params->get('EvPic_Widhtpx');
$CatPic_Heightpx = $params->get('CatPic_Heightpx');
$CatPic_Widhtpx = $params->get('CatPic_Widhtpx');
$Pic_Hspanpx = $params->get('Pic_Hspanpx');
$Pic_Vspanpx = $params->get('Pic_Vspanpx');
$TitleSw = $params->get('TitleSw');
$MenuPos = $params->get('MenuPos');
$Paging = $params->get('Paging');
$Sort_Field = $params->get('Sort_Field');
$Sort_Order = $params->get('Sort_Order');
$db_host = "localhost";
$db_user = "xxxx";
$db_database = "xxxxx";
$db_password = "xxxxx";
$db_tabconfig = "xxxxxxx";
$db_tabpreroll = "xxxxxxxxxxx";
echo 'AVVIAMO LA PROCEDURA 0.0.090 - '.$Station_ID.'<br><br>';
echo '<div id="TabellaEventi"></div>';
echo '<INPUT Type="BUTTON" VALUE="Avanti" ONCLICK="avanti()"> ';
echo '<INPUT Type="BUTTON" VALUE="Indietro" ONCLICK="indietro()"> ';
echo '<br>';
?>
当用户单击“Avanti”或“Indietro”按钮时,我调用 JAVASCRIPT 函数 avanti() 和 indietro(),这两个函数将使用上述所有参数。我该怎么做才能转移这么多的变量?
和!!!这两个 Javascript 函数必须调用其他 PHP 文件才能与 MySql 数据库进行交互,并且我将或多或少需要另一个文件中的所有变量。
互联网编程有时真是一团糟……