WordPress.org

Forums

Cat + Tag Filter
Вывод логичного заголовка при фильтрации. (7 posts)

  1. voro7nov77alex
    Member
    Posted 4 months ago #

    Здравствуйте, Аджей. Во-первых, хочу выразить вам свои слова искренней благодарности за такой поистине замечательный плагин. Это действительно очень нужная и полезная штука. Я бы даже сказал - это один из самых необходимых плагинов вордпресса.

    Аджей, но мне приходится просить вашей помощи, так как сам не могу решить данную проблему. Плагин у меня настроен так, что поиск выполняется после выбора какой-то одной категории и одного какого-то тега. И вот проблема в том, что используя на страницах вывод заголовков с помощью кода:

    <?php wp_title(' '); ?>

    у меня при поиске через плагин выводится в заголовке название категории, в каторой искали сообщения с выбранным тегом. А очень нужно, чтобы помимо названия категории в заголовке выводилось и название тега по которому осуществлялся поиск.

    Буду вам очень признателен.

    P.S.- пишу вам на русском, так как знаю, что вы до переезда на Филиппины жили в России.

    http://wordpress.org/extend/plugins/cat-tag-filter-widget/

  2. ajayver
    Member
    Plugin Author

    Posted 4 months ago #

    It is prohibited to speak here in any languages except English.
    It is possible to show all chosen tags and categories in the title, but it is a big amount of code and may be worth writing another plugin.

    But id you are familiar with PHP, the chosen tags and categories are stored in $current_tax['tags'] and $current_tax['cats'] variable. So if you call global $current_tax; you can use it anywhere on page.

  3. voro7nov77alex
    Member
    Posted 4 months ago #

    I do not understand how to bring these variables. Tried to do so:

    <h1>
    <?php
    global $current_tax;
    $current_post = $current_tax;
    echo $current_post;
    ?>
    </h1>

    But nothing is displayed on the page.

  4. ajayver
    Member
    Plugin Author

    Posted 4 months ago #

    Try this:

    <h1>
    <?php
    global $current_tax;
    print_r($current_tax);
    ?>
    </h1>
  5. voro7nov77alex
    Member
    Posted 4 months ago #

    Nothing did not appear in the h1 on page.

    [No bumping, thank you.]

  6. esmi
    Theme Diva & Forum Moderator
    Posted 4 months ago #

    @voro7nov77alex: Stop bumping!

  7. ajayver
    Member
    Plugin Author

    Posted 4 months ago #

    I don't know what can be the problem. It would be nice to see what kind of error occurs, but it seems like error reports and warning are turned off on your site.
    I suggest you to hire a programmer - this task shouldn't cost much.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.