Camp.php
/**
     * Make amp-instagram component
     * @param string id Instagram post id 
     * @param array attrs List of element attributes
     * @return object amp-instagram node
     */
Make amp-instagram component
@param string id Instagram post id
@param array attrs List of element attributes
@return object amp-instagram node
Make amp - instagram component @param string id Instagram post id @param array attrs List of element attributes @return object amp - instagram node
private function _makeAmpInstagram($id, $attrs, $caption=true){
        unset($attrs['src']);
        if(isset($attrs['frameborder']))
            unset($attrs['frameborder']);
        $attrs['data-shortcode'] = $id;
        if($caption)
            $attrs['data-captioned'] = 'data-captioned';
        $attrs['layout'] = 'responsive';
        $amp_instagram = $this->doc->createElement('amp-instagram');
        $this->_setAttribute($amp_instagram, $attrs);
        $this->_addComponent('amp-instagram');
        return $amp_instagram;
    }
private function _makeAmpInstagram ( $ id , $ attrs , $ caption = true ) { unset ( $ attrs [ 'src' ] ) ; if ( isset ( $ attrs [ 'frameborder' ] ) ) unset ( $ attrs [ 'frameborder' ] ) ; $ attrs [ 'data-shortcode' ] = $ id ; if ( $ caption ) $ attrs [ 'data-captioned' ] = 'data-captioned' ; $ attrs [ 'layout' ] = 'responsive' ; $ amp_instagram = $ this -> doc -> createElement ( 'amp-instagram' ) ; $ this -> _setAttribute ( $ amp_instagram , $ attrs ) ; $ this -> _addComponent ( 'amp-instagram' ) ; return $ amp_instagram ; }
Make amp-instagram component
 @param string id Instagram post id
 @param array attrs List of element attributes
 @return object amp-instagram node
Make amp - instagram component @param string id Instagram post id @param array attrs List of element attributes @return object amp - instagram node