# SRC and INC Files

**URL:** <https://community.mp3tag.de/t/src-and-inc-files/56470>\
**Category:** Web Sources Discussion\
**Created:** [February 24, 2022, 11:44am UTC](https://community.mp3tag.de/t/src-and-inc-files/56470 "2022-02-24T11:44:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![poster](https://community.mp3tag.de/user_avatar/community.mp3tag.de/poster/32/4881_2.png) [@poster](https://community.mp3tag.de/u/poster)\
**Post date:** [February 24, 2022, 11:44am UTC](https://community.mp3tag.de/t/src-and-inc-files/56470/1 "2022-02-24T11:44:47Z")

</div>

My knowledge regarding the development of web source scripts is extremely rudimentary and just enough to understand a few lines of existing scripts and to change them to my liking.

The use of INC files, which has been possible for some time, is very practical in order to use general code for different calls through SRC files.

However, at the moment I have the problem that I have to make my own changes to SRC files, including the Apple Websource Scripts, which consist of umpteen SRC files to take individual countries into account.  
I would like to extend "SearchBy" with a replace function for %albumartist%: `$replace(%ALBUMARTIST%,'Various Artists',)`, which indeed works in the SRC file.  
Based on the Apple script, it looks like this in my SRC file:

> [SearchBy]=Search for||[$if2(%ITUNESALBUMID%,[$if2([$if2(**$replace(%ALBUMARTIST%,'Various Artists',)**,%ARTIST%)][%ALBUM%],[%\_directory%] [%\_parent\_directory%])])]||&term=%s

Unfortunately, this means that I have to make this change in umpteen SRC files and again with every updated version.  
So my question:  
Is it possible to move this $replace function to the INC file so that I only have to make the change once for every web source?

---

<div class="post-metadata">

**Author:** ![LyricsLover](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/c6cbf5/32.png) [@LyricsLover](https://community.mp3tag.de/u/LyricsLover)\
**Post date:** [February 24, 2022, 1:44pm UTC](https://community.mp3tag.de/t/src-and-inc-files/56470/2 "2022-02-24T13:44:21Z")

</div>

I just made a small test and it seems that you can place your  
`[SearchBy]=`  
in the INC file too (not additional, just "instead of")

So the source file would only include one line:  
`[Include]=Name of your include file.inc`

What if you try it with one of your examples?

---

<div class="post-metadata">

**Author:** ![poster](https://community.mp3tag.de/user_avatar/community.mp3tag.de/poster/32/4881_2.png) [@poster](https://community.mp3tag.de/u/poster)\
**Post date:** [February 24, 2022, 2:32pm UTC](https://community.mp3tag.de/t/src-and-inc-files/56470/3 "2022-02-24T14:32:43Z")

</div>

Thanks. It works and I didn't think it would be that easy.
