我想在PHP中操作JavaScript数组。可以做这样的事情吗?
$.ajax({
type: "POST",
url: "tourFinderFunctions.php",
data: "activitiesArray="+activities,
success: function() {
$("#lengthQuestion").fadeOut('slow');
}
});
活动是一维数组,例如:
var activities = ['Location Zero', 'Location One', 'Location Two'];
尝试执行此脚本时无法完成...如何解决?