Facebook & Twitter Card Viewer
Facebook & Twitter Card Viewer is a PHP script that fetches metadata from any URL and previews a card in the browser.
The Crawler
This script includes a rich crawler written in PHP. It crawls and gets card-related metadata from any URL. It can even find endpoints of short URLs and get the data from the last URL. Also, the crawler is well-commented and can be easily modified to do more complicated tasks.
Preview
The preview is hand-made and I don't use any iframes from Facebook and Twitter to generate them.
Currently, the following types are supported.
- Normal Facebook cards
- Twitter summary cards
- Twitter summary_large_image cards
What can I do with this script?
- Learn: You can learn some things about crawling, fetching, handling redirects, cURL, creating cards, etc.
- Earn Money : You can host this script in your website and you can earn by showing ads in this page. Just signup to an advertising site (Ex: Adsense) then place your ad code at the bottom.
- Debug your web pages: You can use this script to debug your web pages, find if the card views are working fine. And, to check the meta tags.
Features
- Well-commented PHP Script
- Built in an OOP model
- Javascript is also commented when it comes to tricky things
- Built on bootstrap and jquery
- Crawler supports 301, 302 redirects
- Fast fetcher
- Card Previews
- Meta tags previews
- Supports facebook cards, twitter summary and summary_large_image cards
- Supported in all the modern browsers
FAQs- Can I use this for commercial purposes? Yes, make sure that you buy the extended license
- Can I earn money with this? Yes, there are many websites doing things like these. If you host it, you can earn money
- Can I customize this? Of course, That's what this is designed for.