1
我想從鏈接源代碼的哈希和股票它在一個可變 的源代碼獲取哈希值是:從源代碼的preg_match
Profile.init({"user_id":37462,"loc":null,"back":"Leeter Leeter","last_names":[],"max_name_len":280,"hash_hash":"8cc8f7b2dcb4331676"});
我想哈希是:8cc8f7b2dcb4331676
我試着用這段代碼,但沒有奏效。
<?php
$data = file_get_contents("Link");
if (preg_match("/hash_hash":"([a-zA-Z0-9]+)"/i", $data, $matches))
print "The hash is: $matches[1]";
else
print "The page doesn't have a hash";
「鏈接」 是$數據=的file_get_contents(」鏈接「)只是一個字符串。 Profile.init來自哪裏? –