Blog, Website & Page Publishing

vhalili
メンバー

How to put cookies notification at the bottom for mobile?

解決

Good day, 

How to put cookies notification at the bottom for mobile? There's a Banner position option in the settings and I chose the "Bottom" option. It is working on desktop but it is not working on mobile, it is still showing at the top.

 

Any help?

 

Thank you!

 

Screenshots:

 

Cookie Banner Setting

Option ChosenOption Chosen

 

 

Mobile Screenshot

Phone ScreenshotPhone Screenshot

 

Desktop Screenshot

Desktop ScreenshotDesktop Screenshot

0 いいね!
1件の承認済みベストアンサー
piersg
解決策
キーアドバイザー

How to put cookies notification at the bottom for mobile?

解決

Hi @vhalili (thanks @JessicaH)

 

Add this css to your site footer HTML in your website settings:

 

 

<style>
@media (max-width: 768px) {
 #hs-eu-cookie-confirmation.hs-cookie-notification-position-bottom {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
 }
}
</style>

 

 

edit: Woops, I put <script> instead of <style>

元の投稿で解決策を見る

5件の返信
piersg
解決策
キーアドバイザー

How to put cookies notification at the bottom for mobile?

解決

Hi @vhalili (thanks @JessicaH)

 

Add this css to your site footer HTML in your website settings:

 

 

<style>
@media (max-width: 768px) {
 #hs-eu-cookie-confirmation.hs-cookie-notification-position-bottom {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
 }
}
</style>

 

 

edit: Woops, I put <script> instead of <style>

APermissions
メンバー | Elite Partner
メンバー | Elite Partner

How to put cookies notification at the bottom for mobile?

解決

I would suggest just one minor change to this:

 

<style>
@media (max-width: 768px) {
 #hs-eu-cookie-confirmation.hs-cookie-notification-position-bottom {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    top: auto;
    width: 100%;
 }
}
</style>
0 いいね!
Freerk
メンバー

How to put cookies notification at the bottom for mobile?

解決

I needed to add top: unset to make it appear at the bottom of mobile screens.

<style>

@media screen and (max-width:768px) {

  #hs-eu-cookie-confirmation.hs-cookie-notification-position-bottom {
    position: fixed;
    bottom: 0;
    top: unset;
    left: 0;
    right: 0;
    width: 100%;
  }

}

</style>

vhalili
メンバー

How to put cookies notification at the bottom for mobile?

解決

Thanks for this information! This solves the problem.

JessicaH
元HubSpot社員
元HubSpot社員

How to put cookies notification at the bottom for mobile?

解決

Hi @vhalili,


Thanks for reaching out.
I want to tag in some thought leaders to see if they can assist with this.
Hi @Chris-M @piersg @thesnappingdog , would you be able to share your thoughts?

Thanks,
Jess 


Wusstest du, dass es auch eine DACH-Community gibt?
Nimm an regionalen Unterhaltungen teil, in dem du deine Spracheinstellungen änderst !


Did you know that the Community is available in other languages?
Join regional conversations by changing your language settings !