diff --git a/website/commonGames.html b/website/commonGames.html
deleted file mode 100644
index 3968a46..0000000
--- a/website/commonGames.html
+++ /dev/null
@@ -1,135 +0,0 @@
-
-
-
-
- Jrtechs Steam Friend Graph Project
-
-
-
-
-
-
-
-
-
-
-
-
TDLTR
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/website/friendsWithFriends.html b/website/friendsWithFriends.html
deleted file mode 100644
index e321aba..0000000
--- a/website/friendsWithFriends.html
+++ /dev/null
@@ -1,252 +0,0 @@
-
-
-
-
- Jrtechs Steam Friend Graph Project
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/website/friendsOfFriends.html b/website/graph.html
similarity index 89%
rename from website/friendsOfFriends.html
rename to website/graph.html
index b650300..80a78fd 100644
--- a/website/friendsOfFriends.html
+++ b/website/graph.html
@@ -66,17 +66,9 @@
- -
- Graphs
-
+
-
+ Graphs
-
-
Blog
@@ -134,15 +126,19 @@
}
});
+ getData = getUrlVars();
connection = new WebSocket('ws://jrtechs.student.rit.edu:4444');
connection.onopen = function ()
{
console.log('Connected!');
- if(r != undefined)
+
+ console.log(r);
+
+ if(getData["id"] != undefined && getData["id"] != "")
{
- connection.send("{id:'" + r.id + "', graph:" + r.graph + "}");
+ connection.send("{id:'" + getData["id"] + "', graph:" + getData["graph"] + "}");
}
else
{
@@ -157,6 +153,15 @@
console.log('WebSocket Error ' + error);
};
+ function getUrlVars()
+ {
+ var vars = {};
+ var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {
+ vars[key] = value;
+ });
+ return vars;
+ }
+
function addNodeToGraph(request)
{
if(s.graph.nodes(request.id) == undefined)
@@ -201,15 +206,6 @@
}
};
- var ids = prompt("Enter the steam id to graph:", "76561198188400721");
-
- if(ids != null)
- {
- r = new Object();
- r.graph = 1;
- r.id = ids;
- }
-
diff --git a/website/commonFriends.html b/website/graphs.html
similarity index 78%
rename from website/commonFriends.html
rename to website/graphs.html
index 3968a46..9fd83b3 100644
--- a/website/commonFriends.html
+++ b/website/graphs.html
@@ -16,17 +16,9 @@
- -
- Graphs
-
+
-
+ Graphs
-
-
Blog
@@ -43,9 +35,34 @@
diff --git a/website/index.html b/website/index.html
index 466eb97..190b051 100644
--- a/website/index.html
+++ b/website/index.html
@@ -16,17 +16,9 @@