Osclass Support Forums
General osclass questions => Themes => Topic started by: bkfly1 on June 12, 2022, 03:14:27 PM
-
I created a page using the Sigma theme and would like to move the "All Categories" section to the top of the page, and remove the text "All Categories". Can someone point me in the right direction as to how to accomplish this?
-
You must edit main.php and move it, no other way.
-
OK, I think you're referring to the main.php in this path - /public_html/OSClass/oc-content/themes/sigma
Can you identify the section of code that needs to be moved in order for "All Categories" to appear at the top of the page?
-
@bkfly1
This is the block.
<?php osc_goto_first_category(); ?>
<div id="home-cats">
<h2><?php _e('All categories', 'sigma'); ?></h2>
<div class="wrap">
<?php while(osc_has_categories()) { ?>
<a href="<?php echo osc_search_category_url(); ?>">
<div class="icon" <?php if(osc_category_color() <> '') { ?>style="color:<?php echo osc_category_color(); ?>;"<?php } ?>>
<i class="<?php echo (osc_category_icon() <> '' ? osc_category_icon() : 'far fa-share-square'); ?>"></i>
</div>
<strong><?php echo osc_category_name(); ?></strong>
</a>
<?php } ?>
</div>
</div>
-
I have that section at the top of my main.php file, but the categories still appear at the bottom of the page beneath the "latest Listings" section. Any other ideas?
-
I think that in Sigma theme, in same way like bender, latest listings are defined in functions.php or header.php that can make harder to reorder
-
I'm still not clear what needs to be done. My page has the header with a link to login, register or publish at the top, then Latest Listings, then All Categories. I would simply like to move the section named "All Categories" above the "Latest Listings" section.
Can you explain how this can be done?, i.e. what file(s) need to be modified? What section of the file needs to be moved, etc.?
Secondary concern. My All Categories section doesn't take up the whole width of the page, as the other sections do. I'd prefer to have the All Categories section the same width as the others.
Thanks!
-
@bkfly1
You probably need to take block of code from header.php into main.php that may impact other pages, so it's not such simple task.
For your 2nd question, you can enlarge main block and hide sidebar.
body.home #main {width:100%!important;}
body.home #sidebar {display:none!important;}
-
Just to clarify, attached is a screen shot showing the two things I'm trying to accomplish...
Per your second suggestion, where can these two lines be found?
body.home #main {width:100%!important;}
body.home #sidebar {display:none!important;}
-
It is CSS, you are asking too too too much basic questions. Spend 1 hour to learn CSS basics as we cannot help with such elementary items.
https://www.w3schools.com/css/default.asp
-
I'm not a programmer. Sorry to be such a burden to you.
I don't think asking you to include the name of a file you're providing code snippets from is asking too much.
-
You do not need to be programmer to know css and html basics
-
Nor do you need to be one to know common courtesy and customer service basics. ;)
-
Customization is not basic service. Courtesy goes aside in forums :D