Last active
May 6, 2018 04:18
-
-
Save gartes/f5bc75ea9913df83bad176453dfb5a2a to your computer and use it in GitHub Desktop.
ukcpu.document $uDoc
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* скачать внешний файл скрипта и сохранить | |
* opt - найти в файле подстроки и заменить | |
* opt - добавить подстроки в конец и/или в начало файла | |
* @ $file_url - Url скачиваемого файла | |
* @ $save_to - локальное хранилище файла ( JPATH_BASE . "/assets/resurs" . '/gtm/'.$ID.'/gtm.js' ) | |
* @ $scripCherch - array // массив поиска в файле | |
* @ $scriptRepl = array // массив замены | |
* @ $addToContent array( | |
* 'srart' => NULL , // - Добавить в начало файла ( строка ) | |
* 'end' => NULL , // - Добавить в конец файла ( строка ) | |
* ) | |
*/ | |
$uDoc->downloadJs( $file_url , JPATH_BASE . $save_to , $scripCherch , $scriptRepl , $addToContent = NULL ); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jimport('ukcpu.document.document'); | |
$uDoc = ukcpuDocument::getDocument(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// src - точка | |
$uDoc::getDotSrc() | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment