• Resolved steve92

    (@steve92)


    I would like to know what is the file with the_title() code because I want to replace it with relevanssi_the_title() so then it also highlights the post titles.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Mikko Saari

    (@msaari)

    There’s no single answer to this; it depends on your theme. The file search.php in your theme is the best place to start. Another common place is template-parts/content-search.php.

    Thread Starter steve92

    (@steve92)

    I have 2 sites and found the code in 2 different files: /template-parts/content-excerpt.php and /inc/structure/content-extensions.php
    It would be nice if you put the default code in the next version.

    • This reply was modified 2 years ago by steve92.
    Plugin Author Mikko Saari

    (@msaari)

    That is, unfortunately, impossible: Relevanssi cannot modify your theme files. In an earlier version, using a separate function wasn’t necessary and the highlights were added automatically, but that doesn’t work: the_title() is used outside post titles, and the highlights would appear to menu items, sidebars and other places where they don’t belong to.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Replace the_title() code’ is closed to new replies.