ModRewrite needs to be enabled in apache2 by executing:<br /> a2enmod rewrite Modify your HTaccess File like this if index.php is your main php File: RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ index.php?i=$1 [L,QSA] For example, if the user enters the UR...
Here code to check if a string exists in another string! $string = 'This is a String';<br /> if (strpos($string , 'This') !== false) {<br /> echo 'true'; # STRING CONTAINS WORD "This"<br /> } else {<br /> # String not f...
Example of replacing a sign in a string (works with more than one sign) $newstring = str_replace("TEXT", "NEW TEXT", $initialstring); ...