我有一个 php 文件,其中包含一个数组。我希望能够使用简单的表单向该数组添加一个项目。
这是一个类似于我的数组的示例:
$list = array("BA0UKSF","BA9IHHE","BAC8GMB","BAC8HMC","BAC8HMC","BAC8HMC","BACI60T","BAEIDFD","BAEIEFE","BAEIEFE","BAMB0","BAOUKSE","BAOUKSF","BAPQADL","BAPQADM","BUNDLE","CN3ICDC","CN3ICDCA","CN7IZDPA","CN8ID42","CN8ID72","CNECBCBA");
我想在数组列表的开头或结尾的某个地方将新项目添加到数组中。
我知道如何将表单数据传递给 php,但我不知道如何让 php 打开这个文件,找到数组并添加一些东西。