Page 1 of 1

Hide items on homepage

Posted: 2021-11-20 05:36
by dlee
I need to hide or remove several items ( see attached pic ) at the top of the homepage of my app. How can I do this?

TD

Re: Hide items on homepage

Posted: 2021-11-20 16:44
by pböttcher
Hi,

you can add some javascript to the hooks/footer-extras.php.

Look for the DOM Elements that represent the marked items and hide them (or remove them).

For the import CSV data i think this can also be configured via the admin area.

Re: Hide items on homepage

Posted: 2021-11-21 00:45
by dlee
This is the code in the page source that I wish to eliminate:

Code: Select all

<a href="import-csv.php" class="btn btn-default navbar-btn hidden-xs btn-import-csv" title="Import CSV data to a table"><i class="glyphicon glyphicon-th"></i> Import CSV data</a>
So I added this code to the footer-extras.php file:

Code: Select all

<script>
    $j('a:contains("import-csv.php")').hide();
</script>
Doesn't work, any suggestions?
TD

Re: Hide items on homepage

Posted: 2021-11-21 01:08
by dlee
GOT IT, using classes, it's a beautiful thing! Thanks pbottcher for your suggestion!
Following code is in footer-extras.php:

Code: Select all

<script>
	$j('.btn-import-csv').hide();
	$j('.signed-in-as').hide();
	$j('.help-shortcuts-launcher').hide();
	$j('.help-block').hide();
</script>