🛠️Configuration

Here are the integrations that you can configure on the product after installation.

1. Ad code setup (AdSense)

In order to serve AdSense ad code you need to verify the domain first before the ads gets served on your website.

This tutorial is for AdSense only but any other Ad Network can be used as well.

1. Verify Domain

Add new site on your AdSense account and copy the verification code and paste it in your head.blade.php file found in the \themes\Minimal\resources\views\components\ folder, it'll load the script in the <head> section of the website.

Example Code
<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-xxxxxxxxxxxxxxxx"
     crossorigin="anonymous"></script>

2. Create Ad Units

Create 4 different ad units with the following configurations and paste the ad code in below mentioned files.

Ad Configuration;

  • Ad Size: Responsive

  • Horizontal Ads

Copy the ad unit codes and paste them in the following files located in the \themes\Minimal\resources\views\components\ad\ folder.

  • hero-section-ad.blade.php

  • about-section-ad.blade.php

  • usage-section-ad.blade.php

  • faq-section-ad.blade.php

Ad Unit Example
<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-xxxxxxxxxxxxxxxx"
     crossorigin="anonymous"></script>
<!-- xh-res-test -->
<ins class="adsbygoogle"
     style="display:block"
     data-ad-client="ca-pub-xxxxxxxxxxxxxxxx"
     data-ad-slot="xxxxxxxxxx"
     data-ad-format="auto"
     data-full-width-responsive="true"></ins>
<script>
     (adsbygoogle = window.adsbygoogle || []).push({});
</script>

2. Cron job setup

The cron job must be set up as it is responsible for handling background tasks.

Create a new cron job with the following command to run once in an hour.

0 * * * * /usr/local/bin/php /public_html/artisan schedule:run >> /dev/null 2>&1

Make sure to replace the /usr/local/bin/php with your own PHP path & /public_html/ with your own script directory.

3. Add Google Analytics Code

In order to use Google Analytics you need to add gtag.js into the <head> section of your website, you can do so by adding the script code into the head.blade.php file located in the \themes\Minimal\resources\views\components\ folder.

Example Code
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-UA-XXXXXXXX-X"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());

  gtag('config', 'UA-XXXXXXXX-X');
</script>

4. BrightData Proxies Setup

You can easily add BrightData proxies in your script by following the below steps.

1. Create an account on BrightData.io

2. After successfully activating the account go to the "Zones" Section from the side menu and click on "Add Zone" button.

3. In "Add new Zone" page select the following options and create zone

  • Network types: Datacenter

  • Price plan: Pay as you go* - $0.6/GB

  • Permissions: 100% Uptime

  • IP Type: Shared (Pay per usage)

4. After creating Zone click on the Edit icon and you'll get the following screen, from there you can get your Zone Username & Password.

5. You've created your zone and got your zone username & password, now open your TikTok script admin panel and add your BrightData proxies.

6. Open script admin panel and navigate to Configure Proxies section.

7. Click on Add Proxy, a new page will get open.

8. Add the newly generated proxy and press Add Proxy button.

  • Protocol: HTTP/HTTPS

  • Hostname: zproxy.lum-superproxy.io

  • Port: 22225

  • Has Authentication: True

  • Username: {your-zone-username}

  • Password: {your-zone-password}

9. Voila! You've successfully added your proxy.

5. Add New Language/Translation

In new script update, multi-language support is added. You can now create multiple languages for every theme.

Every theme can have it's own translations, in order to add or remove a language follow the below steps.

We'll Add Russian language in this tutorial

1. Create JSON File

Open \themes\Minimal\lang\ folder and duplicate the en.json file and rename it with the desired language code (i.e "en" for English, "ru" for Russian). We'll rename it to ru.json.

Open & edit the newly duplicated ru.json file and translate the english text into the Russian language using any text editor.

Original
   "Popular videos": "Popular videos",
    "How to save TikTok video?": "How to save TikTok video?",
    "Download TikTok Video": "Download TikTok Video",
    "Just insert a link": "Just insert a link",
    "Paste": "Paste",
    "Download": "Download",
Translated
   "Popular videos": "популярные видео",
    "How to save TikTok video?": "Как сохранить видео из TikTok?",
    "Download TikTok Video": "Скачать видео с ТикТок",
    "Just insert a link": "Просто вставьте ссылку",
    "Paste": "Вставить",
    "Download": "Скачать",

2. Enable Language

Open your respective theme folder \themes\Minimal\ and open theme.json file.

Add new line in the locales section, and define your language and it's name.

Before
{
    "name": "Minimal Theme",
    "description": "Minimal theme for TT Downloader",
    "author": "CodeSpikeX",
    "preview": "screenshot.png",
    "version": "1.0",
    "id": "Minimal",
    "locales": {
        "en": "English",
        "ar": "Arabic",
        "id": "Bahasa Indonesia",
        "de": "Deutsch",
        "es": "Español",
        "tr": "Türkçe",
        "fr": "Français"
    },
    "rtl_support": [
        "ar"
    ]
}
After
{
    "name": "Minimal Theme",
    "description": "Minimal theme for TT Downloader",
    "author": "CodeSpikeX",
    "preview": "screenshot.png",
    "version": "1.0",
    "id": "Minimal",
    "locales": {
        "en": "English",
        "ar": "Arabic",
        "id": "Bahasa Indonesia",
        "de": "Deutsch",
        "es": "Español",
        "tr": "Türkçe",
        "fr": "Français", //DON'T FORGET THIS COMMA
        "ru": "Russian"  // NO COMMA AT THE END
    },
    "rtl_support": [
        "ar"
    ]
}

3. RTL Support

If the language is RTL you need to specify it as well in the theme.json file located in the \themes\Minimal\ folder.

Example
"rtl_support": [
        "ar", //DON'T FORGET THIS COMMA
        "ru" // NO COMMA AT THE END
    ]

Last updated