0
我正在编写一个API,我需要从webhook(Shopify)获取一些数据。从webservice获取任何内容
昨天它正在工作,但它突然停止,即使我的.htaccess
文件看起来与我正在处理的另一个副本相同。
下面是从.htaccess
某些片断:
## default index file
DirectoryIndex index.php
## rewrite everything else to API.php
RewriteCond %{REQUEST_URI} /([^/]+)(?:/API-NEW)
RewriteRule ([a-zA-Z0-9_-]*)\.(service|test)$ index.php?action=$1&debug=$2&shop=%1&%{QUERY_STRING} [nc,qsa,L]
这里是我的index.php
:
为网络挂接是针对
<?php
require_once 'configs.php';
require_once 'helpers/helpers.php';
require_once 'helpers/io_helpers.php';
$date = date(DATE_RFC2822);
file_put_contents('debug/debug_info.txt', 'Request started', FILE_APPEND);
if (in_array($_GET['action'],array('insertOrder','updateOrder'))){
writeToDebug($date . " --> New: " . $_GET['action']);
getRequest();
}
它不写什么debug/debug_info.txt
所以我有点失去我的心。
请帮忙吗?
你检查文件夹/文件的权限?看看错误报告是否有任何东西出来http://php.net/manual/en/function.error-reporting.php并检查你的日志。另外,你如何执行'getRequest()'和'writeToDebug()'函数? –
*“Webhook的地址为:http:// Mywebsite”* - 您的意思是'http:// Mywebsite' *正确?* –
它没有达到那个部分..我检查它是否工作,如果它打印调试文件的东西,但它不是 – Onilol