<?php
$string_to_be_stripped = "Hi, I am a string and I need to be stripped...";
$new_string = ereg_replace("[^A-Za-z0-9]", "", $string_to_be_stripped );
function alphanumericAndSpace( $string )
{
return preg_replace('/[^a-zA-Z0-9\s]/', '', $string);
}
echo alphanumericAndSpace( $string_to_be_stripped);
?>
Secure file download in PHP, Security question PHP, PHP MYSQL Interview Question -Books download - PHP solutions guidelines queries update, phpmysqlquestion
Subscribe to:
Post Comments (Atom)
How to solve mysql ERROR 1118 (42000) Row size too large
I had this issue with MYSQL 5.7 . The following worked althoug...
-
PHP has an SSH2 library which provides access to resources (shell, remote exec, tunneling, file transfer) on a remote ma...
-
Which pillar of the AWS Well-Architected Framework recommends maintaining infrastructure as code? Operational Excellence Which of the foll...
-
Introduction to PHP PDO (PHP Data Objects) 1. What is PDO 2. What Databases does PDO support 3. Where do I begin? 4. Connect to ...
1 comment:
Nice article as for me. Thanks a lot for providing this information.
Joseph Franplou
wireless signal jammers
Post a Comment