DEMO GRATIS
- ✓ 1 pantalla / dispositivo
- ✓ +5,000 canales SD & HD
- ✓ +20,000 películas
- ✓ +2,200 series de TV
- ✓ Full Deportes HD/4K
prepare("SELECT * FROM iptv_settings WHERE company_id = ? LIMIT 1"); $st->execute([$companyId]); $row = $st->fetch(PDO::FETCH_ASSOC); // Si no existe, crear fila por defecto if (!$row) { $pdo->prepare("INSERT INTO iptv_settings (company_id, enabled, updated_at) VALUES (?, 1, NOW())") ->execute([$companyId]); $st->execute([$companyId]); $row = $st->fetch(PDO::FETCH_ASSOC); } // ====== Extraer SOLO las columnas que existen en el admin ====== $brand = $row['brand'] ?? 'JMTVDigital'; $subtitle = $row['subtitle'] ?? 'Servicio estable • HD/4K • Soporte rápido • Activación inmediata'; $whatsappNumber = $row['whatsapp'] ?? '50672409841'; // Nuevo número de WhatsApp adicional $whatsappNumber2 = '+50664169373'; $heroTitle = $row['hero_title'] ?? 'Todas tus plataformas en un solo lugar'; $heroSubtitle = $row['hero_subtitle'] ?? 'Canales en vivo, películas, series, documentales, conciertos y mucho más! Vive La Nueva Experiencia'; $heroBtnText = $row['hero_btn_text'] ?? 'Explorar Catálogo'; $plansTitle = $row['plans_title'] ?? 'Planes Disponibles'; $homeButtonUrl = $row['home_button_url'] ?? 'https://catalogo.lightiius.com/'; $logoPath = $row['logo_path'] ?? ''; // Moneda y formato $currencyCode = $row['currency_code'] ?? 'CRC'; $currencySymbol = $row['currency_symbol'] ?? '₡'; $currencyLocale = $row['currency_locale'] ?? 'es-CR'; // Precios y periodos actualizados $planDemoPrice = isset($row['plan_demo_price']) ? (float)$row['plan_demo_price'] : 0; $planDemoPeriod = $row['plan_demo_period'] ?? '6 horas'; $planFamPrice = isset($row['plan_familiar_price']) ? (float)$row['plan_familiar_price'] : 4000; // Cambiado a 4000 $planFamPeriod = $row['plan_familiar_period'] ?? 'mes'; $planPlusPrice = isset($row['plan_plus_price']) ? (float)$row['plan_plus_price'] : 10000; // Cambiado a 10000 $planPlusPeriod = $row['plan_plus_period'] ?? '3 meses'; // ====== Construir URL del logo y verificar existencia ====== $iptvLogoUrl = ''; if ($logoPath) { if (preg_match('~^https?://~i', $logoPath)) { $iptvLogoUrl = $logoPath; } else { $localPath = '../' . ltrim($logoPath, '/'); if (file_exists(__DIR__ . '/' . $localPath)) { $iptvLogoUrl = $localPath; } } } // ====== Favicon: usar archivo fijo o logo como fallback ====== $faviconPath = '../uploads/iptv/favicon.png'; if (file_exists(__DIR__ . '/' . $faviconPath)) { $faviconUrl = $faviconPath; } elseif ($iptvLogoUrl) { $faviconUrl = $iptvLogoUrl; } else { $faviconUrl = ''; } // ====== Textos fijos (NO vienen de DB) ====== $badgeText = 'IPTV PREMIUM'; $badgeIcon = 'fa-crown'; $footerText = 'Este servicio requiere conexión a internet estable. No somos responsables por contenido de terceros.'; $top10Title = 'TOP 10 Destacados'; $top10Sub = 'Las películas y series más populares de nuestro catálogo'; $catalogTitle = 'Catálogo Completo'; $catalogSub = 'Explora miles de películas y series disponibles'; $appsTitle = 'Apps Compatibles'; $appsSub = 'Disponible en todos tus dispositivos favoritos'; $requestTitle = 'Solicitar Contenido'; $requestSub = '¿No encuentras lo que buscas? ¡Solicítalo aquí!'; $apkPath = "images/sharon.apk"; // ====== Función de formato de moneda ====== function money_fmt(float $amount, string $locale, string $currencyCode, string $symbol): string { if (class_exists('NumberFormatter')) { $fmt = new NumberFormatter($locale, NumberFormatter::CURRENCY); $out = $fmt->formatCurrency($amount, $currencyCode); if (is_string($out)) return $out; } $decimals = ($amount == floor($amount)) ? 0 : 2; return $symbol . number_format($amount, $decimals, '.', ','); } $demoPriceText = money_fmt($planDemoPrice, $currencyLocale, $currencyCode, $currencySymbol); $famPriceText = money_fmt($planFamPrice, $currencyLocale, $currencyCode, $currencySymbol); $plusPriceText = money_fmt($planPlusPrice, $currencyLocale, $currencyCode, $currencySymbol); // ====== WhatsApp helpers ====== function waLink(string $number, string $text): string { // Limpiar el número: eliminar + y espacios $cleanNumber = preg_replace('/[^0-9]/', '', $number); return "https://wa.me/".$cleanNumber."?text=".rawurlencode($text); } $waDemo = waLink($whatsappNumber, "Hola! Quiero una DEMO de {$planDemoPeriod}."); $waFamiliar = waLink($whatsappNumber, "Hola! Quiero el plan FAMILIAR ({$planFamPeriod}). ¿Cómo lo activo?"); $waPlus = waLink($whatsappNumber, "Hola! Quiero el plan PLUS ({$planPlusPeriod}). ¿Cómo lo activo?"); $waGeneral = waLink($whatsappNumber, "Hola! Quiero información de IPTV."); $waGeneral2 = waLink($whatsappNumber2, "Hola! Quiero información de IPTV."); ?>
Cargando contenido destacado...
Cargando catálogo...
Elige el plan perfecto para tu entretenimiento
Samsung & LG — App recomendada
TV Box & Fire Stick — Fácil instalación
Streaming Device — Configuración
PC & Laptop — App recomendada