O
O
Orbb2017-06-20 18:34:45
PHP
Orbb, 2017-06-20 18:34:45

Operation of the news complex component from the root, is it possible?

Good evening.
There is a need to display news from the root of the site, such as site.ru/category/element, bypassing the /news/ folder, is there such a possibility? I tried all kinds of instructions, guides and others, I already doubt that Bitrix allows you to implement this using standard tools.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Artyom Davydov, 2018-11-14
@IsaevDimka

// Сгенерировал на http://incarnate.github.io/curl-to-php/

$ch = curl_init();

curl_setopt($ch, CURLOPT_URL, "https://api.myshows.me/v2/rpc/");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, "{\n  \"jsonrpc\": \"2.0\",\n  \"method\": \"shows.GetById\",\n  \"params\": {\n    \"showId\": 1,\n    \"withEpisodes\": true\n  },\n  \"id\": 1\n}");
curl_setopt($ch, CURLOPT_POST, 1);

$headers = array();
$headers[] = "Content-Type: application/json";
$headers[] = "Accept: application/json";
$headers[] = "Authorization: Bearer 859ea2450228a5d655e3a8c2f9a5aedc30b591df";
$headers[] = "Accept-Language: en";
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);

$result = curl_exec($ch);
if (curl_errno($ch)) {
    echo 'Error:' . curl_error($ch);
}
curl_close ($ch);

S
Sergey, 2017-06-20
@gangstarcj

Configure in the infoblock and configure the component parameters and everything works fine

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question