registering and calling sidebar for shopping cart
-
So. This is all started with needing to add a shopping cart to the products page. I downloaded the WP Ultra Simple Paypal shopping cart and installed, then added it to the primary widget. It doesn’t show up so I tried changed only the products page from the single column, no sidebar template to the default template. Still no luck. I did a little searching in the editor found this in the style.css:
-------------------------------------------------------------- */ /* LAYOUT: Two columns DESCRIPTION: Two-column fixed layout with one sidebar right of content */ #container { float: left; margin: 0 -240px 0 0; width: 100%; } #content { margin: 0 280px 0 20px; } .blog #content { margin:0; } body.home.page #main{ padding-top:25px; } #primary, #secondary { float: right; overflow: hidden; width: 220px; } #secondary { clear: right; } #footer { border-top: 1px solid #CCC; margin-top: 5px; clear: both; width: 100%; background-color:#EEE; } #footer { text-shadow: 1px 1px 0px white; } #credits { text-align:center; } #footer #credits a { font-size:11px; font-weight:bold; color:#06C; } #footer .widget-title { color:#888; margin-left: 1.3em; } /* LAYOUT: One column, no sidebar DESCRIPTION: One centered column with no sidebar */ .one-column #content { margin: 0 auto; width: 640px; } /* LAYOUT: Full width, no sidebar DESCRIPTION: Full width content with no sidebar; used for attachment pages */ .single-attachment #content { margin: 0 auto; width: 900px; }
and this is in the theme functions.php:
/** * Register widgetized areas, including two sidebars and four widget-ready columns in the footer. * * To override photolistic_widgets_init() in a child theme, remove the action hook and add your own * function tied to the init hook. * * @since Photolistic 1.0 * @uses register_sidebar */ function photolistic_widgets_init() { // Area 1, located at the top of the sidebar. register_sidebar( array( 'name' => __( 'Primary Widget Area', 'photolistic' ), 'id' => 'primary-widget-area', 'description' => __( 'The primary widget area', 'photolistic' ), 'before_widget' => '<li id="%1$s" class="widget-container %2$s">', 'after_widget' => '</li>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ) ); // Area 2, located below the Primary Widget Area in the sidebar. Empty by default. register_sidebar( array( 'name' => __( 'Secondary Widget Area', 'photolistic' ), 'id' => 'secondary-widget-area', 'description' => __( 'The secondary widget area', 'photolistic' ), 'before_widget' => '<li id="%1$s" class="widget-container %2$s">', 'after_widget' => '</li>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ) ); // Area 3, located in the footer. Empty by default. register_sidebar( array( 'name' => __( 'First Footer Widget Area', 'photolistic' ), 'id' => 'first-footer-widget-area', 'description' => __( 'The first footer widget area', 'photolistic' ), 'before_widget' => '<li id="%1$s" class="widget-container %2$s">', 'after_widget' => '</li>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ) ); // Area 4, located in the footer. Empty by default. register_sidebar( array( 'name' => __( 'Second Footer Widget Area', 'photolistic' ), 'id' => 'second-footer-widget-area', 'description' => __( 'The second footer widget area', 'photolistic' ), 'before_widget' => '<li id="%1$s" class="widget-container %2$s">', 'after_widget' => '</li>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ) ); // Area 5, located in the footer. Empty by default. register_sidebar( array( 'name' => __( 'Third Footer Widget Area', 'photolistic' ), 'id' => 'third-footer-widget-area', 'description' => __( 'The third footer widget area', 'photolistic' ), 'before_widget' => '<li id="%1$s" class="widget-container %2$s">', 'after_widget' => '</li>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ) ); // Area 6, located in the footer. Empty by default. register_sidebar( array( 'name' => __( 'Fourth Footer Widget Area', 'photolistic' ), 'id' => 'fourth-footer-widget-area', 'description' => __( 'The fourth footer widget area', 'photolistic' ), 'before_widget' => '<li id="%1$s" class="widget-container %2$s">', 'after_widget' => '</li>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ) ); } /** Register sidebars by running photolistic_widgets_init() on the widgets_init hook. */ add_action( 'widgets_init', 'photolistic_widgets_init' );
the sidebar.php is there but is blank.
So I emailed our “website guy” and asked how to register and call the shopping cart and his response is “This template doesn’t come with a child theme for a sidebar so you would need to create it and takes alot of time unless you know PHP.”
WOW ok thanks. I did a lot of googling and found many tutorials but I don’t want to screw up the whole page.
Can anyone help with this or direct me to a “sidebars for dummies” page???
Here is the site:’ usscarneyfrg.com ‘
Not sure if this helps but all the post are pages and the main/front page is static.
If there is an easier way to do this PLEASE feel free to say.
Regards
Meredith
- The topic ‘registering and calling sidebar for shopping cart’ is closed to new replies.