I have a code in php that has the function to get the parameter ?capa=
with parse_str
<?php
$url = parse_url($_SERVER["HTTP_REFERER"]);
parse_str($url["query"],$queryString);?>
This is his code: <?php echo $queryString["capa"] ?>
but how to do the isset function of $_GET
in $queryString
That is, with $ _GET I would do this: $largura = isset($_GET ["largura"])?$_GET ["largura"]:"100%";
ie if it did not have a value in ?largura=
would receive 100%.
how to do this another way since the query string is interpreted with parse_str
?