Remove "search courses" button

Remove "search courses" button

by Dr. Moodlearner -
Number of replies: 9
Hi All,
I am using Moodle 1.8 and am unable to remove the "search courses" button. I don't know why I am unable to find this is documentation or the forum.

please look at the picture i have highlighted the search portion i am referring to.

thanks for the help
Attachment search.jpg
Average of ratings: -
In reply to Dr. Moodlearner

Re: Remove "search courses" button

by Dr. Moodlearner -
Anyone? how do you remove these search boxes?
In reply to Dr. Moodlearner

Re: Remove "search courses" button

by Don Sheets -

I am looking to do the same thing. Were you ever able to figure out how?

Donald

In reply to Don Sheets

Re: Remove "search courses" button

by Sandra Reitz -
You're talking about the front page only, right?

The only way I found is not the solution for me, as it also removes the course descriptions. In the admin settings => Frontpage => Frontpage Settings, you see a drop-down menu what will be displayed after logon. You can deselect the "List of courses" or play around with the other options, but I couldn't find a setting that has my preferred list of courses without the "Search Course" button.

Maybe an option for you would be to deselect the "List of courses" and instead include a block with that information. Per default, the "courses" block also includes a "search" link, but you can change that in the Admin setting Modules => Blocks => courses settings: block_course_list_hideallcourseslink => yes. Unfortunately, this setting has no effect on the middle column of the front page.



In reply to Dr. Moodlearner

Re: Remove "search courses" button

by Petr Kalis -
You can use CSS to hide it.
Select /theme/standard/styles_layout.css and add at the end of file this: (or if you have another theme which is not using standard theme, manipulate css file in this theme.)
#site-index #coursesearch{
 display:none;
}

This will hide course search form only on front page.

PK

In reply to Petr Kalis

Re: Remove "search courses" button

by Petr Kalis -
To hide both search course forms insert this code
#site-index #coursesearch,#site-index #coursesearch2{
 display:none;
}
PK
In reply to Petr Kalis

Re: Remove "search courses" button

by Jaswant Tak -
Hey Petr,

You missed on some pages to remove from entire site put this

/* to hide search course button */
#site-index #coursesearch,#site-index #coursesearch2, #coursesearchnavbar, #coursesearch2{
display:none;
}
In reply to Dr. Moodlearner

Re: Remove "search courses" button

by Gordon Brooks -

Here is a good explanation of how to remove the search courses box.

http://moodle.org/mod/forum/discuss.php?d=145809

In reply to Gordon Brooks

Re: Remove "search courses" button

by Sarah Jane -

Hi there

has anyone found a solution to hiding the search all courses box on the front page for students?

I have worked through each of the suggestions and none of these seem to make any difference at all.

Any advice would be appreciated.

working in magazine theme - moodle 2.0.7+

Thanks Sarah x

In reply to Sarah Jane

Re: Remove "search courses" button

by Debbie Mowry -

I must also ask if anyone has found a GUI admin way of doing this. It is off on my local environment but on in the production environment and I can't for the life of me figure out where I made a change because the line that these posts tell you to remove, is not in the theme files to remove. It is available in the core-renderer somewhere and while I'm not apposed to changing it, as I appear to have done on local—and as a very good lesson—now I can't remember where I made the change in the core render.

The table that is generated for the search box is coming from a yahoo script because the CSS associated with the table that contains the search box, and is external to the course list, has styling coming from yui_combo.php.

As for the suggested solution for doing it in the CSS file I might point out that this would work for the majority of individuals but turn the CSS off and bingo it is right back because it has not been removed from the actual HTML. I have hidden things through CSS but it is only after clarifying that it is okay that something is available if someone turns CSS off. If you're going to turn off a display it would be far better to turn off the table display that contains the search form (it is the only thing in the table) but it does not look like you can target the table easily (it contains no id or class).