I'm trying to fetch the last order from my Shopify store through the Shopify API on Wordpress with PHP.
我正試圖通過使用PHP的Wordpress上的Shopify API從Shopify商店獲取最后一個訂單。
The PHP documentation for Shopify API is pretty limited so I'm having some trouble actually getting the data, any data, to be echoed into my Wordpress page.
Shopify API的PHP文檔非常有限,因此我在實際獲取數據時遇到一些麻煩,任何數據都會回顯到我的Wordpress頁面。
I've made my Private App on Shopify and I'm using its credentials in the code below (replaced with brackets for security purposes). The app has read access to everything within the shop. There are recent orders, so that is not the problem.
我在Shopify上制作了我的私人應用程序,並且我在下面的代碼中使用了它的憑據(出於安全目的替換為括號)。該應用程序可以讀取商店內的所有內容。最近訂單,所以這不是問題。
Here is the code that I'm using to display within the body of my Wordpress page:
這是我用於在Wordpress頁面正文中顯示的代碼:
$orders_obj_url = 'https://[my api key]:[my api secre