[Solved] PHP get method ajax url reading [closed]


EDITED: You need to use javascript to achieve that.

<script language = "javascript">

var query = location.href.split('#');

var anchorValueSplit = query[1].split("https://stackoverflow.com/");

var anchorValue = anchorValueSplit[1];

alert(anchorValue);

</script>

EDIT:Another solution

<script language = "javascript">

if(location.href.indexOf("#") > 0) {

    location.href = location.href.replace("#","?");

}

</script>
<?php

$param = array_keys($_GET);
$param = $param[0];

$breakParam = explode("https://stackoverflow.com/",$param);

echo $request = $breakParam[1];


?>

6

solved PHP get method ajax url reading [closed]