Wordpress Themes - WP Forum at BFA
Click Here To DONATE! Support the theme development, get more attention and additional benefits based on your donation level. Your forum name will be highlighted.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Header configuration & styling »

Add snippet of PHP code to header area (custom widgets)

Build custom WP THEMES, without
Click here for THEMEFRAME

From the author of Atahualpa, the #1 most
downloaded (700,000+) theme @ wordpress.org
Prev Previous Post   Next Post Next
Old Jan 29, 2012, 09:18 AM
81 posts · May 2009
Add snippet of PHP code to header area (custom widgets)

Hi all,

Quick question: where would I add a bit of PHP code that I want to appear in my header area? I have created a custom header area with 2 widget areas, and obviously I can't use PHP code in a widget. I tried looking at the theme files, but could not determine where I should put it.

Here is the code:

PHP Code:
<div id="btn-cart" class="fr">
<a href="<?php echo $woocommerce->cart->get_cart_url(); ?>" title="<?php _e('View your shopping cart''woothemes'); ?>">
echo sprintf(_n('%d item &ndash; ''%d items &ndash; '$woocommerce->cart->cart_contents_count'woothemes'), $woocommerce->cart->cart_contents_count);
And here is a link to my site: http://www.laurenacooper/AFAR

I would like for the cart information (code above) to be displayed between the search bar and the navigation bar in the header.

I'm using the most current version of WP and Atahualpa, and Woocommerce as my shopping cart.

Any help is greatly appreciated

Last edited by crashley1784; Jan 29, 2012 at 09:19 AM. Reason: Forgot to add something


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Google Analytics Code Snippet Not Being Recognized seo coach New Versions, & Updating 4 Jan 21, 2011 04:28 PM
Where to post code snippet for Google Analytics with this theme? sjolyjuly Atahualpa 3 Wordpress theme 17 Oct 28, 2010 09:15 PM
[SOLVED] problem stacking custom widgets in header area Thomas Sidebars & Widgets 7 Jul 6, 2010 12:01 PM
[SOLVED] How to Add Code Snippet at Bottom of Posts LaneLester Center area post/pages 0 May 16, 2010 06:21 PM
Aweber Autoresponder - how to add snippet code to wordpress theme racingprofits Sidebars & Widgets 0 Aug 24, 2009 12:02 PM

All times are GMT -6. The time now is 03:52 PM.

Powered by vBulletin® Copyright ©2000 - 2016, Jelsoft Enterprises Ltd.