# Illegal Chars Removal

**URL:** <https://community.mp3tag.de/t/illegal-chars-removal/60627>\
**Category:** Support\
**Created:** [April 5, 2023, 9:10am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627 "2023-04-05T09:10:00Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Smudger](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/s/85f322/32.png) [@Smudger](https://community.mp3tag.de/u/Smudger)\
**Post date:** [April 5, 2023, 9:10am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627/1 "2023-04-05T09:10:00Z")

</div>

Hiya Everyone

Can someone please tell me how to use

$validate()

In the title field

Regards

Steve

---

<div class="post-metadata">

**Author:** ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)\
**Post date:** [April 5, 2023, 10:30am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627/2 "2023-04-05T10:30:50Z")

</div>

from the documentation:

> **[Scripting Functions – Mp3tag Documentation](https://docs.mp3tag.de/scripting/#string-functions)**
>
> Documentation on Mp3tag's scripting functions. Mp3tag is the universal Tag Editor.

`$validate(x,y)` returns the given file name/path x with all invalid characters `/?*"<>|:` replaced by the string y.

The main application is to use it with filenames and paths.  
I do not think that there are actually any illegal characters

> [@Smudger](#):
>
> In the title field

To use $validate() with the data in TITLE: $validate(%title%)  
You can apply that function in every action that requires a format string.

---

<div class="post-metadata">

**Author:** ![Smudger](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/s/85f322/32.png) [@Smudger](https://community.mp3tag.de/u/Smudger)\
**Post date:** [April 5, 2023, 11:22am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627/3 "2023-04-05T11:22:02Z")

</div>

thank you for that can I use $validate(%title%) on it's own in tag-tag

dont understand in a format string

thank you

---

<div class="post-metadata">

**Author:** ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)\
**Post date:** [April 5, 2023, 11:29am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627/4 "2023-04-05T11:29:02Z")

</div>

If you have a look at the Tag-Tag-function, then you will see that you are requested to enter a "format string".

---

<div class="post-metadata">

**Author:** ![Smudger](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/s/85f322/32.png) [@Smudger](https://community.mp3tag.de/u/Smudger)\
**Post date:** [April 5, 2023, 11:33am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627/5 "2023-04-05T11:33:32Z")

</div>

yes, and do I just add $validate(%title%)

sorry for being naïve

---

<div class="post-metadata">

**Author:** ![Smudger](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/s/85f322/32.png) [@Smudger](https://community.mp3tag.de/u/Smudger)\
**Post date:** [April 5, 2023, 11:34am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627/6 "2023-04-05T11:34:14Z")

</div>

as when I enter $validate(%title%) in the format string it strips out all of the title

---

<div class="post-metadata">

**Author:** ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)\
**Post date:** [April 5, 2023, 11:41am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627/7 "2023-04-05T11:41:17Z")

</div>

Please try:  
`$validate(%title%,)`

---

<div class="post-metadata">

**Author:** ![Smudger](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/s/85f322/32.png) [@Smudger](https://community.mp3tag.de/u/Smudger)\
**Post date:** [April 5, 2023, 11:58am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627/8 "2023-04-05T11:58:22Z")

</div>

Perfect thank you so much for all your help

---

<div class="post-metadata">

**Author:** ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)\
**Post date:** [May 5, 2023, 11:58am UTC](https://community.mp3tag.de/t/illegal-chars-removal/60627/9 "2023-05-05T11:58:54Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
