Hi
I have two log errors
Undefined variable: cat_id in /oc-content/themes/modern/inc.main.php on line 29
Undefined variable: path in /oc-content/themes/modern/search.php on line 376
I do not know what to change below:
---inc.main.php on line 29
<div class="category">
<h1><strong><span class="category <?php echo osc_category_slug() ; ?>"></span><a href="<?php echo osc_search_category_url() ; ?>"><?php echo osc_category_name() ; ?></a><img style="float:right;" src="<?php echo osc_current_web_theme_url('images/plus.png') ; ?>" alt="Collapsed" class="expand" id="plus_img<?php echo $cat_id; ?>" /> </strong></h1>
<?php if ( osc_count_subcategories() > 0 ) { ?>
<ul class="subcategory">
<?php while ( osc_has_subcategories() ) { ?>
<li><a class="category <?php echo osc_category_slug() ; ?>" href="<?php echo osc_search_category_url() ; ?>"><?php echo osc_category_name() ; ?></a> </li>
<?php } ?>
</ul>
<?php } ?>
</div>
------search.php on line 376
<script>$(document).ready(function() {
$("#sRegion").live("change",function(){ var pk_c_code = $(this).val(); <?php if($path=="admin") { ?> var url = '<?php echo osc_admin_base_url(true)."?page=ajax&action=cities®ionId="; ?>' + pk_c_code; <?php } else { ?> var url = '<?php echo osc_base_url(true)."?page=ajax&action=cities®ionId="; ?>' + pk_c_code; <?php }; ?> var result = ''; if(pk_c_code != '') { $("#sCity").attr('disabled',false); $.ajax({ type: "GET", url: url, dataType: 'json', success: function(data){ var length = data.length; if(length > 0) { result += '<option selected value=""><?php _e("Select a city..."); ?></option>'; for(key in data) { result += '<option value="' + data[key].pk_i_id + '">' + data[key].s_name + '</option>'; } $("#city").before('<select name="sCity" id="sCity" ></select>'); $("#city").remove(); } else { result += '<option value=""><?php _e('No results') ?></option>'; $("#sCity").before('<input type="text" name="city" id="city" />'); $("#sCity").remove(); } $("#sCity").html(result); } }); } else { $("#sCity").attr('disabled',true); } }); if( $("#sRegion").attr('value') == "") { $("#sCity").attr('disabled',true); } });
</script>