skip to Main Content

Php Curl with shopify trouble in output

So basically I just grab a code from here and test run it. This is the code: <?php $url = "https://230******************dc20:b0817***************008@tr*********s.myshopify.com/admin/customers.json"; $shopcurl = curl_init(); curl_setopt($shopcurl, CURLOPT_URL, $url); curl_setopt($shopcurl, CURLOPT_HTTPHEADER, array('Content-Type: application/json')); curl_setopt($shopcurl, CURLOPT_RETURNTRANSFER, true); curl_setopt($shopcurl, CURLOPT_VERBOSE, 0); curl_setopt($shopcurl, CURLOPT_HEADER, 1);…

VIEW QUESTION

Change product description based on variant in Shopify

I want to be able to change product description based on variant name. I am following the tutorial here ==> https://ecommerce.shopify.com/c/ecommerce-design/t/demo-change-description-in-product-with-different-variants-296509 I modified the code a bit in order to use variant.option1 instead of variant.id Seems like I have no…

VIEW QUESTION

Block discount on certain product shopify script

I want to write a script in Shopify that prevents discounts from rendering on certain products. I know this is wrong, but something like this: Input.cart.line_items.each do |line_item| product = line_item.variant.product if product = 123456789 CartDiscount.remove("Discount does not apply") end…

VIEW QUESTION
Back To Top
Search