We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 785
    • 2,113 Posts
    In Search Highlighting:
    $body = explode("<body", $output); // break out the head
    But:
    $output = implode("<body>", $body);
    Result:
    <body>>
    Solution:
    $output = implode("<body", $body);
      Создание сайтов на MODx, поддержка сайтов, поисковая оптимизация, программирование, копирайтинг
      Статьи о MODx, регулярно новые публикации
      • 5811
      • 1,717 Posts
      Thanks Bredova & Akots. Registered as AJAXSEARCH-38

      I didn’t see this typo.
      I made my tests and the demo site with the advSearchHighlight plugin (advSearchHighlight.tpl), which doesn’t explode the <body> tag.

          AdvSearch_Highlight is an advanced "Multi-Part" variant of Search_Highlight
          It allows to frame with "<!--start highlight-->" and <!--end highlight-->
          several parts of the site that will be highligthed
        • 8643
        • 271 Posts
        Hi coroico,
        Can you add multi-language support to SearchHighlight plugin(for $termText,$removeText)?

          • 4036
          • 239 Posts
          Dear coroico,
          I have problem with search Highlighting in EVO 1.0

          http://www.kiddys.info/ I use AjaxSearch 1.8.3

          Search:
          [!AjaxSearch? &AS_showResults=`0` &AS_landing=`1036` &showMoreResults=`1` &moreResultsPage=`1036` &extract=`0` &language=`russian-utf8` &addJscript=`0`!]

          Page results:
          [!AjaxSearch? &ajaxSearch=`0` &AS_showForm=`0` &language=`russian-utf8`!]


          I enter words for search "100", then on page with results of search I pass under any link (http://kiddys.info/catalog/detskaya-mebel/stoly-dlya-obucheniya-i-tvorchestva-aksessuary/lampa-proektor-dlya-risovaniya-1001a31.html?searched=100&advsearch=oneword&highlight=ajaxSearch_highlight+ajaxSearch_highlight1)

          And I see <body>> on this page.

          I change
          $output = implode("<body>", $body);

          $output = implode("<body", $body);
          in plugin.searchHighlight.tpl

          But the error does not disappear.

          Help me, please!
            Портфолио - http://wowstudio.pro
            • 22668
            • 718 Posts
            Hi coroico grin

            Is this replacing can fix the problem?

                $body = explode("<body", $output); // break out the head
            replace with
                $body = explode("<body>", $output); // break out the head


            Working for me.
              • 4036
              • 239 Posts
              Quote from: Paprikas at Aug 11, 2009, 05:10 AM

              Hi coroico grin

              Is this replacing can fix the problem?

                  $body = explode("<body", $output); // break out the head
              replace with
                  $body = explode("<body>", $output); // break out the head


              Working for me.

              This is my file
                Портфолио - http://wowstudio.pro
                • 785
                • 2,113 Posts
                Quote from: Bredova at Aug 11, 2009, 05:25 AM

                This is my file
                Not file replace, but plugin in admin mode.
                  Создание сайтов на MODx, поддержка сайтов, поисковая оптимизация, программирование, копирайтинг
                  Статьи о MODx, регулярно новые публикации
                  • 5811
                  • 1,717 Posts
                  @Bredova

                  As explained by akots, you need
                  1/ In the searchHighlight.tpl file replace:

                  line 123: $output = implode("<body>", $body);
                  by:
                  $output = implode("<body", $body);

                  2/ copy / paste the content of this file inside the content of the plugin in the manager


                  @Paprikas

                  $body = explode("<body", $output); // break out the head
                  replace with
                  $body = explode("<body>", $output); // break out the head
                  This fix the problem, but if you have for instance: <body id="type-b"> the plugin couldn’t work.
                  This is the reason why I have done the change between 1.4 and 1.3 versions.


                  Apologies for this error, but as I use the advSearchHighlight.tpl as plugin, I didn’t see this error.
                    • 4036
                    • 239 Posts
                    Sorry, I not there corrected, the error has disappeared.
                      Портфолио - http://wowstudio.pro
                      • 22668
                      • 718 Posts
                      Ok. The first fix not work for me because I get error on pages that have Jot call.