I created a site where portfolio entries are used as searchable and sortable gallery entries.
The entries contain only title and featured image.
The entries are displayed in sortable Masonry grid, and everything works OK. However, when I use search (ajax or normal), and click on result, I get cropped image, and no title (and no content, as there shouldn’t be any).
What I would like to add is title above the image, and show resized but non-cropped image.
Hey MORTULGAAH,
Could you please give us a link to your website, we need more context to be able to help you.
Could you please attach some screenshots of the issue?
Best regards,
Victoria
I think I managed to solve the issue.
I added:
<h1><?php /**************************** TITLE OUTPUT ****************************/echo esc_html( get_the_title() ); ?></h1>
after:
<div class="entry-content-wrapper clearfix">
And changed crop ratio in functions.php:
$avia_config['imgSize']['entry_with_sidebar'] = array('width'=>845, 'height'=>563 );
-> second value, to adjust to page size.
Is all this OK? Will ti break something?
Hi,
Great, I’m glad you found a solution and thanks for sharing. If you don’t mind changing that image size globally then I don’t see any problems with your solution.
Best regards,
Rikard
I think you can close this thread, it is successfully solved.
Hi MORTULGAAH,
Glad to hear that :)
Thanks for using Enfold and have a great day!
Best regards,
Nikko