/**
  * Parse the data into the template
  *
  * @return	void
  */
 private function parse()
 {
     // Add css
     $this->header->addCSS('/src/Frontend/Modules/' . $this->getModule() . '/Layout/Css/Instagram.css');
     // Fetch instagram user
     $instagramUser = FrontendInstagramModel::get($this->data['id']);
     // Pass user info to javascript
     $this->addJSData('user', $instagramUser);
     // Parse user info in template
     $this->tpl->assign('user', $instagramUser);
 }
 /**
  * Execute the action
  */
 public function execute()
 {
     parent::execute();
     // Get POST parameters
     $userId = \SpoonFilter::getPostValue('userId', null, '');
     // Get count settings
     $this->recentCount = FrontendModel::get('fork.settings')->get('Instagram', 'num_recent_items', 10);
     // Get the images from the Instagram API
     $this->images = FrontendInstagramModel::getRecentMedia($userId, $this->recentCount);
     // Output the result
     $this->output(self::OK, $this->images);
 }