Usamos cookies para medir audiência e melhorar sua experiência. Você pode aceitar ou recusar a qualquer momento. Veja sobre o iMasters.
boa tarde quero capturar essas informações que ja esta no HTML que obti
var skuJson = {"productId":2012377,"name":"Calça Scotch & Soda Ralston Plus Listrada Verde","salesChannel":"1","available":true,"displayMode":"especificacao","dimensions":["Tamanho"],"dimensionsInputType":{"Tamanho":"Combo"},"dimensionsMap":{"Tamanho":["38","39","40","41","42","43","44","46"]},"skus":[{"sku":2046261,"skuname":"Calça Scotch & Soda Ralston Plus Listrada Verde","dimensions":{"Tamanho":"38"},"available":true,"listPriceFormated":"R$ 779,00","listPrice":77900,"bestPriceFormated":"R$ 233,70","bestPrice":23370,"installments":10,"installmentsValue":2337,"installmentsInsterestRate":0,"image":"http://www.glamour.com.br/arquivos/ids/641386-398-398/8717851402656_1.jpg?v=635204516987770000","sellerId":"1","seller":"glamour","measures":{"cubicweight":0.2880,"height":12.0000,"length":12.0000,"weight":200.0000,"width":12.0000},"rewardValue":0},{"sku":2046262,"skuname":"Calça Scotch & Soda Ralston Plus Listrada Verde","dimensions":{"Tamanho":"39"},"available":true,"listPriceFormated":"R$ 779,00","listPrice":77900,"bestPriceFormated":"R$ 233,70","bestPrice":23370,"installments":10,"installmentsValue":2337,"installmentsInsterestRate":0,"image":"http://www.glamour.com.br/arquivos/ids/641386-398-398/8717851402656_1.jpg?v=635204516987770000","sellerId":"1","seller":"glamour","measures":{"cubicweight":0.2880,"height":12.0000,"length":12.0000,"weight":200.0000,"width":12.0000},"rewardValue":0},{"sku":2046263,"skuname":"Calça Scotch & Soda Ralston Plus Listrada Verde","dimensions":{"Tamanho":"40"},"available":true,"listPriceFormated":"R$ 779,00","listPrice":77900,"bestPriceFormated":"R$ 233,70","bestPrice":23370,"installments":10,"installmentsValue":2337,"installmentsInsterestRate":0,"image":"http://www.glamour.com.br/arquivos/ids/641386-398-398/8717851402656_1.jpg?v=635204516987770000","sellerId":"1","seller":"glamour","measures":{"cubicweight":0.2880,"height":12.0000,"length":12.0000,"weight":200.0000,"width":12.0000},"rewardValue":0},{"sku":2046264,"skuname":"Calça Scotch & Soda Ralston Plus Listrada Verde","dimensions":{"Tamanho":"41"},"available":false,"listPriceFormated":"R$ 0,00","listPrice":0,"bestPriceFormated":"R$ 999.987,00","bestPrice":99998700,"installments":10,"installmentsValue":9999870,"installmentsInsterestRate":0,"image":"http://www.glamour.com.br/arquivos/ids/641386-398-398/8717851402656_1.jpg?v=635204516987770000","sellerId":"1","seller":"glamour","measures":{"cubicweight":0.2880,"height":12.0000,"length":12.0000,"weight":200.0000,"width":12.0000},"rewardValue":0},{"sku":2046265,"skuname":"Calça Scotch & Soda Ralston Plus Listrada Verde","dimensions":{"Tamanho":"42"},"available":true,"listPriceFormated":"R$ 779,00","listPrice":77900,"bestPriceFormated":"R$ 233,70","bestPrice":23370,"installments":10,"installmentsValue":2337,"installmentsInsterestRate":0,"image":"http://www.glamour.com.br/arquivos/ids/641386-398-398/8717851402656_1.jpg?v=635204516987770000","sellerId":"1","seller":"glamour","measures":{"cubicweight":0.2880,"height":12.0000,"length":12.0000,"weight":200.0000,"width":12.0000},"rewardValue":0},{"sku":2046266,"skuname":"Calça Scotch & Soda Ralston Plus Listrada Verde","dimensions":{"Tamanho":"43"},"available":true,"listPriceFormated":"R$ 779,00","listPrice":77900,"bestPriceFormated":"R$ 233,70","bestPrice":23370,"installments":10,"installmentsValue":2337,"installmentsInsterestRate":0,"image":"http://www.glamour.com.br/arquivos/ids/641386-398-398/8717851402656_1.jpg?v=635204516987770000","sellerId":"1","seller":"glamour","measures":{"cubicweight":0.2880,"height":12.0000,"length":12.0000,"weight":200.0000,"width":12.0000},"rewardValue":0},{"sku":2046267,"skuname":"Calça Scotch & Soda Ralston Plus Listrada Verde","dimensions":{"Tamanho":"44"},"available":true,"listPriceFormated":"R$ 779,00","listPrice":77900,"bestPriceFormated":"R$ 233,70","bestPrice":23370,"installments":10,"installmentsValue":2337,"installmentsInsterestRate":0,"image":"http://www.glamour.com.br/arquivos/ids/641386-398-398/8717851402656_1.jpg?v=635204516987770000","sellerId":"1","seller":"glamour","measures":{"cubicweight":0.2880,"height":12.0000,"length":12.0000,"weight":200.0000,"width":12.0000},"rewardValue":0},{"sku":2046268,"skuname":"Calça Scotch & Soda Ralston Plus Listrada Verde","dimensions":{"Tamanho":"46"},"available":true,"listPriceFormated":"R$ 779,00","listPrice":77900,"bestPriceFormated":"R$ 233,70","bestPrice":23370,"installments":10,"installmentsValue":2337,"installmentsInsterestRate":0,"image":"http://www.glamour.com.br/arquivos/ids/641386-398-398/8717851402656_1.jpg?v=635204516987770000","sellerId":"1","seller":"glamour","measures":{"cubicweight":0.2880,"height":12.0000,"length":12.0000,"weight":200.0000,"width":12.0000},"rewardValue":0}]};CATALOG_SDK.setProductWithVariationsCache(skuJson.productId, skuJson);
estou tentando desta forma
preg_match('/var\sskuJson\s\=\s\[(.*?)\]\;/', $result, $json);
mais o array sempre resulta vazio
como posso capturar esse json?
Obrigado
Brambilla
Carregando comentários...