This topic contains a post which is marked as Best Answer. Press here if you would like to see it.
*

questions

  • *****
  • 319 posts
Hello,

How to display widgets only on home page and not on all the pages?
If it is shown on all pages, they become non-responsive on mobile.
Can someone help?

Thank you,
« Last Edit: February 22, 2023, 01:34:36 PM by questions »

*

questions

  • *****
  • 319 posts
Re: How to display widgets only on home page and not on all the pages?
« Reply #1 on: February 22, 2023, 04:51:49 PM »
This is how the footer looks like on registration form, authentication form, posting ads form, when widgets are created.

Any idea how to fix this?

or is there any way to show the widgets only on home page? from HOOKS maybe?

there is no errors on home page. remains reponsive.

*

questions

  • *****
  • 319 posts
Re: How to display widgets only on home page and not on all the pages?
« Reply #2 on: February 22, 2023, 05:21:32 PM »
Adding 2 more pics from a fresh install in the loop to see the issue I am talking about. advices? Seeing there is a lot of installations worldwide, which exlucded the widgets on the authentication page, register page, post page..

Help please?

*

questions

  • *****
  • 319 posts
Re: How to display widgets only on home page and not on all the pages?
« Reply #3 on: February 22, 2023, 05:45:05 PM »
<div class="footer-widgets"><?php osc_show_widgets('footer'); ?></div>
removing this in footer.php removes the widgets on all the website.

Should be something here

Hooks Manager Plugin

Admin please help?

*

questions

  • *****
  • 319 posts
Re: How to display widgets only on home page and not on all the pages?
« Reply #4 on: February 22, 2023, 06:54:04 PM »
Wanna have the widgets only on Home page.

Marked as best answer by questions on February 22, 2023, 10:02:13 PM
*

MB Themes

Re: How to display widgets only on home page and not on all the pages?
« Reply #5 on: February 22, 2023, 08:09:11 PM »
Registration page has fixed footer width.
Wrap your code into if(osc_is_home_page()) { }
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

questions

  • *****
  • 319 posts
Re: How to display widgets only on home page and not on all the pages?
« Reply #6 on: February 22, 2023, 08:15:12 PM »
THANK YOU!

But where should I put this? In footer.php?

What should I Search and What should I replace?

Thank you.
« Last Edit: February 22, 2023, 08:18:03 PM by questions »

*

MB Themes

Re: How to display widgets only on home page and not on all the pages?
« Reply #7 on: February 22, 2023, 08:26:51 PM »
<div class="footer-widgets"><?php osc_show_widgets('footer'); ?></div>
removing this in footer.php removes the widgets on all the website
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

questions

  • *****
  • 319 posts
Re: How to display widgets only on home page and not on all the pages?
« Reply #8 on: February 22, 2023, 10:01:54 PM »
<div class="footer-widgets"><?php osc_show_widgets('footer'); ?></div>
removing this in footer.php removes the widgets on all the website

Just in case someone else needs it.

<div class="footer-widgets"><?php if(osc_is_home_page()) {osc_show_widgets('footer');} ?></div>