/** * Convert URLs to Wygwam Tags. * * @param $html * @return mixed */ private function _convert_urls_to_tags($html) { $asset_ids = $this->EE->input->post('wygwam_asset_ids'); $asset_urls = $this->EE->input->post('wygwam_asset_urls'); // If they select any files using Assets. if (!empty($asset_ids) && !empty($asset_urls) && count($asset_ids) == count($asset_urls)) { // Convert Asset URLs to tags Wygwam_helper::replace_asset_urls($html, $asset_ids, $asset_urls); } // Convert file URLs to tags Wygwam_helper::replace_file_urls($html); // Convert page URLs to tags Wygwam_helper::replace_page_urls($html); return $html; }