[#SanitizeString]
= SanitizeString
:mrdocs:

Remove unsafe chars&period; Safe chars chosen to allow simple messages&sol;URLs&sol;email addresses, but avoid anything even possibly remotely dangerous like &amp; or &gt;

== Synopsis

Declared in `&lt;util&sol;strencodings&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
std::string
SanitizeString(
    std::string&lowbar;view str,
    int rule = SAFE&lowbar;CHARS&lowbar;DEFAULT);
----

== Return Value

A new string without unsafe chars

== Parameters

[cols="1,4"]
|===
| Name| Description
| *str* [in]
| The string to sanitize
| *rule* [in]
| The set of safe chars to choose (default&colon; least restrictive)
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
