Raised This Month: $51 Target: $400
 12% 

JSON/Socket help


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
JusTGo
Veteran Member
Join Date: Mar 2013
Old 09-11-2016 , 18:51   JSON/Socket help
Reply With Quote #1

what is the best way i can get data from json
an example will be very helpful.
__________________

Last edited by JusTGo; 10-03-2017 at 18:38. Reason: useless
JusTGo is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 09-11-2016 , 21:05   Re: JSON/Socket help
Reply With Quote #2

Did you look at the JSON include?
__________________
fysiks is offline
JusTGo
Veteran Member
Join Date: Mar 2013
Old 09-11-2016 , 22:44   Re: JSON/Socket help
Reply With Quote #3

i can't get it to work correctly.
__________________

Last edited by JusTGo; 10-03-2017 at 18:38. Reason: useless
JusTGo is offline
Black Rose
Veteran Member
Join Date: Feb 2011
Location: Stockholm, Sweden
Old 09-12-2016 , 12:50   Re: JSON/Socket help
Reply With Quote #4

json_decode() seems seriously broken.

I couldn't even decode this:
Code:
{
	"var": "val"
}
But I'm no expert in JSON so I might be misunderstanding.
__________________

Last edited by Black Rose; 09-12-2016 at 15:31.
Black Rose is offline
JusTGo
Veteran Member
Join Date: Mar 2013
Old 09-12-2016 , 13:30   Re: JSON/Socket help
Reply With Quote #5

Quote:
Originally Posted by Black Rose View Post
json_decode() seems seriously broken.

I couldn't even decode this:
[text]
{
"var": "val"
}
[/text]

But I'm no expert in JSON so I might be misunderstanding.
yes encoding works but decoding doesn't

https://forums.alliedmods.net/showthread.php?t=195557
https://forums.alliedmods.net/showthread.php?t=239170
https://forums.alliedmods.net/showthread.php?t=264433

any idea how to download this module https://forums.alliedmods.net/showthread.php?t=264433 or its not ready yet ?
__________________
JusTGo is offline
klippy
AlliedModders Donor
Join Date: May 2013
Location: Serbia
Old 09-12-2016 , 13:38   Re: JSON/Socket help
Reply With Quote #6

This should work I guess: https://forums.alliedmods.net/showthread.php?t=244605
Also, there is a PR on Github currently, we may be getting JSON support in 1.8.3 soon.
klippy is offline
Old 09-12-2016, 18:10
JusTGo
This message has been deleted by JusTGo. Reason: fixed
Old 09-13-2016, 10:48
JusTGo
This message has been deleted by JusTGo. Reason: useless
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 06:56.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode