tofers / instagram-post-info
Getting data about a post on Instagram. Nickname, location, post date, number of likes, photo.
Installs: 25
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 2
Forks: 0
Open Issues: 0
Type:object
Requires
- php: >=5.6.0
README
Instagam post info - nicname, image, date, likes, location
Getting data about a post on Instagram. Nickname, location, post date, number of likes, photo.
Only links of public posts from Instagram will work, if this is a public account, the result will be an error.
Installation
The preferred way to install this extension is through composer.
Either run:
composer require tofers/instagram-post-info
or add
"tofers/instagram-post-info": "*"
to the require section of your composer.json
file.
Usage
See how it works:
Set link to extension in your view:
<?php use tofers\instagrampost\InstagramPostInfo; $instagram_post = new InstagramPostInfo("https://www.instagram.com/p/CB7KzC6BPIn/"); echo 'instagram link: ' . $instagram_post->src; echo '<br>'; echo '<br>'; echo 'Account name: ' . $instagram_post->account; echo '<br>'; echo '<br>'; echo 'Image src: ' . $instagram_post->image; echo '<br>'; echo '<br>'; echo 'Date post: ' . $instagram_post->date; echo '<br>'; echo '<br>'; echo 'Like post: ' . $instagram_post->like; echo '<br>'; echo '<br>'; echo 'Location: ' . $instagram_post->location; ?>