WebsiteBaker Support (2.12.x) > General Help & Support

Search function does not work in WB-Version 2.12.1

(1/3) > >>

henri:
WebsiteBaker Version: 2.12.1 -r188
PHP-Version: 7.2.13

If I type in a search query at Website Default Template v1.0.9, a blank page will appear.
The same happens with other templates with a search function.

In wb admin in search settings are the settings.
visibility: everyone
template: default settings
if I want to select a different template then there is only one template that I can select. And that is template Web site baker Default Template v1.0.9 there is nothing else.

Gast:

--- Quote ---If I type in a search query at Website Default Template v1.0.9, a blank page will appear.
The same happens with other templates with a search function.
--- End quote ---

it works for me,  you must have content stored in the database and not (for example in wysiwyg) the return from a droplet. other modules needs a special search.php in this module folder, to bring results from this module (for example: foldergallery etc). not every module is prepared for the search



--- Quote ---if I want to select a different template then there is only one template that I can select. And that is template Web site baker Default Template v1.0.9 there is nothing else.
--- End quote ---

the selectbox in wb-options -> Search -> Template show's the installed and registered frontend templates, doesn't matter, if you use this templates in the project or not (means: its not required, to use one of the installed templates on a single page)
please go to  addons -> advanced -> select templates and click on the reload button
then try again to select  a template in wb-options -> Search -> Template

more details about this:
in the most older templates the definition of $template_function is missing

--- Code: ---$template_function      = 'template';
--- End code ---
and because of this, the script in wb-settings to read the template list, doesn't found all installed templates. if you reload the templates, the script add this field in the database automatically

or take a look at first into the database table "addons". sort this table by type and look there to type = templates. now check for every row the content in the field "function" - maybe, its empty
now, you can reload the templates like my description

check also the info.php of the installed templates for the definition of $module_function.
(see example in DefaultTemplate/info.php)

henri:
Hi jacobi22,

I added in template Aeromsting in info.php $ template_function = 'template';
I go to addons -> advanced -> select templates and click on the reload button.
I have several modules with text in them such as topics, faq, Download Gallery etc.

Everything remains the same as in my previous message.

dbs:
Hi, in your WB root is a folder "search" and 5 files beginning with search inside?
The X button in top menu shows errors?

Gast:
we need some more details...........

but step by step
additional to my last post in the top: the missing $template_function -parameter in info.php of the template set also a error message in the error.log, if error reporting is set to Production or Development
Example for this Message:

--- Quote ---Sat, 12 Jan 2019 09:54:43 +0000 [E_USER_NOTICE] \admin\templates\install.php:[168] from \admin\templates\install.php:[168] trigger_error "Missing Template-Parameter [$template_function] in aeromsting/info.php!"
--- End quote ---

but a missing Parameter $template_function has nothing to do with the search, only with the Template-Selectbox in WB-settings.

if you start a search, the system looks to the installed modules and call there every!! search.php. If one of them has an error, the script stop's with a empty page like this screenshot here



if i now switch off my error reporting, i get no information about a problem and i hope, thats, what you mean in the first posting with

--- Quote ---a blank page will appear.
--- End quote ---

P.S.: the error from the screenshot was not logged in my wb-intern error.log, only in the server errror-log

Navigation

[0] Message Index

[#] Next page

Go to full version