Home Forums Basel support forum header shorcode

header shorcode

Viewing 21 posts - 1 through 21 (of 21 total)
  • Author
    Posts
  • #73627

    bruno
    Participant

    hi,

    I have chosen simplified header and would like to place a shortcode on the left next to search icon.

    Is this possible?

    Thanks

    #73637

    Artem Temos
    Keymaster

    Hi,

    Try to add the following PHP code snippet to the child theme functions.php file and then put your shortcode to the header widgets area in Appearance -> Widgets

    add_filter( 'basel_header_configuration', 'basel_custom_header_configuration', 1, 1 );
    
    function basel_custom_header_configuration() {
    
    		return array(
    			'container' => array(
    				'wrapp-header' => array(
    					'logo',
    					'main_nav',
    					'right-column' => array(
    						'widget_area',
    						'search',
    						'wishlist',
    						'cart',
    						'mobile_icon',
    					)
    				)	
    			),
    		);
    }

    Regards

    #73660

    bruno
    Participant

    That did not work it changed badly the layout.

    Attachments:
    You must be logged in to view attached files.
    #73668

    Artem Temos
    Keymaster

    Could you please send us a link where we can see how it looks now?

    #73670

    bruno
    Participant

    this is test web that i use incase i mess the real thing up

    thanks

    #73688

    bruno
    Participant

    Okay maybe i am doing this wrong so have installed plugin woo-commerce
    Currency Converter Widget and it works fine as you can see on the filters section but i want to add it to the right on top of the shopping cart?

    Attachments:
    You must be logged in to view attached files.
    #73691

    Artem Temos
    Keymaster

    You wrote that you set simplified header layout but it is set to different type. Could you please specify what kind of header you would like to use and where you want to place the shortcode?

    #73785

    bruno
    Participant

    I have selected simplified and have removed top bar option as i want only the main menu.
    I would like the shortcode on top of the shopping card please its where the currency option will be.

    Thanks

    Attachments:
    You must be logged in to view attached files.
    #73801

    Artem Temos
    Keymaster

    Could you please send us your admin access so we can check it?

    #73806

    bruno
    Participant

    So have added the widget woocommerce currency converter to the header as it says and does not show that is why i asked for shortcode hope this helps thanks.

    #73814

    Artem Temos
    Keymaster

    Yes, but you said that you use simplified header and we provided a code for you to do that. But as we can see, you don’t use this header and that is why we asked you for admin access to check your configuration first. You didn’t send me your username, only password.

    #73824

    bruno
    Participant

    So sorry included and i have its on the setting shown as selected, maybe i have done something wrong.

    #73827

    Artem Temos
    Keymaster

    Your header is set to Double menu https://gyazo.com/f55ee28d8bd53acd00bef015fdcf43fb
    So try this code and then add your widget

    add_filter( 'basel_header_configuration', 'basel_custom_header_configuration', 1, 1 );
    
    function basel_custom_header_configuration() {
    
    		return array(
    			'container' => array(
    				'wrapp-header' => array(
    					'right-column left-side' => array(
    						'mobile_icon',
    						'search',
    						'wishlist',
    					),
    					'logo',
    					'main_nav',
    					'right-column' => array(
    						'widget_area',
    						'header_links',
    						'cart',
    					)
    				)	
    			),
    		);
    }
    #73841

    bruno
    Participant

    perfect that worked thank you so much

    #73846

    bruno
    Participant

    one more thing sorry can i align to the right as now its based to the left
    thanks again

    #73870

    Artem Temos
    Keymaster

    Try this CSS code

    .widgetarea-head {
    	padding-right:0!important;
    	padding-left:0!important;
    	float:right;
    }
    #78971

    bruno
    Participant

    Hi,

    Okay so i didnt use this code

    .widgetarea-head {
    padding-right:0!important;
    padding-left:0!important;
    float:right;
    }

    and only the function code which then i changed to be pointed to the left and it has done so but is not in line with the icons, how can i change that please.

    thank you

    Attachments:
    You must be logged in to view attached files.
    #79026

    Artem Temos
    Keymaster

    Sorry, but your request is not quite clear and we can’t visit your website now https://gyazo.com/852cc45d74c9c809b8eb014b7ca20220

    #79256

    bruno
    Participant

    Sorry had to create a new temp link

    Thank you

    #79285

    Artem Temos
    Keymaster

    Try to increase right column width in Theme Settings -> Header -> Layout and use this CSS code

    body .main-header .widgetarea-head {
    	display: inline-block;
    }
    #79397

    bruno
    Participant

    Perfect thank you that worked

Viewing 21 posts - 1 through 21 (of 21 total)

The topic ‘header shorcode’ is closed to new replies.