phpMyFAQ

How to set up the number of categories on the main page

How to set up the number of categories on the main page

Posted: Wed May 29, 2013 8:40 pm

by tselyuloza

Hello,

Where can i set up the number of categories displayed on the main page? For example, i have 50 categories, and for now all they are displayed on the main page that stretches the page down. In my case i want 10 categories to be displayed on the main page. I haven't find a proper line in constants.php file. So, where can i do this?

The same question relates to the most popular searches variable. Where can i change it?

Thanks in advance!

Re: How to set up the number of categories on the main page

Posted: Thu May 30, 2013 7:20 pm

by Thorsten

Hi,

what about moving some categories to subcategories? Otherwise I can show you where to hack the code to get only 10 categories.

You can set the number of the most popular search terms in the configuration section for search

bye
Thorsten

Re: How to set up the number of categories on the main page

Posted: Thu May 30, 2013 8:25 pm

by tselyuloza

1) Otherwise I can show you where to hack the code to get only 10 categories. - it will be the best way out.

2) You can set the number of the most popular search terms in the configuration section for search - seems, this is the code i need. but it does not help me. 10 most popular searches are always displayed. you know, when i found the default value was 7, i was surprised cause 10 items were always displayed in my case.

Re: How to set up the number of categories on the main page

Posted: Thu Jun 13, 2013 1:28 pm

by tselyuloza

It works. Thank u a lot!

Re: How to set up the number of categories on the main page

Posted: Fri Jun 14, 2013 1:02 pm

by tselyuloza

HI, i have one more question.
I want to disable the language selection and make English as a default language regardless of the browser language. Seems, i need this file \inc\Language.php but where i should change the code?
Thanks in advance!

Re: How to set up the number of categories on the main page

Posted: Fri Jun 14, 2013 1:13 pm

by Thorsten

HI,

you don't have to change code. Remove the language selection from the index.tpl template and disable the automatic detection in the main config

bye
Thorsten

Re: How to set up the number of categories on the main page

Posted: Fri Jun 14, 2013 2:14 pm

by tselyuloza

"automatic detection in the main config" - if i'm not mistaken you are talking about the following piece of code:
can you give me a hint at what lines should be disabled cause my attempts didn't give me any result.