Permalink
Browse files

addes code to capture openURL and write to text file

  • Loading branch information...
1 parent b708112 commit 0858659f75f1cd0cba6d51c28caeb0b75aa12f8b @K-Felk K-Felk committed Mar 22, 2012
Showing with 30 additions and 0 deletions.
  1. +11 −0 360link-reset.2.0.js
  2. +19 −0 url_write.php
View
@@ -372,6 +372,17 @@ jQuery("#360link-reset ul li a").click(function() {
if(clicks > 1) {
jQuery(".doc-del-tooltip").show();
+ //lets also grap the openURL we are passing to the browser and pass it off
+ //to a PHP script that will write it elsewhere, so it can be checked
+ var URL = jQuery("div#ArticleCL a").attr('href');
+ jQuery.ajax({
+ type: "POST"
+ data: {URL : URL},
+ dataType: "text",
+ url: "url_write.php"
+
+ });
+
}
});
View
@@ -0,0 +1,19 @@
+<?
+ if () {
+ $url = trim($_POST['URL']) . "\n";
+ $DataFile = fopen("dodgy_urls.txt", "a");
+ fwrite($DataFile, $url);
+ fclose($DataFile);
+
+ } else {
+ die;
+
+
+ }
+
+
+
+
+
+
+?>

0 comments on commit 0858659

Please sign in to comment.