Codex tools: Log in
Sanitizes title, replacing whitespace with dashes.
Limits the output to alphanumeric characters, underscore (_) and dash (-). Whitespace becomes a dash.
Note that it does not replace special accented characters (see plugins such as  to fix that).
<?php sanitize_title_with_dashes( $title, $unused, $context = 'display' ) ?>
<?php echo sanitize_title_with_dashes("I'm in LOVE with WordPress!!!1"); // this will print: im-in-love-with-wordpress1 ?>
Does not apply the sanitize_title filter to the title.
sanitize_title_with_dashes() is located in
sanitize_sql_orderby() is in a class of functions that help you sanitize potentially unsafe data which allow you to pass an arbitrary variable and receive the clean version based on data type. Others include: