COM sanitizeID

提供: GeeklogJpWiki

lib-common.php>COM sanitizeID

説明

string   COM_sanitizeID  (string $id, [boolean $new_id = true]) 

IDをサニタイズ。IDがアルファベット・数字・ドット・ダッシュ・アンダーバーのみで構成されているか確認する。

パラメータ

$id
the ID to sanitize
$new_id
true = create a new ID in case we end up with an empty string

返り値

the sanitized ID

使用例

個人用ツール