photo

Mark Strozier

shared this question
5 years ago

Employees Involved

photo

PIV Support

Admin

Statistics

5
Comments
313
Views

Relates to

Share

Tags

1
votes

Missing field types | search_page_default

I've developed a very simple theme. Everything is working fine with the exception of the Search page. I'm missing Text and Date range field types. Other field types (dropdowns, multiple select, etc.) are working fine.

I've tried commenting out all of my code and only rendering OR's code in case there was a Javascript or a CSS conflict. Even with all of my code stripped out I'm still missing these field types.

Any suggestions on what to do next?

Thank you.

Mark

Add Comment

Comments (5)

photo Employee
1

You did not disclose the specific version of OR you are using. You always need to do that when requesting support here.

Change your text and date range fields to other field types to eliminate this being a field type problem.

Remove your custom search_page_default template and allow OR to fall back to use its default version. If it works after that, something is wrong with your customized template file. If it still fails, switch the site to use the Lazuli template. If that works, it's a problem with your custom template in general, most likely 'main.html'.

Hard to really diagnose anything without seeing all the custom code and field settings involved.

photo
1

Hi PIV Support,

Thanks for the advice, I'll know next time to add the details. Re: OR version, I'm using the OR 3.2.7 paid version.

As a test, I changed the template from my custom template to Lazuli and the search function came up without any problems, so the fault is somewhere in my custom template, and I agree, most likely main.html. I don't doubt the issue is mine since this is my first custom template. I've got a number of Javascript files in addition to the OR required Javascript files. I'm not sure if there may be a conflict there. On the other hand, I tried to follow the documentation to the letter.

Is there a diagnostic protocol I can follow to try and weed out the problem before opening a support ticket?

Thanks,Mark

photo Employee
1

Mark Strozier wrote:

I've got a number of Javascript files in addition to the OR required Javascript files. I'm not sure if there may be a conflict there.

Is there a diagnostic protocol I can follow to try and weed out the problem before opening a support ticket?

Thanks,Mark

Transparent Tech does not provide debugging services for custom template source code, so I'd suggest familiarizing yourself with the following handy tools:

Chrome's developers tools: for debugging & viewing HTML/CSS and javascript problems. Javascript errors/conflicts are much more easily located, it's the best thing since sliced bread.

The W3C markup validation service: for validating the syntax of your HTML markup. Not all markup errors are bad, but ones that cause the browser to go into "quirks mode" can cause all kinds of headaches, and cause different problems for different browsers.

What was the result of just removing your custom search_page_default template file? That would potentially narrow this down even further.

photo
1

To check, I loaded Lazuli and everything came up fine.

I removed my search_page_default and added a clean search_page_default and the errors still existed.

Diagnostically, I commented out all non-OR Javascript, problem still existed. Then I commented out three non-OR CSS files and the site design completely broke, but the search function worked fine.

I then tried using one of the non-OR CSS files at a time-- same results. Site design hosed, search function fixed.

It looks like I've got to use the three CSS files for the site design, however I've narrowed the problem down to those CSS files.

Do you know of any CSS rules that would specifically affect the search_page_default's text & date range fields?

Thanks for your help.

Mark

photo Employee
1

Mark Strozier wrote:

To check, I loaded Lazuli and everything came up fine.

I removed my search_page_default and added a clean search_page_default and the errors still existed.

All you needed to do was remove your customized version of search_page_default, from your custom template folder. OR would then fall-back to use its "clean" default version.

For CSS debugging, In addition to the Chrome developers tools, I suggest:

W3C CSS validation service

Leave Comment

photo

Attach files...

The file must be a jpg, gif, png, bmp, ico, pdf, doc, rtf, txt, zip or rar no more than 20M