Skip to content

Instantly share code, notes, and snippets.

@saaeiddev
Created October 31, 2022 20:12
Show Gist options
  • Save saaeiddev/a9b764b08b459c80f72a4a1b5cba7b65 to your computer and use it in GitHub Desktop.
Save saaeiddev/a9b764b08b459c80f72a4a1b5cba7b65 to your computer and use it in GitHub Desktop.
<?php
$text = "Welcome to PHP !";
$a = urlencode($text);
$b = urldecode($a);
echo '<p>Original text: '.$text."</p>";
echo '<p>After urlencode: '.$a."</p>";
echo '<p>After urldecode: '.$b."</p>";
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment