T
T
T-ed2018-01-10 18:06:11
Python
T-ed, 2018-01-10 18:06:11

How to give a piece of code to the Yandex bot, but not give it to others?

Please help me solve a small problem. There is this code in the header of the site:

<?php if (is_page_template( 'brokers-cards-template-noajax.php' )  ) : ?>
 <meta name="fragment" content="!">
<?php endif; ?>

You need to give a piece of code only to the Yandex crawler, but close it for the rest. Tell me how to do it, maybe wrap it in some other condition? I practically do not understand PHP, so if you can just throw off the finished piece of code. Thanks <meta name="fragment" content="!">

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Danil, 2019-10-29
@DanilBaibak

For data preparation, sklearn is a great choice. The library contains a number of preprocessing tools . Some more examples can be seen here .

S
synapse_people, 2018-01-10
@synapse_people

anyway, Yandex bot does not always send the required user-agent header values)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question