My Linux Guide
  • Home
Sign in Subscribe

php string remove white space

A collection of 1 post
PHP

PHP function to remove whitespaces from a string

Usage : $spaceRemovedString = removeWhiteSpaces($stringWithSpace);   Function : function removeWhiteSpaces($spaceStr) { $newStr = preg_replace('/\s+/', '', $spaceStr); return $newStr; }
Dec 28, 2012
Page 1 of 1
My Linux Guide © 2025
Powered by Ghost