• Downloading from our site will require you to have a paid membership. Upgrade to a Premium Membership from 10$ a month today!

    Dont forget read our Rules! Also anyone caught Sharing this content will be banned. By using this site you are agreeing to our rules so read them. Saying I did not know is simply not an excuse! You have been warned.

Hỏi lấy dữ liệu mảng

hjephb

New Member
giả sử t có 1 mảng:
Code:
{"sm":{"id":"1102","name":"Bùi thị hiệp","message":"test"}}
làm ntn để lấy ra các giá trị:
id = 1102
name = bùi thị hiệp
message= test
t dùng ntn:
Code:
$stat= '{"sm":{"id":"1102","name":"Bùi thị hiệp","message":"test"}}';

foreach($stat as $key => $value) {
echo "id = ".$stat[$key][id];
echo "name = ".$stat[$key][name];
echo "message = ".$stat[$key][masage];
}
tự học nên ko biết làm ntn mong các b chỉ rõ chút à :D hihi
 
Last edited:

Facebook Comments

Similar threads

New posts New threads New resources

Back
Top