Navigation
This is archived content. Visit our new forum.
  • Author
    Posts
  • #82295

    Zach W
    Participant

    Hi there-

    I am making an e-ccomerce site with WooCommerce. I want the “my account” and “cart” pages in the top bar instead of the menu. My Url is zachswebdesigns.com but I am building on someone else’s website. Do I just add the shortcode? I know you can add a “cart” widget but I want it like this website: https://www.websimian.co.uk

    Can you help? Thanks!!!

    #82300

    Mrinal
    Member

    Hi Zach,

    Please follow the steps below:

    1) At first create a menu via WP Admin > Menus which you wanna show in top bar .

    2) Now, Please install & activate this plugin: https://wordpress.org/plugins/shortcode-menu/

    3) Then go to this plugin settings page, get the shortcode for top bar menu.

    4) Place the shortcode you got from step no. 3 in topbar content area via Customizer > Header.

    The shortcode won’t be outputed & will show as plain text.

    5) Create a child theme by following this KB: http://theme.co/x/member/kb/how-to-setup-child-themes/

    6) Now, open the functions.php file of child theme & add the following codes into it:

    add_filter('option_x_topbar_content','x_topbar_do_shortcode');
    
    function x_topbar_do_shortcode($content) {
     return do_shortcode( $content );
    }

    7) You’re done, see the result in Topbar with a custom menu.

    Hope this helps, Cheers!

    #82434

    Zach W
    Participant

    Hi there-

    Thanks so much! One question: where is the functions.php of the child theme?

    #82466

    Kosher K
    Member

    Hi Zack,

    the functions.php is located in child theme root directory,

    e.g. x-child-ethos/functions.php

    If you activate any child theme, then browse WordPress Admin -> Appearance -> Editor,

    you can see the functions.php in the right side of the editor.

    Hope that helps.

    Cheers

    #84190

    Sarah E
    Participant

    Hi, I want this setup for my top bar too. I followed all your advice above, installed the plugin and have managed to get the topbar to show but i’m having trouble with styling.

    I want to remove the social icons and then right align the menu items.
    I found this code on other posts and have pasted both in to customizer/custom but to no effect, i assume because i’m using the shortcode plugin above. Can you help me out?

    .x-topbar .x-social-global {
       display: none;
    }}
    .x-topbar .p-info {
    text-align:center;
    float:none;
    }

    I also love the “0 items cart icon in the web simian example but can’t find a way to do that.

    I would also really like to put “login/logout” buttons on the top bar, similar to what you have here on this forum page. I notice Woo have this on their site too, yet i don’t seem to be able to work out how to do it.

    #84191

    Sarah E
    Participant
    This reply has been marked as private.
    #84223

    Paula S
    Member
    This reply has been marked as private.
    #84329

    Sarah E
    Participant
    This reply has been marked as private.
    #84333

    Paul R
    Moderator

    Hi Sarah,

    This was our reply
    ———
    Thanks for the information. I’ve been getting a 404 error when accessing your website at the moment, and I’ve tried on Chrome and Firefox. Let us know if it’s up and we’ll inspect then.

    Update: Not getting errors now but is showing a blank page. http://prntscr.com/4cm2pd (firefox) http://prntscr.com/4cm30e (Chrome)

    #84334

    Sarah E
    Participant

    that’s so strange, i’m logged in to the dashboard right now and the site seems ok, although i’m unable to get into the customizer – it just says “initializing” and stalls at step 2. Not sure what could explain this…

    Can’t suggest anything other than to try later, so sorry.

    #84335

    Sarah E
    Participant

    FYI, Investigating my earlier question about including a cart icon in the topbar i’ve installed the menu cart pro plugin after reading another post but haven’t had a chance to try it yet, since i can’t get into customizer.

    #84339

    Paul R
    Moderator

    Hi Sarah,

    Can you try adding memory limit by adding this code in wp-config.php

    
    define( 'WP_MEMORY_LIMIT', '256M' );
    define( 'WP_MAX_MEMORY_LIMIT', '512M' );
    

    I am also getting this error

    “NetworkError: 404 Not Found – http://flyingstartbooks.com/wp-content/plugins/paypal-for-woocommerce/jss/upload-image.js?ver=3.9.2

    Maybe you accidentally deleted the file?

    Thanks

    #84343

    Sarah E
    Participant

    ok, i’ve added that code in wp-config.php. (i presume i was meant to just paste it at the end).

    I definitely haven’t deleted that file but did have some paypal issues last week so will investigate, thanks for the info.

    #84346

    Christopher
    Moderator

    We will be happy to help you when you update us about this.

    #84347

    Sarah E
    Participant

    I’m not really sure what the issue is here – is it just a missing image or is there something wrong with the plugin?
    I could try reinstalling the plugin but i don’t understand the implications – or how it affects this issue with the topbar?