Header append Set-Cookie ;SameSite=None;Secure

<ifmodule mod_headers.c>
    Header always edit Set-Cookie ^(.*)$ $1;SameSite=None;Secure
</ifmodule>

<IfModule mod_rewrite.c>

    # set the default language
    AddDefaultCharset UTF-8
    DefaultLanguage fa-IR

    RewriteEngine On
    RewriteBase /

    RewriteCond %{HTTPS} off
    RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

    RewriteRule ^ads/(\w+)/(.*)$ single.php?id=$1&slug=$2 [QSA]
    RewriteRule ^ads/(\w+)$ single.php?id=$1 [QSA]

    RewriteRule ^blog?$ blog__list.php?page_type=blog [QSA]
    RewriteRule ^postcat/(\w+)/(.*)/ blog__list.php?categoryId=$1&page_type=blog [QSA]
    RewriteRule ^post/(\w+)/(.*)$ blog__list.php?id=$1&slug=$2&page_type=blog-single
    RewriteRule ^post/(\w+)$ blog__list.php?id=$1&page_type=blog-single
    RewriteRule ^tags/post/(\w+)/(.*)/$ blog__list.php?tag=$1&slug=$2&page_type=blog-tag [QSA]

    RewriteRule ^tags/ads/(\w+)/(.*)/$ ads__list.php?page_type=ads-list-tag&tag=$1&slug=$2 [QSA]
    RewriteRule ^category/(\w+)/(.*) ads__list.php?page_type=ads-list-category&cat=$1&slug=$2 [QSA]
    RewriteRule ^subcategory/(.*)/(.*) ads__list.php?page_type=ads-list-subcategory&cat=$1&subCat=$2 [QSA]
    RewriteRule ^subsidiary/(.*)/(.*)/(.*) ads__list.php?page_type=ads-list-subsidiary&cat=$1&parent=$2&subCat=$3 [QSA]

    RewriteRule ^print/(\w+)/ single.php?id=$1 [QSA]

    RewriteRule ^location/state/(\w+)/(.*) ads__list.php?page_type=ads-list-state&type=state&id=$1&slug=$2 [QSA]
    RewriteRule ^location/city/(\w+)/(.*) ads__list.php?page_type=ads-list-city&type=city&id=$1&slug=$2 [QSA]

    RewriteRule ^search list.php

    RewriteRule ^maintenance?$ maintenance.php
    RewriteRule ^new?$ submit.php

    RewriteRule ^all-categories?$ pages.php?page_type=all-categories
    RewriteRule ^payment/(.*)/callback pages.php?page_type=callback&method=$1 [QSA]
    RewriteRule ^page/(.*) pages.php?page_type=dynamic-page&page_slug=$1 [QSA]
    RewriteRule ^pricing?$ pages.php?page_type=pricing
    RewriteRule ^profile/([\w-]+) pages.php?page_type=profile-view&id=$1 [QSA]
    RewriteRule ^rss$ pages.php?page_type=rss-list&list_type=rss [QSA]
    RewriteRule ^rss/categories$ pages.php?page_type=rss-list&list_type=categories [QSA]
    RewriteRule ^rss/(.*)$ pages.php?page_type=rss-content&content=$1


    RewriteRule ^download/android process/download_android.php

    RewriteRule ^auth/activation-code$ process/auth/ajax_activation_code.php [QSA]
    RewriteRule ^auth/(.*)$ auths.php?slug=$1 [QSA]

    RewriteRule ^auth/forgot-pass$ auth__forgot_password.php
    RewriteRule ^auth/forgot-pass/verify$ auth__forgot_password_verify_code.php
    RewriteRule ^auth/reset-pass$ auth__reset_password.php [QSA]
    RewriteRule ^auth/activation$ auth__account_activation.php [QSA]
    RewriteRule ^auth/activate-email$ auth__activate_email.php
    RewriteRule ^auth/activate-sms$ auth__activate_sms.php


    RewriteRule ^ajax/locations$ process/ajax/locations.php?slug=ajax-actions [QSA]
    RewriteRule ^ajax/captcha$ process/ajax/captcha.php?slug=ajax-actions [QSA]
    RewriteRule ^ajax/map-search$ process/ajax/map__search.php?slug=ajax-actions [QSA]
    RewriteRule ^ajax/category$ process/ajax/category.php?slug=ajax-actions [QSA]
    RewriteRule ^ajax/like$ process/ajax/like.php?slug=ajax-actions [QSA]
    RewriteRule ^ajax/favourite$ process/ajax/favourite.php?slug=ajax-actions [QSA]

    RewriteRule ^restrict/ restrict.php
    RewriteRule ^restrict-ip/ restrict-ip.php

    RewriteRule ^robots.txt$ robots.php

    RewriteRule ^account?$ account__dashboard.php [QSA]
    RewriteRule ^account/logout process/account/logout.php
    RewriteRule ^account/(.*)$ account__dashboard.php [QSA]

    RewriteRule ^account/item/(\w+)/edit account__edit_item.php?id=$1
    RewriteRule ^account/item/(\w+)/change-plan account__change_plan.php?item_id=$1 [QSA]
    RewriteRule ^account/item/(\w+)/extend account__extend_item.php?item_id=$1 [QSA]
    RewriteRule ^account/item/(\w+)/pay account__pay_item.php?item_id=$1

    RewriteRule ^account/item/(\w+)/delete process/account/delete_item.php?id=$1 [QSA]
    RewriteRule ^account/item/(\w+)/mutate process/account/mutate_item.php?id=$1 [QSA]

    RewriteRule ^affiliate/([\w-]+) actions.php?action=refer&id=$1 [QSA]

    RewriteRule ^help/font-awesome helps.php

    RewriteRule 403 pages.php?page_type=page-403
    RewriteRule demo-restrict pages.php?page_type=page-demo-restrict
</IfModule>

# ErrorDocument : #
ErrorDocument 404 /pages.php?page_type=page-404

Redirect /sitemap.xml /sitemap_index.xml

Options -Indexes

<Files .htaccess>
    order allow,deny
    deny from all
</Files>

LimitRequestBody 10240000

Redirect 301 "https://amlakzanjan.com/zanjan-real-estate-consultants/" "https://amlakzanjan.com/category/12/zanjan-real-estate-consultants"