Hey guys,
I am having an issue on my current development site. I am using a shopping cart plugin that pulls the wp-login.php file as an include.. this allows users to log in to the site while maintaining the header navigation, footer and sidebars etc.
the issue im running into is that i am using $wpdb class to create my customised navigation.. using this call every page seems to work great, other than the wp-login.php page.
The error i get says
Notice: Undefined variable: wpdb in /wp-content/themes/shopperpress/header.php on line 230
Fatal error: Call to a member function get_col() on a non-object in /wp-content/themes/shopperpress/header.php on line 230
line 230 starts
$nav_item = $wpdb->get_col("SELECT post_title FROM <code>wp_posts</code> WHERE post_type='page' AND post_status ='publish' AND post_parent =0");
is there an action hook i can implement in the functions.php that will allow me to keep my $wpdb call even on the wp-login.php page?
Thanks so much
James