Bitrix Site Manager

CMain::GetCurPage

string
CMain::GetCurPage()

The method GetCurPage is used to obtain the path and name of the current page relative to the site root, without parameters.

Note
If the file of the current page is not defined explicitly, the index page of a folder is determined using the algorithm of the function GetDirIndex.

Parameters

No parameters.

See Also

Example



<?
// current page: /en/?id=3&s=5
$page = $APPLICATION->GetCurPage(); // returns /en/index.php
?>