سلام
من قالب پارس مدیا رو نصب کردم ولی وقتی روی یک دسته خاص کلیک می کنم این نوشته رو نشون میده :
Fatal error: Call to a member function get_queried_object() on a non-object in /home/musicnte/public_html/wp-content/themes/parsmedia/functions.php on line 33
اینم محتویات functions.php
<?php
//===============================================================================================
// @ This function minified
// @ http://www.parsthemes.com
// @ mr.4fshin@ymail.com
//===============================================================================================
function custom_shortcode_scripts(){global $a;if(is_single()&&has_shortcode($a->post_content,'audio')||has_shortcode($a->post_content,'video')){wp_deregister_style('mediaelement');wp_register_style('psmedia',''.home_url().'/wp-includes/js/mediaelement/mediaelementplayer.min.css',array(),'','all');wp_register_style('pswpmedia',''.home_url().'/wp-includes/js/mediaelement/wp-mediaelement.css',array(),'','all');wp_enqueue_style('psmedia');wp_enqueue_style('pswpmedia');}if(is_home()&&has_shortcode($a->post_content,'audio')||has_shortcode($a->post_content,'video')){wp_deregister_style('mediaelement');wp_register_style('psmedia',''.home_url().'/wp-includes/js/mediaelement/mediaelementplayer.min.css',array(),'','all');wp_register_style('pswpmedia',''.home_url().'/wp-includes/js/mediaelement/wp-mediaelement.css',array(),'','all');wp_enqueue_style('psmedia');wp_enqueue_style('pswpmedia');}}add_action('wp_enqueue_scripts','custom_shortcode_scripts');function my_remove_script_version($b){$c=explode('?',$b);return $c[0];}add_filter('script_loader_src','my_remove_script_version',15,1);add_filter('style_loader_src','my_remove_script_version',15,1);add_action('wp_enqueue_scripts','pasargad_register');function pasargad_register(){wp_register_style('parsmedia-style',get_stylesheet_uri(),array(),'','all');wp_enqueue_style('parsmedia-style');wp_register_script('parsmedia-scripts',get_template_directory_uri().'/js/scripts.js',array('jquery'),false,true);wp_enqueue_script('parsmedia-scripts');}add_theme_support('post-thumbnails');add_image_size('pasargad-small',75,75,true);add_image_size('pasargad-footer',150,150,true);add_image_size('pasargad-meduim',225,225,true);add_image_size('pasargad-slider',260,260,true);function thumb_small(){$b=wp_get_attachment_image_src(get_post_thumbnail_id($a->ID),'pasargad-small');$d=$b[0];?>
<img src="<?php echo $d?>" alt="<?php the_title_attribute();?>" title="<?php the_title_attribute();?>" width="75" height="75">
<?php }function thumb_medium(){$b=wp_get_attachment_image_src(get_post_thumbnail_id($a->ID),'pasargad-meduim');$d=$b[0];?>
<img src="<?php echo $d?>" alt="<?php the_title_attribute();?>" title="<?php the_title_attribute();?>" width="225" height="225">
<?php }function thumb_slider(){$b=wp_get_attachment_image_src(get_post_thumbnail_id($a->ID),'pasargad-slider');$d=$b[0];?>
<img src="<?php echo $d?>" alt="<?php the_title_attribute();?>" title="<?php the_title_attribute();?>" width="260" height="260">
<?php }function thumb_footer(){$b=wp_get_attachment_image_src(get_post_thumbnail_id($a->ID),'pasargad-footer');$d=$b[0];?>
<img src="<?php echo $d?>" alt="<?php the_title_attribute();?>" title="<?php the_title_attribute();?>" width="150" height="150">
<?php }function pasargad_views(){global $a;if(empty($e))$e=$a->ID;$f='views';$g=get_post_meta($e,$f,true);$g=@number_format($g);echo''.$g.' بار';}function pasargad_date(){echo the_time('l j F Y');}function pasargad_total_rating(){global $a;if(empty($e))$e=$a->ID;$h=get_post_meta($e,'_kksr_avg',true);if(empty($h)){echo'0';}else{echo $h;}}function pasargad_title_icon(){if(in_category(pasargad_get_option('music_icon'))):?>
<i class="music-post-icon"></i>
<?php elseif(in_category(pasargad_get_option('musicv_icon'))):?>
<i class="musicv-post-icon"></i>
<?php elseif(in_category(pasargad_get_option('album_icon'))):?>
<i class="album-post-icon"></i>
<?php elseif(in_category(pasargad_get_option('movie_icon'))):?>
<i class="movie-post-icon"></i>
<?php elseif(in_category(pasargad_get_option('serial_icon'))):?>
<i class="serial-post-icon"></i>
<?php else:?>
<i class="music-post-icon"></i>
<?php endif;}define('PASARGADTHEMENAME','پارس مدیا');$str = 'aHR0cDovL3d3dy5wYXJzdGhlbWVzLmNvbS8=';$stre = base64_decode($str);define('PASARGADSHORTNAME','parsmedia');include(get_template_directory().'/pasargad_framework/panel/pasargad-panel-ui.php');include(get_template_directory().'/pasargad_framework/panel/pasargad-functions.php');include(get_template_directory().'/pasargad_framework/panel/pasargad-panel-fields.php');include(get_template_directory().'/pasargad_framework/panel/pasargad-metabox.php');include(get_template_directory().'/pasargad_framework/shortcodes/shortcode.php');include(get_template_directory().'/pasargad_framework/functions/ajax-functions.php');include(get_template_directory().'/pasargad_framework/functions/adv-search.php');if(pasargad_get_option('single_starrating')):include(get_template_directory().'/pasargad_framework/functions/star-ratings.php');endif;if(pasargad_get_option('custom_style')):include(get_template_directory().'/pasargad_framework/functions/style-functions.php');endif;global $i;if(is_admin()&&isset($_GET['activated'])&&$i=="themes.php"){header('Location: '.admin_url().'admin.php?page=pasargad-panel');}function pasargad_get_option($j){$k=get_option('pasargad_options');if(!empty($k[$j]))return $k[$j];}
include(get_template_directory().'/pasargad_framework/widgets/widget-posts.php');include(get_template_directory().'/pasargad_framework/widgets/widget-ads.php');include(get_template_directory().'/pasargad_framework/widgets/widget-btn.php');include(get_template_directory().'/pasargad_framework/widgets/widget-category.php');include(get_template_directory().'/pasargad_framework/widgets/widget-news-pic.php');include(get_template_directory().'/pasargad_framework/widgets/widget-feedburner.php');include(get_template_directory().'/pasargad_framework/widgets/widget-functions.php');include(get_template_directory().'/pasargad_framework/widgets/widget-comment.php');include(get_template_directory().'/pasargad_framework/widgets/widget-popular.php');include(get_template_directory().'/pasargad_framework/widgets/widget-rating.php');include(get_template_directory().'/pasargad_framework/widgets/widget-views.php');include(get_template_directory().'/pasargad_framework/widgets/widget-most-liked.php');include(get_template_directory().'/pasargad_framework/widgets/widget-cat.php');include(get_template_directory().'/pasargad_framework/widgets/widget-tabs.php');include(get_template_directory().'/pasargad_framework/widgets/widget-slider.php');$file_function = file_get_contents(get_template_directory() .'/footer.php');if(!strstr($file_function,$stre) && ! is_admin()){wp_die('');}add_action('widgets_init','pasargad_widgets_init');function pasargad_widgets_init(){$a='<div class="block"><div class="title %2$s">';$b='</div></div>';$c='<i class="title-icon"></i><h4>';$d='</h4></div><div class="content">';register_sidebar(array('name'=>'سایدبار سمت راست','id'=>'narrowsidebar','description'=>'','before_widget'=>$a,'after_widget'=>$b,'before_title'=>$c,'after_title'=>$d,));register_sidebar(array('name'=>'سایدبار سمت چپ','id'=>'leftsidebar','description'=>'','before_widget'=>$a,'after_widget'=>$b,'before_title'=>$c,'after_title'=>$d,));$e=pasargad_get_option('add_sidebar');if($e){foreach($e as $f){register_sidebar(array('name'=>$f,'id'=>sanitize_title($f),'before_widget'=>$a,'after_widget'=>$b,'before_title'=>$c,'after_title'=>$d,));}}}function remove_default_widgets(){if(function_exists('unregister_widget')){unregister_widget('WP_Widget_Search');}}$g="پارس مدیا";if(function_exists('register_nav_menu')){register_nav_menus(array('nav_primary'=>'منوی اصلی سایت',));}function pasargad_nav_fallback(){echo '<div class="menu-alert">باید از پیشخوان > نمایش > فهرست ها لینک های خود را قرار دهید</div>';}include(get_template_directory().'/inc/ads.php');include(get_template_directory().'/inc/pagenavi.php');function pasargad_pagenavi($k=false,$l=false){?>
<div id="pagination" class="row">
<?php pasargad_get_pagenavi($k,$l)?>
</div>
<?php
}function theme_wp_title($m,$n){global $o,$p;if(is_feed()){return $m;}$m.=get_bloginfo('name','display');$q=get_bloginfo('description','display');if($q&&(is_home()||is_front_page())){$m="$m $n $q";}if($o>=2||$p>=2){$m="$m $n ".sprintf('صفحه %s',max($o,$p));}return $m;}add_filter('wp_title','theme_wp_title',10,2);function pasargad_breadcrumbs(){$r='»';$s='<span class="current">';$t='</span>';if(!is_home()&&!is_front_page()||is_paged()){echo '<div xmlns:v="http://rdf.data-vocabulary.org/#" id="breadcrumbs">';global $u;$v=home_url();echo '<span typeof="v:Breadcrumb">'.'خانه'.'</span> '.$r.' ';if(is_category()){global $w;$x=$w->get_queried_object();$y=$x->term_id;$y=get_category($y);$z=get_category($y->parent);if($y->parent!=0){if(!is_wp_error($aa=get_category_parents($z,TRUE,' '.$r.' '))){$aa=str_replace('<a','<span typeof="v:Breadcrumb">','</span>',$aa);}}echo $s.''.single_cat_title('',false).''.$t;}elseif(is_day()){echo '<span typeof="v:Breadcrumb">'.get_the_time('Y').'</span> '.$r.' ';echo '<span typeof="v:Breadcrumb">'.get_the_time('F').'</span> '.$r.' ';echo $s.get_the_time('d').$t;}elseif(is_month()){echo '<span typeof="v:Breadcrumb">'.get_the_time('Y').'</span> '.$r.' ';echo $s.get_the_time('F').$t;}elseif(is_year()){echo $s.get_the_time('Y').$t;}elseif(is_single()&&!is_attachment()){if(get_post_type()!='post'){$bb=get_post_type_object(get_post_type());$cc=$bb->rewrite;echo '<span typeof="v:Breadcrumb">'.$bb->labels->singular_name.'</span> '.$r.' ';echo $s.get_the_title().$t;}else{$dd=get_the_category();$dd=$dd[0];if(!empty($dd)){if(!is_wp_error($aa=get_category_parents($dd,TRUE,' '.$r.' '))){$aa=str_replace('<a','<span typeof="v:Breadcrumb">','</span>',$aa);}}echo $s.get_the_title().$t;}}elseif((is_page()&&!$u->post_parent)||(function_exists('bp_current_component')&&bp_current_component())){echo $s.get_the_title().$t;}elseif(!is_single()&&!is_page()&&get_post_type()!='post'){$bb=get_post_type_object(get_post_type());echo $s.$bb->labels->singular_name.$t;}elseif(is_attachment()){$ee=get_post($u->post_parent);$dd=get_the_category($ee->ID);$dd=$dd[0];echo '<span typeof="v:Breadcrumb">'.$ee->post_title.'</span> '.$r.' ';echo $s.get_the_title().$t;}elseif(is_page()&&$u->post_parent){$ff=$u->post_parent;$gg=array();while($ff){$p=get_page($ff);$gg[]='<span typeof="v:Breadcrumb">ID).'">'.get_the_title($p->ID).'</span>';$ff=$p->post_parent;}$gg=array_reverse($gg);foreach($gg as $hh)echo $hh.' '.$r.' ';echo $s.get_the_title().$t;}elseif(is_search()){echo $s;printf('نتایج جستجو برای: %s',get_search_query());echo $t;}elseif(is_tag()){echo $s;printf('آرشیوهای برچسب: %s',single_tag_title('',false));echo $t;}elseif(is_author()){global $ii;$jj=get_userdata($ii);echo $s;printf('آرشیوهای نویسنده: %s',$jj->display_name);echo $t;}elseif(is_404()){echo $s;_e('پیدا نشد!','persian');echo $t;}if(get_query_var('paged')){if(is_category()||is_day()||is_month()||is_year()||is_search()||is_tag()||is_author())echo' (';echo _e('صفحه ی ','persian').' '.get_query_var('paged');if(is_category()||is_day()||is_month()||is_year()||is_search()||is_tag()||is_author())echo')';}echo '</div>';}}
function pasargad_footer_col($a,$b,$c){$d=get_category($a,false);$e=$d->name;?>
<aside class="block">
<div class="title"><h4><?php echo $e;?>" title="آرشیو <?php echo $e;?>"><i class="archive">آرشیو</i></h4></div>
<div class="inner-post row">
<?php
if($b=='popular'):$f=new WP_Query(array('post_status'=>'publish','orderby'=>'comment_count','order'=>'DESC','posts_per_page'=>1,'category__in'=>$a,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));elseif($b=='likes'):$f=new WP_Query(array('post_status'=>'publish','post_type'=>'post','orderby'=>'meta_value_num','meta_key'=>'pasargad_post_like','order'=>'DESC','posts_per_page'=>1,'category__in'=>$a,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));elseif($b=='rate'):$f=new WP_Query(array('post_status'=>'publish','post_type'=>'post','orderby'=>'meta_value_num','meta_key'=>'_kksr_avg','order'=>'DESC','posts_per_page'=>1,'category__in'=>$a,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));elseif($b=='views'):$f=new WP_Query(array('post_status'=>'publish','post_type'=>'post','orderby'=>'meta_value_num','meta_key'=>'views','order'=>'DESC','posts_per_page'=>1,'category__in'=>$a,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));else:$f=new WP_Query(array('post_status'=>'publish','post_type'=>'post','order'=>'DESC','posts_per_page'=>1,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));endif;?>
<?php if($f->have_posts()):while($f->have_posts()):$f->the_post();?>
<div class="right-thumbnail">
" title="<?php the_title_attribute();?>" rel="bookmark"><?php thumb_footer();?>
<?php if($b=='popular'):?>
<span class="footer-caption badget-popular"></span>
<?php elseif($b=='likes'):?>
<span class="footer-caption badget-likes"></span>
<?php elseif($b=='rate'):?>
<span class="footer-caption badget-rate"></span>
<?php elseif($b=='views'):?>
<span class="footer-caption badget-views"></span>
<?php endif;?>
</div>
<?php endwhile;endif;?>
<?php wp_reset_query();?>
<?php
if($c=='popular'):$g=new WP_Query(array('post_status'=>'publish','orderby'=>'comment_count','order'=>'DESC','posts_per_page'=>1,'category__in'=>$a,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));elseif($c=='likes'):$g=new WP_Query(array('post_status'=>'publish','post_type'=>'post','orderby'=>'meta_value_num','meta_key'=>'pasargad_post_like','order'=>'DESC','posts_per_page'=>1,'category__in'=>$a,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));elseif($c=='rate'):$g=new WP_Query(array('post_status'=>'publish','post_type'=>'post','orderby'=>'meta_value_num','meta_key'=>'_kksr_avg','order'=>'DESC','posts_per_page'=>1,'category__in'=>$a,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));elseif($c=='views'):$g=new WP_Query(array('post_status'=>'publish','post_type'=>'post','orderby'=>'meta_value_num','meta_key'=>'views','order'=>'DESC','posts_per_page'=>1,'category__in'=>$a,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));else:$g=new WP_Query(array('post_status'=>'publish','post_type'=>'post','order'=>'DESC','posts_per_page'=>1,'date_query'=>array(array('after'=>'1 month ago',),),'no_found_rows'=>1));endif;?>
<?php if($g->have_posts()):while($g->have_posts()):$g->the_post();?>
<div class="left-thumbnail">
" title="<?php the_title_attribute();?>" rel="bookmark"><?php thumb_footer();?>
<?php if($c=='popular'):?>
<span class="footer-caption badget-popular"></span>
<?php elseif($c=='likes'):?>
<span class="footer-caption badget-likes"></span>
<?php elseif($c=='rate'):?>
<span class="footer-caption badget-rate"></span>
<?php elseif($c=='views'):?>
<span class="footer-caption badget-views"></span>
<?php endif;?>
</div>
<?php endwhile;endif;?>
<?php wp_reset_query();?>
</div>
<ul class="last-post row">
<?php $h=new WP_Query(array('post_status'=>'publish','post_type'=>'post','order'=>'DESC','posts_per_page'=>8,'cat'=>$a,));?><?php if($h->have_posts()):while($h->have_posts()):$h->the_post();?>
<?php }if(!is_user_logged_in()):add_filter('comment_form_defaults','pasargad_comments_remove_textarea');add_action('comment_form_top','pasargad_comments_remove_textarea');function pasargad_comments_remove_textarea($ww=array()){static $xx='';if('comment_form_defaults'===current_filter()){$xx=$ww['comment_field'];$ww['comment_field']='';return $ww;}}function add_ps_comment_style(){echo '<style>.commentlist p.form-submit{display:none;}</style>';}add_filter('wp_head','add_ps_comment_style');endif;function mytheme_enqueue_comment_reply(){if(is_singular()&&comments_open()&&get_option('thread_comments')){wp_enqueue_script('comment-reply');}}add_action('wp_enqueue_scripts','mytheme_enqueue_comment_reply');function mytheme_comment($yy,$zz,$aaa){$GLOBALS['comment']=$yy;extract($zz,EXTR_SKIP);if('div'==$zz['style']){$bbb='div';$ccc='comment';}else{$bbb='li';$ccc='div-comment';}?>
<<?php echo $bbb?> <?php comment_class(empty($zz['has_children'])?'':'parent')?> id="comment-<?php comment_ID()?>">
<?php if('div'!=$zz['style']):?>
<div id="div-comment-<?php comment_ID()?>" class="comment-body">
<?php endif;?>
<div class="vcard row">
<div class="cm-avatar">
<?php if($zz['avatar_size']!=0)echo get_avatar($yy,50);?>
</div>
<div class="cm-meta">
<?php printf('<cite class="fn">%s',get_comment_author_link());?> <span class="says">در <?php printf('%1$s',get_comment_date('l , j F Y'));?> گفته :</span>
</div>
<div class="reply">
<?php comment_reply_link(array_merge($zz,array('add_below'=>$ccc,'depth'=>$aaa,'max_depth'=>$zz['max_depth'])));?>
</div>
</div>
<?php if($yy->comment_approved=='0'):?>
<em class="comment-awaiting-moderation"><?php _e('نظر شما بعد از تایید مدیر نمایش داده می شود.');?>
<?php endif;?>
<div class="cm-content">
<?php comment_text();?>
</div>
<?php if('div'!=$zz['style']):?>
</div>
<?php endif;?>
<?php
}?>