Ich habe Daten von 1 Website kriechen und ich erhalte die folgende Zeichenfolge:Wie verarbeitet man Daten-Javascript mit PHP?
var image_data11723 = [ { "type_code": "", "image_data": [ "graphics\/00000001\/COA389-l\u005F3\u005F350x280.jpg", "graphics\/00000001\/COA389-l\u005F3\u005F65x52.jpg", "graphics\/00000001\/COA389-l\u005F3.jpg" ] } ,{ "type_code": "", "image_data": [ "graphics\/00000001\/COA389-Dinette 1\u005F350x280.jpg", "graphics\/00000001\/COA389-Dinette 1\u005F65x52.jpg", "graphics\/00000001\/COA389-Dinette 1.jpg" ] } ,{ "type_code": "", "image_data": [ "graphics\/00000001\/COA389-Poker Table 1\u005F350x280.jpg", "graphics\/00000001\/COA389-Poker Table 1\u005F65x52.jpg", "graphics\/00000001\/COA389-Poker Table 1.jpg" ] } ,{ "type_code": "", "image_data": [ "graphics\/00000001\/COA389-Pool Table 1\u005F350x280.jpg", "graphics\/00000001\/COA389-Pool Table 1\u005F65x52.jpg", "graphics\/00000001\/COA389-Pool Table 1.jpg" ] } ,{ "type_code": "", "image_data": [ "graphics\/00000001\/COA389-Table CLoseup\u005F350x280.jpg", "graphics\/00000001\/COA389-Table CLoseup\u005F65x52.jpg", "graphics\/00000001\/COA389-Table CLoseup.jpg" ] } ,{ "type_code": "", "image_data": [ "graphics\/00000001\/COA389-Chair 1\u005F350x280.jpg", "graphics\/00000001\/COA389-Chair 1\u005F65x52.jpg", "graphics\/00000001\/COA389-Chair 1.jpg" ] } ] var im11723 = new ImageMachine('COA389', 0, 'main\u005Fimage', 'thumbnails', 'closeup\u005Fdiv', 'closeup\u005Fimage', 'closeup\u005Fclose', '', 'B', 350, 360, 1, 'N', 900, 675, 1, 65, 65, 1, 'graphics\/00000001\/COA389.1-i.jpg'); im11723.oninitialize(image_data11723);
Ich mag einen Array aus dem image_data
Variable bekommen, aber ich weiß nicht, wie dies zu erreichen.
Response ist im JSON-Format Sie json_decode verwenden können Array zu erhalten, was Sie wollen. – Dharmendra
Sie haben Daten vom Crawler mit Js? –
Willkommen bei Stack Overflow! Stack Overflow ist kein kostenloser Code-Schreibdienst, bitte zeigen Sie Ihren Code/Aufwand und was das eigentliche Problem ist. – FrankerZ