Publisher does not support the Fluid field type. Please do not contact asking when support will be available.

If you purchased an add-on from expressionengine.com, be sure to visit boldminded.com/claim to add the license to your account here on boldminded.com.

Ticket: No Bloqs contente in search results

Status Resolved
Add-on / Version Bloqs 2.10.7
Severity
EE Version 5.2.1

Werner Gusset

Oct 18, 2019

Have an almost finished developed new site with Publisher and Bloqs where I deal with the search functionality now.

The standard search from EE does find content in standard EE fields, but none of the content in Bloqs is found.

The atoms are set to be searchable and the fields with a set of bloqs is set to be searchable.

Do I miss somewhere a setting or is it a bug?

EE 5.3 | Publisher 2.11.2 | Bloqs 4.1.0

#1

BoldMinded (Brian)

The first thing we’ll need to know is if the searchable data is in the database correctly. To do that you will need to go to the exp_channel_data and exp_publisher_data tables, and find the columns with the field_id of your Bloqs field, then find the row that matches the entry_id. The contents of the field_id_X column should be a long concatenated string of block content separated by pipes, e.g. “this is a heading|some paragraph|some other block|etc|etc” - The channel_data table should have the default language of the text, and the publisher_data table should have the same data, but the translated versions as well.

Here are a couple queries that will help make it easier.

select field_id_X from exp_channel_data where entry_id = 123
select field_id_X from exp_publisher_data where entry_id = 123

If the data is there, then that eliminates a lot of possible issues, but if the data is not there, then that tells me where to start looking at what the issue is.

#2

Werner Gusset

exp_channel_data has no field_id column

exp_channel_data_field_2 has 22 rows where field_id_2 only has content in 1 row. All other rows (also the watched entry_id) are empty.

exp_publisher_data field_id_2 columns is empty, except one row (same entry_id as the one in exp_channel_data_field_2 we can see)

note: we only have entered content in one of the foreseen 4 languages at the moment.

#3

BoldMinded (Brian)

Did you re-save the entries you’re expecting to find in the search results after running the query to add the hook yesterday?

Are you able to provide CP access so I can take a look directly? If so tell me what entry_id you’ve been working with, the URL to the search form, and the search term you’ve been using that you’re expecting results from.

#4

Werner Gusset

I have one entry that is resaved today. The content of this one entry con not be found.

Do you want me to send access infos sent my email?

Need to mention this, in case you would go and resave other entries in the CP:

There is one Block in the field-set which caused trouble yesterday during the day. Entries that have this Block in use couldn’t be resaved without an error message that highlighted the first atom, a checkbox. I removed that checkbos atom from the block because I expected the problem be resolved. But it was not, still had an error message that in a block is an error. No hint what it could be.

I then decided this morning to rebuild that block under a new name, added it to the field, took one entry where I copied the content from the block witch caused the error to the new block, removed the faulty block, adjusted the template and the I could resave.

We need all 20 and more entries to resave with moving the content to that new block. That’s not done yet. But I have an entry resaved today that work ok, as I mentioned. Ann entries without this block but with others are not a problem.

I have not reported this issue because I knew how delicate it could be to find out what is wrong. I mention it because you might run into this when in the CP.

How do you want the infos for an CP access?

#5

BoldMinded (Brian)

Don’t send access info via email, it’s not secure. Edit this ticket, and use the fields provided. When the ticket is resolved, the login info is deleted from the database so it isn’t lingering around forever.

#6

BoldMinded (Brian)

Regarding the block saving issue with the checkbox, you’ll need to make a separate ticket, and if possible include a video of the issue happening so I know exactly what you’re referring to and so I can try to replicate it. Also include a screenshot of the checkbox field settings.

#7

BoldMinded (Brian)

Don’t forget:

If so tell me what entry_id you’ve been working with, the URL to the search form, and the search term you’ve been using that you’re expecting results from.
#8

Werner Gusset

As I was explaining, the checkbox I removed.

Take entry 292 and try to resave, you’ll see the error even the checkbox is gone.

#9

Werner Gusset

Comment has been marked private.

#10

Werner Gusset

Comment has been marked private.

#11

BoldMinded (Brian)

Lets stick to solving one issue at a time here and focus on the searching issue.

The blocks checkbox issue should be a brand new ticket and I will look into that when we resolve the searching issue.

Also, the server/basic http auth you provided in the email doesn’t appear to be working.

#12

Werner Gusset

Comment has been marked private.

#13

BoldMinded (Brian)

Ok, I just setup a test locally and Bloqs searching with Publisher is working as intended. I took a look at your Bloqs fields, and a lot of them do not have the “Include in Search?” option checked: https://d.pr/i/KtgWOi

#14

Werner Gusset

I know that not all fields are searchable, only those that are needed.

Block “zweispaltig” has col_2_title and col_2_text searchable. These are the fields that are not searched in the example I gave you for testing.

There are many fields that are searchable, none of them gives back a search result. Also your hint to look for tables that should have content for field_id_2 show these columns empty.

