Answer the question
In order to leave comments, you need to log in
Bitrix api price output, what could be wrong?
Good afternoon! I'm trying to display the price using api, but it shows the wrong one... The price is not the base one. euro currency. export using product id
$ID = 908;
$arPrice = CPrice::GetByID($ID);
echo "Цена типа ".$arPrice["CATALOG_GROUP_NAME"].
" на товар с кодом ".$ID.": ";
echo CurrencyFormat($arPrice["PRICE"],
$arPrice["CURRENCY"])."<br>";
echo "Вы ".(($arPrice["CAN_ACCESS"]=="Y") ?
"можете" :
"не можете")." видеть эту цену";
Answer the question
In order to leave comments, you need to log in
CPrice::GetByID takes a price ID, and you pass in the product ID.
Can get the price by product id like this Cprice::GetBasePrice($ID);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question