note 98958 deleted from function.mb-substr by cmb

From: Date: Mon, 08 Jun 2015 11:38:25 +0000
Subject: note 98958 deleted from function.mb-substr by cmb
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-202764@lists.php.net to get a copy of this message
Note Submitter: levani9191 at gmail dot com ---- A simple code that check if the latest symbol in the string is a question mark and adds one if it doesn't... <?php $string = (mb_substr($string, -1, 1, 'UTF-8') != '?') ? $string.'?' : $string; ?>

« previous php.notes (#202764) next »