<?php $str = "geeks"; // Or we can write ltrim($str, $str[0]); $str = ltrim($str, 'g'); echo $str; ?>