I'm new for OSClass. This code from oc-content\themes\modern\inc.search.php
,
<form action="<?php echo osc_base_url(true); ?>" method="get" class="search" onsubmit="javascript:return doSearch();">
<input type="hidden" name="page" value="search" />
<fieldset class="main">
<input type="text" name="sPattern" id="query" value="<?php echo osc_esc_html( ( osc_search_pattern() != '' ) ? osc_search_pattern() : $sQuery ); ?>" />
<?php if ( osc_count_categories() ) { ?>
<?php osc_categories_select('sCategory', null, __('Select a category', 'modern')); ?>
<?php } ?>
<button type="submit"><?php _e('Search', 'modern'); ?></button>
</fieldset>
<div id="search-example"></div>
</form>
Here, i need to add one more option to search. That is Place, same as #query. What can I do?
And where I can make change(s) for good work to this search?
I know following codes,
<input type="text" name="sCity" id="sCity" value="<?php _e('Enter your city here'); ?>" />
that's give the result like following,
But, My requirement is the sCity
is also same as sPattern
. See the value
in both. sPattern shows same result when redirect. but sCity wouldn't. I need that.