Quantcast
Channel: Active questions tagged return-value - Stack Overflow
Viewing all articles
Browse latest Browse all 203

"Return of a Function() in PHP" skip syntex error in filter_var()

$
0
0
private function getURL(){    $url = isset($_GET['url']) && $_GET['url'] != "" ? $_GET['url'] : "home";    return explode("/", filter_var(trim($url,"/")),FILTER_SANITIZE_URL);}

The above code execute without any warning or error, but the second line of getURL() function should be like: return explode("/", filter_var(trim($url,"/"),FILTER_SANITIZE_URL));

Why I did not get any error or warning?

Please let me know, what is happening here?

Thanks in advance.


Viewing all articles
Browse latest Browse all 203

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>