Hivu Films - Watch Movie - Custom Full Automatic Php Streaming Platform
Hivu Films - Watch Movie - Custom Full Automatic Php Streaming Platform
Gallery
About
hivu.net is a fully custom-built, production-ready Video on Demand (VOD) platform developed in pure PHP with a MySQL backend. It is architecturally modeled after Netflix and major streaming services, and ships with a powerful admin panel, an automated content scraper, a full TMDB integration pipeline, an HLS video player, subtitle support, advertisement management, multi-language UI (Turkish / English), SEO optimization, and much more.This is not a WordPress plugin. This is not a template. This is a hand-engineered, ground-up custom MVC PHP application — designed to scale, perform, and operate autonomously.TECHNICAL ARCHITECTURELanguage: PHP 8.1 Database: MySQL (InnoDB, UTF8MB4) Architecture: Custom MVC (Model / View / Controller) Frontend: HTML5 + Vanilla CSS + Bootstrap 5 + Bootstrap Icons Video Player: Plyr.js + HLS.js (native HLS streaming) HTTP: cURL (multi-source scraping, TMDB API calls) Routing: Custom URL router with clean SEO-friendly URLs Hosting: cPanel / shared hosting compatible (PHP 8.1, mod_rewrite) Fonts: Google Fonts (Outfit) Icons: Bootstrap Icons 1.11The application follows a strict MVC separation. Routing is handled in index.php, controllers extend a base Controller class that provides render(), json(), redirect(), and CSRF utilities, models extend a base Model with fluent query methods, and views are pure PHP templates loaded via a layout system.VIDEO PLAYERPlyr.js + HLS.js integrated player supporting native HLS (.m3u8) streamsSupports JSON stream format with full subtitle track loadingSupports legacy iframe / embed URLs (ok.ru, vidmoly, uptostream, filemoon, vidoza, streamtape, etc.)Multi-source tab system: if a content item has multiple video sources, tabs are shown above the player to switch between them seamlesslyResume playback: the player automatically saves watch progress to localStorage and presents a Resume / Restart dialog on next visitAd overlay system: pre-roll or overlay ads with configurable skip timers, countdown displays, and clickable linksFull-screen default: the player opens covering the entire viewport immediatelySubtitle tracks (.vtt) are loaded from the JSON payload and rendered natively via the Plyr subtitle engineMobile-optimized: volume controls hidden on small screens, progress bar full-width, wrap-mode controlsADMIN PANELA fully-featured admin panel available at /admin.Dashboard: Live counters for total movies, series, episodes, views, comments, and favorites. Recent activity log. Quick-access links to all management sections.Movie Management: Add, edit, and delete movies with full metadata including title, original title, description, poster, backdrop, trailer URL, embed code / video URL, categories, IMDB rating, release year, duration, country, director, cast, age limit, budget, revenue, filming locations, production companies, soundtracks, alternative titles, watch providers, and awards. Slug auto-generation with SEO suffix. Duplicate TMDB ID check before insert. Featured flag for homepage slider.Series & Episode Management: Full series metadata plus total seasons and total episodes. Per-episode management with season number, episode number, title, description, poster, and embed code. Full support for JSON stream format per episode.Category Management: Add, edit, and delete categories with slug generation. Type flag for movie, series, or both.Slider Management: Hero carousel on the homepage. Each slide links to a movie or series by ID. Active/inactive toggle and sort order.Ad Management: Multiple ad types including banner, video overlay, and pre-roll. Per-ad configuration for source URL, click-through URL, duration, and skip-after seconds. Ads are injected into the player and homepage banners dynamically.Comment Moderation: Review and delete user comments per content item.Site Settings: TMDB API key configuration, site name, SEO defaults, contact info.Features Panel: View and delete incoming contact form messages. System-wide activity log. Admin notification center.THE SCRAPER SYSTEM (MOST CRITICAL FEATURE)The heart of the platform is the AdminTmdbController, a 2,184-line automated content acquisition engine. Here is how it works step by step:STEP 1 — TMDB SEARCH & IMPORTWhen an admin types a movie or series title in the TMDB Import panel, a live TMDB API search is made. Results are returned in real-time with poster, year, and rating previews. The admin clicks Import on the desired result.STEP 2 — TMDB DATA PULLThe importer fetches a complete TMDB detail payload including: title, original title, overview and description, poster and backdrop images, genres (auto-created as categories in the database), director, cast up to 15 actors with name, character, and profile photo URL, YouTube trailer URL, IMDB rating, release date, runtime, production companies, budget, revenue, alternative titles, and watch providers such as Netflix and Disney+.STEP 3 — AUTOMATIC VIDEO SOURCE SCRAPINGAfter TMDB data is collected, the system automatically searches for a working video stream without any admin input. This is a fully autonomous multi-source web scraping pipeline.Primary Source: sinekfilmizle.comA search query is constructed by sanitizing the title and removing special characters that break search engines. The scraper tries three search strategies in order of priority: the original English title, the clean localized title, and a slug-derived keyword fallback. Search results are parsed with regex to extract movie page links. Each candidate link is validated against a year match, a text similarity check using PHP's similar_text() function with at least 85% similarity threshold, and a URL keyword check to prevent false positives. Once the correct movie page URL is identified, the scraper fetches that page and extracts all iframe source attributes plus any loadFilmPlayer() JavaScript calls. Video sources are prioritized in this order: ok.ru, vidmoly, uptostream, filemoon, vidoza, voe, uqload, streamtape, rapidplay. The first matching source is selected.Fallback Source: jetfilmizle.nowIf the primary source returns no result, the scraper falls back to jetfilmizle.now. It uses the correct search endpoint with full browser-spoofed headers and cookie jar management to simulate a real browser visit. The scraper parses the site's specific HTML structure to find the film page link, then extracts the stream source from data attributes.Series Scraping (Episode-Level)For TV series, each season and each episode is scraped individually. The scraper searches for episode-specific pattern URLs. For each episode, it extracts the embed code or stream URL and stores it in the episodes table. The system supports the full JSON stream format for episodes including subtitles and poster.JSON Stream Format (Videopark Integration)The platform is integrated with Videopark CDN, which serves HLS streams. Stream data is stored as a JSON object containing a stream URL, an array of subtitle tracks (each with file URL and label), and a poster image URL. The player detects this format at runtime and initializes Plyr with the HLS source and subtitle tracks automatically.Multi-Source FormatFor content with multiple quality options or mirror servers, a sources array is stored containing multiple stream entries each with a label and URL. The player renders a tab bar above the video with one button per source.STEP 4 — DATABASE WRITEAfter scraping, the movie or series record is inserted with all TMDB metadata plus the scraped video URL. Cast is stored as a JSON array. Genres are created in the categories table if not already present. Slugs are uniqueness-checked and suffixed if a collision exists.STEP 5 — LIVE API BRIDGEThe admin panel can push content directly to the live production site via a secure API bridge. A secret key authenticates every request. Supported actions include insert_movie, insert_series, insert_episode, repair_movie, repair_series, and repair_episode. Content added on the local development environment becomes immediately visible on the live production server.STEP 6 — REPAIR FUNCTIONSThe scraper has full repair and update capabilities. Repair Movie re-scrapes both sources for a movie that has a broken or missing video URL and updates only the video fields without overwriting other metadata. Repair Series Episodes iterates all episodes of a series and re-scrapes each one, only updating episodes that have empty embed codes. Bulk Repair fixes all broken content items in one click.MULTI-LANGUAGE SYSTEM (TR / EN)The platform ships with a complete dual-language system. Language is stored in the session and toggled via a URL switch. All UI strings including buttons, labels, headings, breadcrumbs, section titles, player dialogs, ad labels, metadata field names, and form placeholders are served through a central Language helper. Translated keys cover: home, movies, series, categories, search, favorites, contact, dmca, play, trailer, details, add to favorites, in favorites, cast, director, country, age limit, production companies, budget, revenue, episodes, season, episode, trending movies, newly added, popular series, continue watching, load more, view all, click to watch, ad, skip ad, resume, restart, comments, submit, and many more. TMDB content such as titles, descriptions, and cast names remains as sourced from the API.SEO & DISCOVERABILITYClean SEO-friendly URLs for all content pages, category pages, search, and episode pages. JSON-LD Schema Markup on every movie and series page for Google rich results. Breadcrumb navigation on all detail pages. robots.txt configured to allow indexing of content pages and block admin. Sitemap route at /sitemap.xml. Meta descriptions dynamically generated from TMDB overview. Open Graph meta tags on movie and series pages for social sharing. Slugs use locale-aware transliteration.USER FEATURESWatch History & Continue Watching: Every play event is recorded with content ID, type, progress in seconds, and total duration. The homepage shows a Continue Watching row for returning users. Progress is also persisted client-side for gapless resumption.Favorites: Users can bookmark movies and series without logging in. A favorites page lists all bookmarked content.Comments: Guest comments with name field on every movie and series page. Admin moderation panel to approve or delete. Comment count displayed in the section heading.Ratings: Star rating UI on detail pages.Comparison: A dedicated page for side-by-side movie comparison by metadata.Collections: Group movies into thematic collections such as Marvel Cinematic Universe. Each collection has its own URL.Filter & Browse: Listing pages for movies and series with pagination. Filter by genre, year range, and rating. Trending movies page. Category browsing pages.Search: Live AJAX search as the user types. Search results page. Searches across movie and series titles simultaneously.Contact Form: Contact form with messages stored to database, viewable in admin. Contact link in main navbar.LEGAL PAGESDMCA / Copyright Notice at /dmca. Full legal text per Law No. 5651. Declares the site as a hosting service provider operating under notice and takedown principle. Links directly to the contact form for takedown requests. Response time stated as within 2 business days.FRONTEND DESIGNDark Netflix-style theme throughout with deep background colors and red accent color. Hero slider with full-bleed backdrop images, gradient overlays, animated title and description reveal, and play button with hover glow. Card grid system with hover scale and info overlay animations. Glass-morphism effects on modals and overlays. Fully mobile-optimized with Bootstrap 5 grid. Micro-animations including card hover scale, button transitions, and slider fade. Google Fonts Outfit for premium typography. Category chips, season and episode tabs, cast photo rows — all styled consistently.DATABASE SCHEMA HIGHLIGHTSMain tables: movies (film records with full metadata, embed code, and video URL), series (series records with season and episode counts), episodes (per-episode records with individual embed codes), categories (genre taxonomy), sliders (hero carousel slides), watch_history (user watch progress), favorites (bookmarked content), comments (user comments), ratings (star ratings), ads (ad campaigns), contact_messages (form submissions), settings (key-value site configuration), activity_log (admin activity audit trail), notifications (admin notification queue), collections (curated content collections).The embed_code column in both movies and episodes supports three formats: raw iframe HTML, plain stream URL auto-wrapped in iframe, and JSON stream object with HLS stream plus subtitles and poster detected by the opening curly brace character.DEPLOYMENTCompatible with any cPanel or shared hosting running PHP 8.1 or above. Apache mod_rewrite configured via .htaccess so all routes pass through index.php. Database seeded via provided SQL file including schema and sample data. TMDB API key configured once in Admin Settings. Live content push configured via API bridge on the production server.FEATURE SUMMARYCustom PHP MVC Framework — Complete Admin Panel with Full CRUD — Complete TMDB Auto-Import — Complete Auto Video Scraper (primary source) — Complete Auto Video Scraper (fallback source) — Complete HLS + Subtitle Player (Plyr + HLS.js) — Complete Multi-Source Video Tab System — Complete Resume Playback — Complete Advertisement System — Complete Multi-Language TR/EN — Complete SEO + JSON-LD Schema — Complete Watch History — Complete Favorites — Complete Comments & Ratings — Complete Series + Episode Management — Complete Live API Bridge (local to production) — Complete DMCA / Legal Pages — Complete Contact Form — Complete Collections — Complete Movie Comparison — Complete Filter & Browse — Complete Responsive Mobile Design — CompleteBuilt with PHP 8.1 · MySQL · Plyr.js · HLS.js · Bootstrap 5 · TMDB API
Comments (2)
pure php at netflix scale is certainly a choice
pure php with no framework is a bold call for streaming scale
ComingUp