社区 PHP 上的 Zend PHP 代码是否必须更改为 运行?

Does Zend PHP code have to be changed to run on community PHP?

使用许可 zend php server basic is ending June 30, 2021.

IBM i community PHP 上的以下代码 运行 会吗?

function as400Connect($libl)
{
  $options = array('i5_naming' => DB2_I5_NAMING_ON);
  if (strlen($libl) > 0)
  {
    $options['i5_libl'] = $libl ;
  }
  $conn = db2_connect("*LOCAL", "", "", $options);
  if (!$conn) {
    echo "Connection failed";
    echo "<br>";
    echo db2_conn_errormsg();
    exit();
  }
  return $conn;
}

该代码使用了 db2_ 函数。它依赖 i5_libl 选项在服务器作业上设置库列表。当我的 PHP Web 应用程序调用 IBM i 上的 SQL 存储过程时,设置库列表至关重要。

你走运了!虽然我不确定你提供的 link 的分布,但我们的 CommunityPlus+ PHP 肯定支持 ibm_db2 和 i5_libl 选项。我们是 ibm_db2 组件的官方维护者。

有关更多信息,请参阅 this article in IT Jungle