Ads readiness, lead delivery, project inventory
- SEO/ads: title, description, canonical, OG 1200x630, JSON-LD, robots, sitemap, .htaccess - Privacy policy page with operator data; server-side consent check; cookie reset in footer - Metrika loads only after cookie consent; goals lead / email_click / phone_click; utm and yclid stored with the lead - Form delivery: store, Telegram, SMTP, webhook; config presets; dev stub - Project window shows public sections only; Moba copy rewritten - Fix 14 px horizontal overflow in the filter bar on phones - Move history to archive/; add docs/project-inventory.md and docs/lead-delivery.md
This commit is contained in:
1 parent
e352335822
commit
b60d00d55c
47 files changed
+1665
-202
No files matched your search
+56
-6
@@ -1,12 +1,62 @@
|
||||
<?php
|
||||
/**
|
||||
* Copy this file to config.php and fill in real values.
|
||||
* config.php is gitignored — never commit bot credentials.
|
||||
* config.php is gitignored — never commit credentials.
|
||||
*
|
||||
* Bot: create via @BotFather, add to the target chat, chat_id for groups:
|
||||
* send any message to the group, then GET https://api.telegram.org/bot<TOKEN>/getUpdates
|
||||
* and read message.chat.id (starts with '-' for groups).
|
||||
* Every channel with a non-empty value is used, in this order:
|
||||
* 1. store — ALWAYS on. Lead is appended to api/var/leads/YYYY-MM.jsonl.
|
||||
* 2. telegram — BOT_TOKEN + TG_CHAT_ID
|
||||
* 3. email — MAIL_TO + (SMTP_* or MAIL_MODE = 'mail')
|
||||
* 4. webhook — WEBHOOK_URL (+ optional WEBHOOK_TOKEN)
|
||||
*
|
||||
* The form reports success when at least one of 2–4 accepted the lead.
|
||||
* With everything empty the endpoint answers 500 — the form is never silently dead.
|
||||
*/
|
||||
|
||||
const BOT_TOKEN = '123456789:AA...';
|
||||
const TG_CHAT_ID = '-1000000000000';
|
||||
/* ---------- 1. Telegram ----------
|
||||
* Bot: @BotFather → /newbot. Add the bot to the target chat, send any message
|
||||
* (for groups: /start@your_bot), then GET
|
||||
* https://api.telegram.org/bot<TOKEN>/getUpdates and read message.chat.id
|
||||
* (group ids start with '-'). */
|
||||
const BOT_TOKEN = '';
|
||||
const TG_CHAT_ID = '';
|
||||
|
||||
/* ---------- 2. Email ----------
|
||||
* MAIL_MODE = 'smtp' — the built-in client (AUTH LOGIN + SSL/STARTTLS), no Composer.
|
||||
* MAIL_MODE = 'mail' — PHP mail(); works on many shared hosts, weaker deliverability.
|
||||
*
|
||||
* MAIL_FROM must belong to the domain that has SPF/DKIM configured, otherwise
|
||||
* Gmail/VK/Yandex will spam-filter every lead.
|
||||
*
|
||||
* Presets (copy the block you need):
|
||||
* Yandex 360: SMTP_HOST = 'smtp.yandex.ru'; SMTP_PORT = 465; SMTP_SECURE = 'ssl';
|
||||
* SMTP_USER = 'site@harveymonsterteam.ru'; (password = app password)
|
||||
* Mail.ru: SMTP_HOST = 'smtp.mail.ru'; SMTP_PORT = 465; SMTP_SECURE = 'ssl';
|
||||
* Unisender Go:SMTP_HOST = 'smtp.go1.unisender.ru'; SMTP_PORT = 587; SMTP_SECURE = 'tls';
|
||||
* SendPulse: SMTP_HOST = 'smtp-pulse.com'; SMTP_PORT = 465; SMTP_SECURE = 'ssl';
|
||||
* Mailgun: SMTP_HOST = 'smtp.mailgun.org'; SMTP_PORT = 587; SMTP_SECURE = 'tls';
|
||||
* Brevo: SMTP_HOST = 'smtp-relay.brevo.com'; SMTP_PORT = 587; SMTP_SECURE = 'tls';
|
||||
* Timeweb: SMTP_HOST = 'smtp.timeweb.ru'; SMTP_PORT = 465; SMTP_SECURE = 'ssl';
|
||||
*/
|
||||
const MAIL_MODE = 'smtp'; // 'smtp' | 'mail'
|
||||
const MAIL_TO = 'monsterharvi@gmail.com';
|
||||
const MAIL_FROM = 'site@harveymonsterteam.ru';
|
||||
const MAIL_FROM_NAME = 'Harvey Monster Team';
|
||||
const MAIL_SUBJECT = 'Заявка с harveymonsterteam.ru';
|
||||
|
||||
const SMTP_HOST = '';
|
||||
const SMTP_PORT = 465;
|
||||
const SMTP_SECURE = 'ssl'; // 'ssl' (465) | 'tls' (587, STARTTLS) | '' (25, plain)
|
||||
const SMTP_USER = '';
|
||||
const SMTP_PASS = '';
|
||||
|
||||
/* ---------- 3. Webhook ----------
|
||||
* Any endpoint that accepts JSON:
|
||||
* {"site","sent_at","name","contact","message","consent","meta":{utm,yclid,…}}
|
||||
* Works directly with Make / n8n / Zapier / Albato / a custom handler.
|
||||
* Native CRM and ESP APIs (Bitrix24, amoCRM, Unisender, SendPulse) need their own
|
||||
* field mapping — point the webhook at a no-code scenario that does the mapping
|
||||
* (recipe in docs/lead-delivery.md), not at the API URL directly.
|
||||
* WEBHOOK_TOKEN, when set, is sent as `Authorization: Bearer <token>`. */
|
||||
const WEBHOOK_URL = '';
|
||||
const WEBHOOK_TOKEN = '';
|
||||
Reference in new issue
Block a user