1. <?php
2. $_page = null;
3. include(MODS_DIRECTORY."/client.php");
4. $auth_url = "http://localhost/server.php";
5. $data = file_get_contents();
6. $result = json_decode($result);
7. if($result['valid'] != true){
8. die("Invalid Key. Script Stopped!")
9. }
10. ?>
I'm bit new to PHP. Could anyone please tell me what's wrong in the above code snippet?
I'm getting Syntax Parse error: Unexpected '}' at line no.9
Thanks!
globetrotter_me 0 Newbie Poster
Recommended Answers
Jump to PostAs mentioned you need a ';'. This looks dicky:
$data = file_get_contents(); $result = json_decode($result);
Don't understand where the $result comes from and $data points at nothing.
All 3 Replies
Reply to this topic Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.