- This topic has 7 replies, 2 voices, and was last updated 3 years, 10 months ago by David.
-
AuthorPosts
-
May 21, 2020 at 2:50 am #1295058Bob
Hi,
I have just started building a new website using your ‘Prime’ template from the Site Library, but have ran into an initial problem I was not expecting.I do not want to use a slider for the banner image, so I removed the slider and created an element for the Banner. I added a static image under ‘Custom Image’ hoping that would do it. Alas, the image does not appear, unless I start adding blank spaces to the Page Hero field.
Basically, I just want a simple banner image at the top instead of the slider. How do I do this?I am also trying to get the Cart to show up in the Header section, preferably with the current Cart cost and number of contents. This shows up in the Navigation menu, but when I use the Cart widget, it just says Cart, with no Cart icon or price etc?
FYI. As I am rebuilding the site, the current domain you will see is the current site and not the one I am building. To see that you will need the IP address 103.27.34.47
ThanksMay 21, 2020 at 3:47 am #1295117DavidStaffCustomer SupportHi there,
1. Edit the Header Element – remove the spaces you have added to the content and add a simple HTML comment eg.
<!-- hero image -->
Now increase the Top padding to set the elemetns height.
Tip:
Calculate the % aspect ratio of your original image using this calculation: Height / Width * 100.
In the Element select % units for the top padding and add your aspect ratio.
This works for full width hero elements that contain no text and will keep the image full size and responsive.2. The Menu Cart icon is only available in Navigation menu. You could add it to the secondary navigation using this filter:
https://docs.generatepress.com/article/generate_woocommerce_menu_item_location/
And then set a secondary navigation to float right of the header.
May 24, 2020 at 5:51 pm #1299851BobHey David,
The banner advise worked perfect, thanks.The Navigation Menu however has not worked at all. I added the code to the functions.php file in my child theme and created a new menu. I then added this as a Header Widget, but just got the word ‘Cart’?
The changes have also done strange things to my main menu?To give you some idea of what I am trying to achieve, please look at the website without forcing the DNS.
Another quick question. How do I change the color of the Sticky Navigation Background?
Cheers,
TroyMay 25, 2020 at 1:57 am #1300136DavidStaffCustomer Support2. It will only work if it is displayed in a theme Navigation Location.
That code moves it to the Secondary Navigation.1. Add the code.
2. Create a new menu.
2.1 Assign the menu to the Secondary Navigation
3. In customizer set the Location of the Secondary Navigation to Float Right. This will position the menu in the same place as the footer widget.3. The sticky navigation should inherit the colors you have set in Customizer > Colors > Primary Navigation. If you want to change it independently of the static nav use this CSS:
.sticky-enabled .main-navigation.is_stuck { background-color: #fff; }
May 25, 2020 at 5:53 pm #1301324BobHey David,
I managed to fix the Sticky Header with your code. Thanks.
I still could not get the desired effect from the Secondary Navigation solution though. All it did was create another menu at the top of the page.
I have used a dodgy plugin to resolve the issue for now, but I’m pretty sure my client will not like it.
I was rather hoping I could just make something using the Header Widget and maybe some HTML, but haven’t been able to find any solutions online, other than this ugly plugin.
If you can offer any advice at all on how I can make this look a little more presentable, I would really appreciate it.Thanks
May 26, 2020 at 3:40 am #1301745DavidStaffCustomer SupportI tested the method i proposed and it worked fine.
These are the steps i followed:1. I added the code provided here to my site:
https://docs.generatepress.com/article/generate_woocommerce_menu_item_location/2. Appearance > Menus -> New Menu
Saved the Menu without any Items. Set the Location to Secondary Navigation.3. Customizer > Layout > Secondary Navigation –> Set location to Float Right.
June 1, 2020 at 1:27 am #1309486BobHey David,
I will mark this as resolved, but I can’t seem to get this happening and cannot throw any more time at it for now.
I may revisit this later.
Thanks anyway.June 1, 2020 at 3:59 am #1309609DavidStaffCustomer SupportNo problems – let us know if you need help with it in the future.
-
AuthorPosts
- You must be logged in to reply to this topic.