bool CMain::SaveFileContent( string abs_path, string content )
The method SaveFileContent saves the page to disk. This method fires the event OnChangeFile.
Parameter | Description |
---|---|
abs_path | Fully qualified file path. |
content | File contents. |
Returns true on success or false otherwise.
<? $file_content = ' <? require($_SERVER["DOCUMENT_ROOT"]."/bitrix/header.php"); $APPLICATION->SetTitle("Title"); ?> Page contents... <?require($_SERVER["DOCUMENT_ROOT"]."/bitrix/footer.php");?> '; $abs_path = $_SERVER["DOCUMENT_ROOT"]."/en/index.php"; if(!$APPLICATION->SaveFileContent($abs_path, $file_content)) ShowError("Error saving file"); ?>
© 2001-2005 Bitrix | Bitrix Site Manager - Content Management & Portal Solutions |