Creating duplicate of search.php archive template

Posted in: Newsmag
Post count: 2

Hi
I am trying to create a template for my search&filter plugin to use for displaying results. I duplicated the search.php template and it works with the plugin. But I have three different types of search so i need three different templates with three different sidebars. So I need to be able to control from the them panel.

My problem is I am not able to get it to work. the display view and the sidebar do not change when i change in the theme panel only thin that works is the sidebar position. I will appreciate your help inb sorting this out.

I added this example code to the /includes/wp_booster/wp-admin/panel/views/td_panel_template_settings.php
<!-- Resource Search page -->
<?php echo td_panel_generator::box_start('Resource Search template', false); ?>

<div class="td-box-description td-box-full">
<p>Select the layout for the search page.</p>

</div>

<!-- DISPLAY VIEW -->
<div class="td-box-row">
<div class="td-box-description">
<span class="td-box-title">ARTICLE DISPLAY VIEW</span>
<p>Select a module type, this is how your article list will be displayed</p>
</div>
<div class="td-box-control-full td-panel-module">
<?php
echo td_panel_generator::visual_select_o(array(
'ds' => 'td_option',
'option_id' => 'tds_search_page_layout',
'values' => td_panel_generator::helper_display_modules('enabled_on_loops')
));
?>
</div>
</div>

<!-- Custom Sidebar + position -->
<div class="td-box-row">
<div class="td-box-description">
<span class="td-box-title">CUSTOM SIDEBAR + POSITION</span>
<p>Sidebar position and custom sidebars</p>
</div>
<div class="td-box-control-full td-panel-sidebar-pos">
<div class="td-display-inline-block">
<?php
echo td_panel_generator::visual_select_o(array(
'ds' => 'td_option',
'option_id' => 'tds_resource_sidebar_pos',
'values' => array(
array('text' => '', 'title' => '', 'val' => 'sidebar_left', 'img' => get_template_directory_uri() . '/images/panel/sidebar/sidebar-left.png'),
array('text' => '', 'title' => '', 'val' => 'no_sidebar', 'img' => get_template_directory_uri() . '/images/panel/sidebar/sidebar-full.png'),
array('text' => '', 'title' => '', 'val' => '', 'img' => get_template_directory_uri() . '/images/panel/sidebar/sidebar-right.png')
)
));
?>
<div class="td-panel-control-comment td-text-align-right">Select sidebar position</div>
</div>
<div class="td-display-inline-block td_sidebars_pulldown_align">
<?php
echo td_panel_generator::sidebar_pulldown(array(
'ds' => 'td_option',
'option_id' => 'tds_resource_sidebar'
));
?>
<div class="td-panel-control-comment td-text-align-right">Create or select an existing sidebar</div>
</div>
</div>
</div>
<?php echo td_panel_generator::box_end();?>

Post count: 23312

Hello aanakwue,

Notice that as you want to achieve involves doing such a custom work and we cannot provide support for this, sorry! You should try to do it yourself, considering the example of search template. If you are not aware of the steps which are needed to take in this case, please consider hiring a freelancer/developer to help you!

Thanks for your understanding!

Viewing 2 posts - 1 through 2 (of 2 total)
The forum ‘Newsmag’ is closed to new topics and replies.