Skip Navigation

[Resolved] custom search layout

This support ticket is created 6 years, 4 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 4 replies, has 2 voices.

Last updated by manolisC 6 years, 4 months ago.

Assisted by: Christian Cox.

Author
Posts
#1126887
villasFilter.JPG

Hello i'm trying to make a custom search with view but i can't or i don't know how to make exactly the layout that i have from my designer (i have the html from disigner) i saw that i can insert in views the fields and the filters that i want as shortcodes how can i use the html that i have?

i want to make the layout you see in photo.

thanks in advance!

#1127060

Hi, Views does not provide much flexibility for search filter markup customization, unfortunately. For example, there is no ability to add or remove elements from the markup, modify CSS classes or tag attributes. You can add any custom CSS you want using the View's Search and Pagination CSS panel, and you can add any custom JavaScript you want as well. Other than CSS and JS, the output generated automatically by Views is not very customizable.

If you have access to a designer who knows HTML, CSS and JavaScript you can place the search filters on a custom page and give the designer a link to that page. S/he should be able to inspect the markup of the search form and tell you what is possible, or how close to the original design you can get with Views without modifing that code template. Note that Views does not offer a sliding range filter as shown here. That would require additional custom code.

#1127313

OK with that, so we suppose with one way or another i have a view with custom filters, i want that view to load at homepage but the results want to be to another page, i'm loading the view with this code at my custom php homepage template: <?php
$args = array('id'=>76);
echo (render_view($args)); ?>
is there a way to tell the view results to load to another page?
i saw from your tutorials that this is posible if you load the view within a page or widget, is this posible if i load the view with custom code in my php code?

#1127495

No I think you would have to call do_shortcode() on the wpv-form-view shortcode. I would insert the View in a custom Page using the wp-admin GUI, where you can select the page where the results should appear. Then cut that generated shortcode and paste it into your PHP template. Echo the results like this:

echo do_shortcode( '[wpv-form-view ... ]'); 
#1128281

I will try it Thank you for your help!