" . $stuff . "";
}
return $stuff;
}
if (isset($_GET['justlook']) || isset($_GET['url']) || (!isset($_GET['justlooking']) && !isset($_GET['url']) && !isset($_POST['url']))) {
$classarray = array();
$sclass = array(" class=", " CLASS=", " Class=");
$selclass = "
";
$idarray = array();
$sid = array(" id=", " ID=", " Id=");
$selid = "
";
$tagarray = array();
$stag = array("<");
$seltag = "
";
$outtag = array("head", "script", "link", "meta", "html", "!doctype", "body", "style", "title");
$url = "";
$acont = "";
$cont = "";
if (isset($_GET['justlooking'])) {
if (!isset($_GET['url']) && !isset($_POST['url'])) {
$url = "";
$selclass = "";
$selid = "";
$seltag = "";
}
}
if (isset($_GET['url'])) {
$url = urldecode($_GET['url']);
if ($url != "") {
$acont = file_get_contents($url);
$cont = str_replace(" = ", "=", $acont);
} else {
$acont = file_get_contents("http://" . $_SERVER['SERVER_NAME'] . ":" . $_SERVER['SERVER_PORT'] . str_replace("?" . $_SERVER['QUERY_STRING'], "", $_SERVER['REQUEST_URI']) . "?justlooking=");
$cont = str_replace(" = ", "=", $acont);
}
} else if (isset($_POST['url'])) {
$url = urldecode($_POST['url']);
if ($url != "") {
$acont = file_get_contents($url);
$cont = str_replace(" = ", "=", $acont);
} else {
$acont = file_get_contents("http://" . $_SERVER['SERVER_NAME'] . ":" . $_SERVER['SERVER_PORT'] . str_replace("?" . $_SERVER['QUERY_STRING'], "", $_SERVER['REQUEST_URI']) . "?justlooking=");
$cont = str_replace(" = ", "=", $acont);
}
} else {
$url = "http://" . $_SERVER['SERVER_NAME'] . ":" . $_SERVER['SERVER_PORT'] . str_replace("?" . $_SERVER['QUERY_STRING'], "", $_SERVER['REQUEST_URI']);
$acont = file_get_contents($url . "?justlooking=");
$cont = str_replace(" = ", "=", $acont);
}
function classadd($thing) {
global $classarray, $selclass;
if (!in_array($thing, $classarray)) {
$selclass = str_replace(" style='display:none;'>", ">", $selclass);
$classarray[sizeof($classarray)] = $thing;
$selclass = str_replace("", "", $selclass);
}
}
function idadd($thing) {
global $idarray, $selid;
if (!in_array($thing, $idarray)) {
$selid = str_replace(" style='display:none;'>", ">", $selid);
$idarray[sizeof($idarray)] = $thing;
$selid = str_replace("", "", $selid);
}
}
function tagadd($thing) {
global $tagarray, $seltag, $outtag;
if (!in_array(strtolower($thing), $tagarray)) {
if (substr($thing, 0, 1) != "/" && substr($thing, 0, 1) != "!") {
if (!in_array(strtolower($thing), $outtag)) {
$seltag = str_replace(" style='display:none;'>", ">", $seltag);
$tagarray[sizeof($tagarray)] = strtolower($thing);
$seltag = str_replace("", "", $seltag);
}
}
}
}
if (isset($_GET['justlook']) || $cont != "") { //$url != "" && !isset($_GET['url']) && !isset($_POST['url'])) {
$xtag = explode($stag[0], str_replace(">", " ", str_replace("/>", " ", $cont)));
for ($i=1; $i
The putElement(s)By Webpage - RJM Programming - November, 2014
>
The putElement(s)By Webpage -
RJM Programming - November, 2014
ways
parts
Under line under here are putElement(s)By HTML elements