Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search Results page is unable to display the excerpt / content of any found page or post that has been built with Oxygen Builder #3618

Open
graphicdetail opened this issue Feb 18, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@graphicdetail
Copy link

Here is the sandbox site that I have created to show the issue:

https://oxygen-qmj4hg4xczx4l.oxygen-demo.qsandbox.org/

The header just contains a search form.

Doing a search for "Oxygen" shows a good example of the issue:

The search results page is a template which contains the "Easy Posts" element using the "List - Standard (Left)" template. This template contains the "the_excerpt()" function to display the excerpt for the pages / posts found.

It is unable to display any excerpts for any pages or posts that have been built using the Oxygen Builder (I presume this has something to do with the way Oxygen Builder JSON encodes all of it's content).

When doing a search for "Oxygen", you will see 3 results:
"Page Built with Oxygen Builder" is the homepage which contains plenty of text, but the whole page was built using Oxygen Builder.
"Sample Page" is Wordpress's default sample page just containing a small sample of raw text.
"Hello world!" is, of course, Wordpress's default sample blog post which just contains a small sample of raw text.

Note that excerpts are displaying just fine for "Sample Page" and "Hello world!", but no excerpt is displaying for "Page Built with Oxygen Builder".

This is a major problem now for one of our clients for whom we have built their entire website with Oxygen Builder and now they want search functionality added to their site:

https://www.southerncrosspartners.co.nz

We have added the search form to the header of their site and if you do a search for anything on their site (i.e., "Investments"), it shows plenty of found pages, but only their pages titles; no excerpts at all what-so-ever!

Is there a work-around for this at all?

@graphicdetail graphicdetail added the bug Something isn't working label Feb 18, 2025
@graphicdetail
Copy link
Author

One follow up to this is, on our client's site we are using Relevanssi. Relevanssi has the option to generate excerpts from custom fields (which is where Oxygen Builder's content is stored), but when we enable that, the excerpt appears as the raw json code, i.e.,:

...my investment?","activeselector":false},"depth":3},{"id":24,"name":"oxy_rich_text","options":{"ct_id":24,"ct_parent":27,"selector":"_rich_text-24-125","original":{"font-size":"20","line-height":"31.5px","margin-bottom":"35"},"nicename":"Rich Text (#24)","ct_content":" All investments carry risk however SCP peer to peer investments are supported by a first mortgage registered against a piece of Real Estate. Better yet, you...

So, this is coming from "the_excerpt()". Is there any way to get this excerpt to display correctly? (i.e., "json_decode(the_excerpt)))" does nothing).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant