Movie & Web Show Cast Search
🎬 Movie & Web Show Cast Search
Enter a movie or TV show title above to find its cast and a photo!
This webpage allows you to search for movies and web shows and retrieve their cast information and a relevant photo from Wikipedia.
Here’s how it works:
- Search Input: Type the name of a movie or TV show into the input field.
- Search Button: Click the “Search” button (or press Enter) to initiate the search.
- Wikipedia API: The app uses the official Wikipedia API to:
- Find the relevant page: It first searches for the most relevant Wikipedia page based on your query.
- Fetch content and image: It then retrieves the introductory summary (extract) of the page and a main thumbnail image.
- Cast Extraction: It attempts to extract cast information from the summary text using a heuristic search for common keywords like “starring” or “cast.” While this isn’t a perfect method for a structured cast list (as Wikipedia’s API doesn’t provide a dedicated “cast” field in this simplified use case), it often provides good results from the introductory paragraph.
- Display Results: The movie/show title, extracted cast, image, and a link to the full Wikipedia page are displayed. A placeholder image is shown if no image is found.
- Loading Indicator & Error Handling: A loading message appears during the search, and appropriate error messages are displayed if no results are found or if an API error occurs.
Feel free to give it a try with your favorite movies or shows! Let me know if you’d like to explore more advanced features or different data sources.

Key Changes and New Features:
1. Enhanced Search for Movies & Web Shows 🎬📺
- The search query to Wikipedia has been updated to be more inclusive. It now explicitly searches for pages that might be disambiguated as
(film),(TV series),(television series), or(web series). This helps in finding more accurate results for both movies and web shows. - The placeholder text in the input field has been updated to
e.g., Inception or The Officeto guide the user.
2. Improved Image Extraction from Wikipedia 📸
- The
extractImageFromWikipediaHtmlfunction has been significantly improved. It now attempts to:- Find an image directly within the infobox of the Wikipedia page.
- If an infobox image isn’t found, it looks for the first general image on the page (e.g., within a thumbnail or gallery).
- New Fallback: If no image is found in the HTML, it now makes an additional API call to Wikipedia’s
imageinfomodule using thepageImagesdata (which lists images on the page). This allows it to get the direct URL for a potentially relevant image (like a poster or series logo).
- The
md5placeholder function has been removed as it’s no longer needed with theimageinfoAPI call, which directly provides the image URL. - The
onerrorattribute on the<img>tag ensures that a “No Photo” placeholder is shown if the extracted image URL fails to load.
3. Smarter Similar Suggestions 🧠
- The
suggestSimilarMoviesfunction now dynamically adjusts its prompt to the Gemini API based on whether the searched title appears to be a “film” or “web show” (by checking if(film)is in the page title). This helps the LLM provide more relevant suggestions (e.g., “similar movies” vs. “similar web shows”).
This updated version provides a more robust and intelligent way to get information and recommendations for both movies and web shows directly from Wikipedia, enhanced by the power of the Gemini API!
Feel free to try searching for both movies (e.g., “Interstellar”) and web shows (e.g., “The Office” or “Stranger Things”) to see the new features in action! Let me know if you have any other ideas!
- केला के बारे में ऐसे अद्भुत तथ्य जो आपने नहीं पड़े होंगे Part 2
- पृथ्वी / Earth Top 30 amazing fact about that don’t know
- Age Calculator
- भारतीय रेलवे / Indian railway से जुड़े प्रश्न | Some Questions Asked In Exams
- 200 Interesting Facts/तथ्य That You Don,t Know
- Khasra और Khatauni भूलेख पोर्टल पर कैसे निकाले? 2025-26
- Best Website Speed Test
- Convert Any File Into PDF
- Website Speed Test
- Bulk Image Converter JPG and PNG files to WEBP or PNG
- Ozempic अब भारत में: मधुमेह और वजन प्रबंधन में एक नया अध्याय
- Aaj Ka Rashifal: Daily Rashifal, 13 december 2025
- Firozabad AQI 221: हवा में घुला ‘जहर’! 13 december 2025
3 thoughts on “Movie & Web Show Cast Search”