Problems don't know where to start
-
Hi
I have got a couple of sites running wordpress, I can only use 1 template which is supplied by the company that supply the service I use.
I am having problems running certain plugins, when I activate wBounce the wordpress admin bar disappears, wBounce appears to run correctly. Add Meta tags and To Top won’t work at all. I have tried a lot of plugins to numerous to mention. I have contacted the template authors and they tell me there is nothing wrong with the php coding, but they do admit that there is a problem somewhere but they can’t find it.
This is the error report when I turned on debugging from a fresh install I put online just to test it
Notice: Undefined index: post_id in /var/www/vhosts/thechineseconnection.co.uk/httpdocs/wp-content/themes/icodes/header.php on line 3 Notice: Undefined index: icid in /var/www/vhosts/thechineseconnection.co.uk/httpdocs/wp-content/themes/icodes/header.php on line 4 Notice: Undefined index: s in /var/www/vhosts/thechineseconnection.co.uk/httpdocs/wp-content/themes/icodes/header.php on line 7 Notice: Trying to get property of non-object in /var/www/vhosts/thechineseconnection.co.uk/httpdocs/wp-content/themes/icodes/header.php on line 11 Notice: Undefined variable: logoSize in /var/www/vhosts/thechineseconnection.co.uk/httpdocs/wp-content/themes/icodes/header.php on line 81 Notice: Undefined variable: shadow in /var/www/vhosts/thechineseconnection.co.uk/httpdocs/wp-content/themes/icodes/header.php on line 83When I showed them the error this was the response
“We looked at the coding and could not find anything obviously wrong, the line numbers shown in the errors above have no resemblance to what the line in the coding actually does.”
This is the coding in header.php
<?php include 'config.php'; $code_id=$_REQUEST['post_id']; $icid=$_REQUEST['icid']; $px="18"; $apx="10"; $s = $_REQUEST['s']; $search = get_search_query('search'); $slug = get_query_var('category_name'); $term = get_term_by( 'slug', $slug, 'category'); $catname=$term->name; ?> <html> <head> <script> function open_site(url) { window.open(url, '_blank'); } </script> <script type="text/javascript" language="JavaScript"> function HideContent(d) { document.getElementById(d).style.display = "none"; } function ShowContent(d) { document.getElementById(d).style.display = "inline"; } function ReverseDisplay(d) { if(document.getElementById(d).style.display == "none") { document.getElementById(d).style.display = "inline"; } else { document.getElementById(d).style.display = "none"; } } </script> <link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>"> <meta charset="<?php bloginfo( 'charset' ); ?>"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <script src="http://code.jquery.com/jquery-latest.min.js" type="text/javascript"></script> <meta name="viewport" content="width=device-width, initial-scale=1"> <?php $body_color=get_background_color(); $background_image=get_background_image(); $header_image=get_theme_mod('header-upload'); $header_background_color=get_theme_mod('header-background-color'); $mainmenu_background_color=get_theme_mod('mainmenu-background-color'); $mainmenu_text_color=get_theme_mod('mainmenu-text-color'); $mainmenu_highlight_color=get_theme_mod('mainmenu-highlight-color'); $submenubar_text_color=get_theme_mod('submenubar-text-color'); $submenubar_color=get_theme_mod('submenubar-color'); $logo=get_theme_mod('img-upload'); $logo_placement=get_theme_mod('logo_placement'); $page_color=get_theme_mod('page-color'); $footer_background_color=get_theme_mod('footer-background-color'); $footer_text_color=get_theme_mod('footer-text-color'); $sidebar_text_color=get_theme_mod('sidebar-text-color'); $header_text_color=get_theme_mod('header-text-color'); $shadow_color=get_theme_mod('shadow-color'); $content_box_color=get_theme_mod('content-box-color'); $content_box_text_color=get_theme_mod('content-box-text-color'); $content_box_highlight_color=get_theme_mod('content-box-highlight-color'); $sidebar_heading_text_color=get_theme_mod('sidebar-heading-text-color'); $sidebar_heading_color=get_theme_mod('sidebar-heading-color'); $content_heading_text_color=get_theme_mod('content-heading-text-color'); $content_heading_color=get_theme_mod('content-heading-color'); $search_box_color=get_theme_mod('search-box-color'); $content_text_color=get_theme_mod('content-text-color'); $sidebar_page_color=get_theme_mod('sidebar-page-color'); $site_description = get_bloginfo( 'description' ); $site_name = get_bloginfo( 'name' ); $logoSize = get_option('icsmpl_logoSize', $logoSize); $shadow = get_option('icsmpl_shadow', $shadow); $margin=$logoSize+16; if($header_background_color==""){$header_background_color="#347baf";} if($mainmenu_background_color==""){$mainmenu_background_color="#2a628c";} if($mainmenu_text_color==""){$mainmenu_text_color="#ffffff";} if($mainmenu_highlight_color==""){$mainmenu_highlight_color="#347baf";} if($submenubar_text_color==""){$submenubar_text_color="#ffffff";} if($submenubar_color==""){$submenubar_color="#2a628c";} if($page_color==""){$page_color="#f7f7f7";} if($footer_background_color==""){$footer_background_color="#262626";} if($footer_text_color==""){$footer_text_color="#ffffff";} if($body_color==""){$body_color="#ffffff";} if($sidebar_text_color==""){$sidebar_text_color="#000000";} if($header_text_color==""){$header_text_color="#ffffff";} if($shadow_color==""){$shadow_color="#808080";} if($logo_placement==""){$logo_placement="left";} if($background_image){$body_color="";} if($header_image){$header_background_color="";} if($sidebar_heading_text_color==""){$sidebar_heading_text_color="#000000";} if($sidebar_heading_color==""){$sidebar_heading_color="#e5e5e5";} if($content_heading_text_color==""){$content_heading_text_color="#000000";} if($content_heading_color==""){$content_heading_color="#e5e5e5";} if($content_text_color==""){$content_text_color="#000000";} if($sidebar_page_color==""){$sidebar_page_color="#f7f7f7";} if($content_box_highlight_color==""){$content_box_highlight_color="#d1d1d1";} if($content_box_color==""){$content_box_color="#e5e5e5";} if($content_box_text_color==""){$content_box_text_color="#000000";} if($search_box_color==""){$search_box_color="#e5e5e5";} if($shadow=="off"){$shadow_color="off";} if($code_id or $icid){ $region = get_option('icsmpl_region', $region); $username = get_option('icsmpl_username', $username); $subid = get_option('icsmpl_subid', $subid); if($region==""){$region="United Kingdom";} if($region=="United Kingdom"){$reg_url="icodes.co.uk/ws_plugin";} if($region=="United States"){$reg_url="icodes-us.com/ws_plugin";} if($region=="India"){$reg_url="icodes-in.com/ws_plugin";} $ch = curl_init(); $timeout = 0; // set to zero for no timeout curl_setopt ($ch, CURLOPT_URL, "http://webservices.$reg_url.php?UserName=$username&SubscriptionID=$subid&RequestType=Codes&Action=Icid&Query=$code_id,$icid&Sort=id&Page=$page&PageSize=$HomePageSize&Relationship=$relationship"); curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt ($ch, CURLOPT_CONNECTTIMEOUT, $timeout); $xml_raw = curl_exec($ch); $xml = simplexml_load_string($xml_raw); curl_close($ch); $total_items=trim($xml->Results); foreach ($xml->item as $item) { $title = $item->title; $merchant = $item->merchant; } } ?> <title> <?php if($code_id or $icid){ bloginfo('name'); echo " - "; echo urldecode(str_replace("-"," ",$title)); } elseif($search>"") { bloginfo('name'); echo " - "; echo wp_specialchars($search); echo" Codes and Offers"; } elseif($catname>"") { bloginfo('name'); echo " - "; echo "$catname"; } elseif(is_page()){ bloginfo('name'); echo " - "; the_title();} elseif(is_single()){ the_title(); echo " - "; bloginfo('name'); } else{ bloginfo('name'); } /* * Print the <title> tag based on what is being viewed. */ global $page, $paged; // Add a page number if necessary: if ( $paged >= 2 || $page >= 2 ) echo ' - ' . sprintf( __( 'Page %s', 'shape' ), max( $paged, $page ) ); ?> </title> <style> <?php include 'stylesheet.php'; ?> </style> <?php wp_head(); ?> </head> <body> <div id="wrapper"> <div id="menubar"> <?php $args = array( 'depth' => 0, 'sort_column' => 'menu_order, post_title', 'menu_class' => 'navmenu', 'include' => '', 'exclude' => '', 'echo' => true, 'show_home' => false, 'link_before' => '', 'link_after' => '' ); $defaults = array( 'theme_location' => '', 'menu' => '', 'container' => 'div', 'container_class' => 'navmenu', 'container_id' => '', 'menu_class' => 'navmenu', 'menu_id' => '', 'echo' => true, 'fallback_cb' => 'wp_page_menu', 'before' => '', 'after' => '', 'link_before' => '', 'link_after' => '', 'items_wrap' => '<ul id="%1$s" class="%2$s">%3$s</ul>', 'depth' => 0, 'walker' => '' ); ?> <a href="javascript:toggleDiv('myContent');" style="float: right; margin-right: 16px; margin-top: 6px; margin-bottom: 4px;"><div id="catlines";></div></a> <?php wp_nav_menu( $defaults ); ?> </div> <div id="header"> <?php include 'searchform.php'; if($logo){echo'<a href="'.$siteUrl.'"><img src="'.$logo.'" style="float: '.$logo_placement.';padding-right: 24px;"></a>';} else{echo'<div><a href="'.$siteUrl.'" style="color: '.$header_text_color.'; font-size: 32px; padding-right: 24px; float: '.$logo_placement.';">'.$site_name.'</a></div>'; echo'<div style="color: '.$header_text_color.'; font-size: 16px; padding-right: 24px; clear: '.$logo_placement.'; float: '.$logo_placement.';">'.$site_description.'</div>'; } ?> <div id="header_sidebar"> <?php// wp_page_menu($args); ?> </div> </div> <?php include 'sidebarLeft.php'; ?> <div id="header2"> <?php if(is_page( 'Home' )){ if(is_active_sidebar('homepage-header')){ dynamic_sidebar('homepage-header'); } } if(!is_page( 'Home' )){ if(is_active_sidebar('header-area')){ dynamic_sidebar('header-area'); } } ?> </div> <div> </div>The test site I put up is http://www.thechineseconnection.co.uk
I don’t know if the information I have given is enough for anybody to respond.
Any help would be appreciated.
Thanks
Mike
The topic ‘Problems don't know where to start’ is closed to new replies.