Good day! I am just starting to learn PHP myself. Can you please tell me how to insert the php-code in the link?
<? Cmodule::IncludeModule('citrus.tszh'); $arResult["ACCOUNTS"] = Array(); $dbAccounts = CTszhAccount::GetList($arOrder = array(), $arFilter = array("USER_ID"=>CUser::GetID()), $arGroupBy = false, $arNavStartParams = false, $arSelectFields = array("*")); $arAccount = $dbAccounts->GetNext(); echo $arAccount["XML_ID"]; ?> To get a link like https://www.somesite.ru/pay/PERSONAL_ACCOUNT=### , where ### is the PHP code
I tried this:
<? Cmodule::IncludeModule('citrus.tszh'); $arResult["ACCOUNTS"] = Array(); $dbAccounts = CTszhAccount::GetList($arOrder = array(), $arFilter = array("USER_ID"=>CUser::GetID()), $arGroupBy = false, $arNavStartParams = false, $arSelectFields = array("*")); $arAccount = $dbAccounts->GetNext(); echo '<a href="https://www.somesite.ru/pay/PERSONAL_ACCOUNT='$arAccount["XML_ID"];'">Ссылка</a>' ?> And, of course, nothing happens. What am I doing wrong?
echo '<a href="https://www.somesite.ru/pay/PERSONAL_ACCOUNT=' . $arAccount["XML_ID"] . '">Ссылка</a>'- u_mulder