I am sure if we would make a fresh install it would work as you say. But this is an almost finished project that should go live in 10 days. A fresh install for the more than 400 entries is not of help.

#15

BoldMinded (Brian)

I’m not saying you need to re-create all that content. Have you tried setting up a new/clean EE environment with only Publisher and Bloqs installed with a very basic block to see if you can replicate the issue?

#16

Werner Gusset

Brian, How should I be able to replicate what we have done with a new install? We started by end of April with the project. Filled content bit by bit, updated EE, Publisher, Boqs and other add-ons if there were new versions available. I let run a SQL-query you gave me (missing hook in context with search). All this adds up to what we have now, a website with more than 400 entries that should go live in 10 days and the search utility doesn’t fin any Block content.

You say yourself, a new install at your place proves the search does work. What do I gain if I do the same here? You have access to the CP. You can see the Blocks. Did I do something wrong that causes all Block content not to be searchable?

Please understand that I (and my costumer) are getting nervous because of this problem.

The question is, how do we fix this the next days?

I don’t understand how search in EE is functioning. Maybe this question is stupid: does using Low Search do any difference? Would this add-on find Block content? Or is it based on the same table content that seems to be missing, if I understood correctly your advice to look into database tables?

We need some way out of this frustrating situation and get to a search functionality the finds content in Blocks.

#17

BoldMinded (Brian)

I want to help you fix this, but again, I can’t just fix it if I don’t know what the problem is, and I’m trying to figure out the problem.

“What do I gain if I do the same here?” - This is part of the debugging process. I can’t just login to peoples sites and just fix things, especially when it is a complicated site that I’m not familiar with. The pages you provided as an example are very complex, which means there is a lot of noise, that I as someone unfamiliar with the site, has to navigate around when trying to debug the issue. Imagine trying to login to one of my sites that you have never seen before and try to fix an issue. It is difficult. The first part of debugging is simplifying and isolating the problem. I suggest you read this: https://u.expressionengine.com/article/debugging-in-expressionengine

I ask people to replicate the issue in a clean EE environment (see the Support Terms and Conditions linked in the footer). If they can replicate in a clean environment, then it means that it is probably an issue with the add-on, and then I have a less noisy site to login to to debug. If they can’t replicate the issue, then it usually means that there is something wrong with their existing environment, possibly an add-on conflict, then we go from there to isolate the problem. Sometimes people end of fixing the problem themselves when setting up the clean EE environment because they did something wrong the first time. The clean EE environment is the first thing I ask for when I can’t replicate something myself. It’s just part of the process.

#18

BoldMinded (Brian)

I took another look at your site, and the entry I’ve been testing with is #297, which is in the Referenzen channel, which is not included in your search tag. I updated pt_search_modal to include “referenzen”, and it looks like it returned the correct result. https://d.pr/i/fKAq5H

This is the part that tells me Publisher and Bloqs are working correctly. https://d.pr/i/u8v4X4 It concatenates the blocks fields into a single string in the exp_publisher_data table. You can see the pipe characters are used as the concatenator, so the bloqs text is searchable. It looks like to me if the entries are not being returned in the results correctly it is probably caused by another issue, such as the channel not being defined in the search tag to begin with.

#19

Werner Gusset

First paragraph: The search result is from channel News and not from channel “Referenzen”.

Short version: sorted the problem out. The search works.

Longer version: During the time we fixed the missing hook in Publisher (your SQL statement) I was checking all settings for the atoms in all the blocks. Don’t like it to say: in one of the Blocks I switched the wrong toggle at one of the atoms down the block. I switched the field to requested instead the toggle for a searchable field. The result was, that at resaving an entry with such a block (most entries have them) EE / Bloqs highlited the first atom with an error which was a checkbox field. This was wrong, because the requested field was down the block at another place. I removed the checkbox because I believed it has an error. But I still had an error and the entry could not be resaved. Because I did not know about my mistake and that in reality a field missed requested content, I constructed a new block to replace the one that did not allow resaving. Yesterday I rechecked everything on our site and found the wrong set toggle and corrected my mistake. The result is, that the entries now could be resaved. But at time I was writing forth and back with you we did not have a entry that was resaved after the installation of the missing search hook.

Today I resaved some of the entries and checked the search. It does find content. But again, it took a while to recognize that if there is an umlaut in the search terms (in german very likely that there are umlauts) that EE will not find the content. This has nothing to do with publisher or Bloqs. It’s an EE thing if we use an Wysiwyg Editor. Umlauts are saved as HTML entities and the search routine can not read them. We might be able to configure CK Editor to save ä and not the html entity

We need to go and resave the rest of the content and we might have resolved the troubles.

I run into troubles because of my own mistake with the toggle and because we had to resave all entries with Bloqs Content after the install of the missing hook in Publisher. Sorry if I have taken much of your time and if I reacted nervous two days ago.

#20

BoldMinded (Brian)

Don’t worry about it, I’m just happy that everything is sorted out now 😊

Login to reply