• Resolved Kobekes

    (@kobekes)


    Hi,

    is there a way to change the structure of the posts made by instagrab?

    Now it is like this:

    <a href="**to tag**"><img width="30" src="**profile-image**"/>
    **name**</a><img src="**instagram image**" alt=""/>
    
    <h3><a target="_blank" href="**link to image**"><img border="0"
    src="**instagram_logo.png**" alt="Posted on Instagram"/></a>
     ** Caption of instagram image**</h3>

    The caption (title) of the instagram picture is also the title of the post.

    I can change the css for <h3>, but how do I remove the profile picture for example?

    Thanks.

    Erik.

    https://www.ads-software.com/extend/plugins/instagrab/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Kobekes

    (@kobekes)

    Do I have to plunge into the instagrabGrabAndSave-function in instagrab/instagrab.php to do this?

    function instagrabGrabAndSave() {
    		$hashtags = explode("\n", get_option($this->prefix . "tags"));
    
    		require_once(ABSPATH . 'wp-admin/includes/taxonomy.php');
    
    		foreach($hashtags as $hashtag) {
    			$category_id = wp_create_category($hashtag, 0);
    			$images = $this->instagrabGetImagesByHashtag($hashtag);
    
    			foreach($images as $image) {
    				$link = home_url() . "/?tag=" . $image['author']['username'];
    				$content = <<<EOF
    	<a href="{$link}"><img width="30" src="{$image['author']['picture']}"/> {$image['author']['username']}</a>
    	<img src="{$image['images']['large']}" alt=""/>
    	<h3><a href="{$image['link']}"><img border="0" src="{$this->instagram_logo}" alt="Posted on Instagram"/></a> {$image['title']}</h3>

    [Please post code & markup between backticks or use the code button. Your posted code has now been permanently damaged by the forum’s parser.]

    Plugin Author Ole-Kenneth

    (@olekenneth)

    Short answer: yes

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘structure of posts’ is closed to new replies.