Answer the question
In order to leave comments, you need to log in
Dynamic creation of CNC links?
There is a filter for restaurants. Restaurants are filtered by metro station, average bill, type of cuisine, type of establishment, and so on. Examples of links for filtering:
site.ru/metro/metro_station
site.ru/metro/metro_station/kitchen/kitchen_type
The user ticks the necessary items on the page, then clicks "find". I'm thinking of creating a url using js. Is this the right decision?
PS To transfer, for example, several metro stations, is it better to use a separator or are there better options? That is, the link will look like this site.ru/metro/station_metro1, station_metro2
Answer the question
In order to leave comments, you need to log in
There are search params for this, which are in the url after ? go. And then what the hell.
What exactly is the reason for such a url format?
What if js is disabled? The result will be a null link. In any case, it's better to look towards get
Given your set of conditions, this is the only solution . It is not clear how correctness can be assessed here .
But the conditions are, frankly, stupid.
did recently
for all checkboxes in the filter, wrote a piece of the link to the data-attributes and simply added them through /
if 2 checkboxes from the same group were selected, for example 2 brands, then this piece of the link was done in the
Yandex get-parameters, everything started processing normally after 1.5-2 months and to display such pages in the search,
the main thing is that the cmska ate such links and processed them correctly + did a normal h1 and
UPD meta
wrote a little wrong,
you cycle through the filter blocks,
if in one of the blocks there are 2 checkboxes or more, for example, 2 brands are selected, then you form a link with get-parameters,
if one daw is used, then you form an NC-link,
I repeat the main thing is that CMS was able to parse such links
for this they usually do a prefix to them, for example / f /
it turns out something like site.ru/catalog/f/brand_brand/color_color/
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question