Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include 'scripts/fblog.php';
- // Create connection to database
- include 'scripts/sql.php';
- //SQL Table Persons - PID key, Firstname, Lastname,Gender
- $result = mysqli_query($con,"SELECT PID FROM Persons WHERE PID='" . $user_profile['id'] . "'");
- $Signedup = "";
- while($row = mysqli_fetch_array($result))
- {
- $signedup = $row['PID'];
- }
- if ($signedup == "")
- {
- echo "<script> window.location = 'http://calander.site90.net/monopoly/signup.php' </script>";
- }
- //close connection to db
- mysqli_close($con);
- ?>
- <head>
- <link rel="stylesheet" type="text/css" href="style.css">
- <script src="deed.js"></script>
- <script src="create.js"></script>
- <script src="play.js"></script>
- <script>
- var Vdeed = true;
- function loadOgame(){
- loading();
- }
- function loadMain(){
- if(Vdeed){
- loading();
- var xmlhttp;
- if (window.XMLHttpRequest){// code for IE7+, Firefox, Chrome, Opera, Safari
- xmlhttp=new XMLHttpRequest();
- }
- else{// code for IE6, IE5
- xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
- }
- xmlhttp.onreadystatechange=function(){
- if (xmlhttp.readyState==4 && xmlhttp.status==200){
- document.getElementById("the").innerHTML=xmlhttp.responseText;
- }
- }
- xmlhttp.open("GET","main.php?id=" + <?php echo $user_profile['id']; ?> ,true);
- xmlhttp.send();
- }}
- function AllowDeed(){
- Vdeed =true;
- }
- var Players = new Array();
- function loading(){
- document.getElementById("the").innerHTML="<h1>Loading stuff...</h1>";
- }
- </script>
- <script>
- var id0 = <?php echo $user_profile['id']; ?>;
- function isgo(gamid){
- //send request
- var xmlhttp;
- if (window.XMLHttpRequest){// code for IE7+, Firefox, Chrome, Opera, Safari
- xmlhttp=new XMLHttpRequest();
- }
- else{// code for IE6, IE5
- xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
- }
- xmlhttp.onreadystatechange=function(){
- if (xmlhttp.readyState==4 && xmlhttp.status==200){
- document.getElementById("the").innerHTML=xmlhttp.responseText;
- }
- }
- xmlhttp.open("GET","game.php?gid=" + gamid + "&id=" + id0,true);
- xmlhttp.send();
- }
- function isngo(gamid){
- //send request
- var xmlhttp;
- if (window.XMLHttpRequest){// code for IE7+, Firefox, Chrome, Opera, Safari
- xmlhttp=new XMLHttpRequest();
- }
- else{// code for IE6, IE5
- xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
- }
- xmlhttp.onreadystatechange=function(){
- if (xmlhttp.readyState==4 && xmlhttp.status==200){
- document.getElementById("the").innerHTML=xmlhttp.responseText;
- }
- }
- xmlhttp.open("GET","ogame.php?gid=" + gamid + "&id=" + id0,true);
- xmlhttp.send();
- }
- function play(gamid){
- loading();
- //check weather it is this users go or not
- var xmlhttp;
- if (window.XMLHttpRequest){// code for IE7+, Firefox, Chrome, Opera, Safari
- xmlhttp=new XMLHttpRequest();
- }
- else{// code for IE6, IE5
- xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
- }
- xmlhttp.onreadystatechange=function(){
- if (xmlhttp.readyState==4 && xmlhttp.status==200){
- var response=xmlhttp.responseText;
- if(response.substring(0,1) == "1"){
- //its the users go
- isgo(gamid);
- }
- else{
- //its not the users go
- alert(response.substring(0,1));
- isngo(gamid);
- }
- }
- }
- xmlhttp.open("GET","isgo.php?gid=" + gamid + "&id=" + id0,true);
- xmlhttp.send();
- }
- </script>
- </head>
- <body onload="loadMain();">
- <table border="1" class="a1" style="">
- <tr><td class="property" ><b>GO</b> </td><td class="property" ><table class="property"><tr><td id="a"></td></tr><tr><td onclick="loadDeed('Old Kent Road')" >Old kent road</td></tr></table></td><td class="property" id="chest">Chest</td><td class="property" ><table class="property"><tr><td id="a"></td></tr><tr><td onclick="loadDeed('Whitechapel Road')" >white...le</td></tr></table></td><td class="property" >Income tax</td></td><td class="property" >Kings cross station</td></td><td class="property" ><table class="property"><tr><td id="b"></td></tr><tr><td onclick="loadDeed('The Angel, Islington')" >The Angle islington</td></tr></table></td><td class="property" id="chance">?</td><td class="property" ><table class="property"><tr><td id="b"></td></tr><tr><td onclick="loadDeed('Eusten Road')" >Eusten road</td></tr></table></td><td class="property" ><table class="property"><tr><td id="b"></td></tr><tr><td onclick="loadDeed('Pentonville Road')" >Pentavil road</td></tr></table></td><td class="property" ><img width="50%" src="http://3.bp.blogspot.com/-IfpDgdvq7Y0/UTyRKWGJkTI/AAAAAAAAAbk/9U8SQQhRrQY/s1600/graphic_jail.jpg" /> </td></tr>
- <tr><td class="property" ><table class="property"><tr><td id="h"></td></tr><tr><td onclick="loadDeed('Mayfair')" >Mayfair</td></tr></table></td>
- <td id="the" colspan="9" rowspan="9">
- <h1>Loading please wait...</h1>
- <?php
- function isuser($Userid) {
- // Create connection to database
- include 'scripts/sql.php';
- //SQL Table Persons - PID key, Firstname, Lastname,Gender
- $result = mysqli_query($con,"SELECT PID FROM Persons WHERE PID='" . $Userid . "'");
- $Signedup = "";
- while($row = mysqli_fetch_array($result))
- {
- $signedup = $row['PID'];
- }
- if ($signedup != ""){
- return false;
- }
- else{
- return true;
- }
- mysqli_close($con);
- }
- ?>
- <div style="position:absolute;right:11%;top:11%;width:75px;text-align: justify;display: inline-block;">
- <p><img class="profileimage" name="" src="https://graph.facebook.com/<?php echo $user; ?>/picture" width="50" height="50" alt=""><br />
- <?php echo $user_profile['name']; ?><br />
- </p>
- </div>
- </td>
- <td class="property" ><table class="property"><tr><td id="c"></td></tr><tr><td onclick="loadDeed('Pall Mall')" >Pall mall</td></tr></table></td></tr>
- <tr><td class="property" >Super tax</td><td class="property" ><img width="50%" src="http://4.bp.blogspot.com/-3q1uxh1D9JA/UTEnxRIi5GI/AAAAAAAAAaU/RqQ6uUnnp44/s320/SKU1827.gif" /></td></tr>
- <tr><td class="property" ><table class="property"><tr><td id="h"></td></tr><tr><td onclick="loadDeed('Park Lane');">Park lane</td></tr></table></td><td class="property" ><table class="property" ><tr><td id="c"></td></tr><tr><td onclick="loadDeed('Whitehall');" >Whitehall</td></tr></table></td></tr>
- <tr><td class="property" id="chance">?</td><td class="property" ><table class="property"><tr><td id="c"></td></tr><tr><td onclick="loadDeed('Northumberland Avenue');" >North...land avernue</td></tr></table></tr>
- <tr><td class="property" >Liver... station</td><td class="property" >Mal...ne station</td></tr>
- <tr><td class="property" ><table class="property"><tr><td id="g"></td></tr><tr><td onclick="loadDeed('Bond Street');" >Bond street</td></tr></table></td><td class="property" ><table class="property"><tr><td id="d"></td></tr><tr><td onclick="loadDeed('Bow Street');" >Bow Street</td></tr></table></td></tr>
- <tr><td class="property" id="chest">Chest</td><td class="property" id="chest">Chest</td></tr>
- <tr><td class="property" ><table class="property"><tr><td id="g"></td></tr><tr><td onclick="loadDeed('Oxford Street');" >Oxford street</td></tr></table></td><td class="property" ><table class="property"><tr><td id="d"></td></tr><tr><td onclick="loadDeed('Marlborough Street');" >Malbura street</td></tr></table></td></tr>
- <tr><td class="property" ><table class="property"><tr><td id="g"></td></tr><tr><td onclick="loadDeed('Regent Street');" >Regent street</td></tr></table></td><td class="property" ><table class="property"><tr><td id="d"></td></tr><tr><td onclick="loadDeed('Vine Street');" >Vine street</td></tr></table></td></tr>
- <tr><td class="property" >go to jail</td><td class="property" ><table class="property"><tr><td id="f"></td></tr><tr><td onclick="loadDeed('Piccadilly');" >Piccadilly</td></tr></table></td><td class="property" ><img width="97%" src="http://1.bp.blogspot.com/--72tDF4Ew9A/UTEl1Bxir2I/AAAAAAAAAaM/BOcwShc0kXY/s320/nowater.jpg" /></td><td class="property" ><table class="property"><tr><td id="f"></td></tr><tr><td onclick="loadDeed('Coventry Street');" >Coventry street</td></tr></table></td><td class="property" ><table class="property"><tr><td id="f"></td></tr><tr><td onclick="loadDeed('Leicester Square');" >lester square</td></tr></table></td><td class="property" >Fen...ch station</td><td class="property" ><table class="property"><tr><td id="e"></td></tr><tr><td onclick="loadDeed('Trafalgar Square');" >trafalgar square</td></tr></table></td><td class="property" ><table class="property"><tr><td id="e"></td></tr><tr><td onclick="loadDeed('Fleet Street');" >Fleet street</td></tr></table></td><td class="property" id="chance">?</td><td class="property" ><table class="property"><tr><td id="e"></td></tr><tr><td onclick="loadDeed('Strand');" >strand</td></tr></table></td><td class="property" >free parking</td></tr>
- </table>
- </body>
Advertisement
Add Comment
Please, Sign In to add comment