Recent post shortcode, throwing error on search page

Error:

Notice: Trying to get property of non-object in /wp-content/themes/pro/framework/functions/portfolio.php on line 411

only on search page. https://ww1.globalmarshallplan.org/?s=test

I am using the code below to sort posts:
[recent_posts count=“1” orientation=“horizontal”][recent_posts count=“2” orientation=“horizontal” offset=“1”][recent_posts count=“2” orientation=“horizontal” offset=“3”]

using latest version of pro

Hello @Sagarari,

Thanks for writing in! You are seeing a PHP notices. and there is nothing to worry about. This usually appears when a certain variable is not initialized or being set to null. To get rid of this message, you will need to disable the debug mode. You can do this by opening wp-config.php and adding


define('WP_DEBUG', false);

/* That's all, stop editing! Happy blogging. */

When you revisit the page, you should no longer be seeing those PHP notices.

Please let us know how it goes.

Thanks that worked.

Another issue:
On page: https://ww1.globalmarshallplan.org/news/

How do i make the posts boxes and featured pictures same height.

I was able to remove the border outside image, and remove the icon before name, but this one, no idea.

Hello Sagar,

Thanks for asking. :slight_smile:

Can you please confirm the URL as on visiting the URL I am getting 404 error. Please confirm the URL for us to take a closer look.

Thanks.

Hi, Sorry migrated to www the same day.

Thanks

Hi Sagar,

I checked and can see that you are using Masonry Layout.

Please note that Masonry works by placing elements in optimal position based on available vertical space, sort of like a mason fitting stones in a wall. Unlike other grid layouts, it doesn’t have fixed height rows.

You can try adding a min height by adding the code below in Theme Options > CSS

body .x-iso-container>.hentry {
    min-height: 600px;
}

For more information kindly refer to the link below.

Thanks

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.