• Welcome to PHPVIBE Forums. Please log in.

[ Video Sharing CMS v4 ] remove Channel icons

Started by shpeedie,

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

shpeedieTopic starter

I want to remove the Channel icons and leave only the text.

In sidebar.php i can remove them for Posts and Pages by changing the thumb_fix to false, but there is no option for the Channels ?

How can i do this ?
  •  

ollipaust

#1
Hello,

for things like this, I suggest you to use the multi-file-search, which the most editors have.

I found this in less than 1 minute:

1. Open the file lib > functions.php

2. Go to line 700 or search for "the_nav". You should find this line:
$label = '<a href="'.channel_url($cat->id, $cat->name).'" title="'. stripslashes($cat->name).'"><img src="'.thumb_fix($cat->picture, true, 23, 23).'" class="cat-menu-img"/>'. stripslashes($cat->name).'</a>';


3. delete or comment-out the <img>-tag
<img src="'.thumb_fix($cat->picture, true, 23, 23).'" class="cat-menu-img"/>


4. your new line should look like this
$label = '<a href="'.channel_url($cat->id, $cat->name).'" title="'. stripslashes($cat->name).'">'. stripslashes($cat->name).'</a>';


5. save and upload


NOTE: If you take out the channel-image, you have to apply a margin-left to the link in the navigation.
Since the link-tag has no specified class or id, you could give it one, then you can give it some CSS, without affecting other boxes or such.

example:

$label = '<a class="navilabel" href="'.channel_url($cat->id, $cat->name).'" title="'. stripslashes($cat->name).'">'. stripslashes($cat->name).'</a>';


css:

.navilabel {margin-left:10px;}

regards
  •  

PHPVibe A.

thumb_fix false = embed the image without re-sizing it.

OlliPaust :

.sidebar-nav ul a {
...
padding: 4px 1px 6px 2px;
...
}


Changing 2px to a higher padding, also does the trick.


ollipaust

Quote from: Alexander on

OlliPaust :

.sidebar-nav ul a {
...
padding: 4px 1px 6px 2px;
...
}



yep i saw this but then other boxes would change too so thats why i would do this
  •  

ipeci

This was a Big Problem for me,  the index was wery slowwwww.
I have removed and now its load very fast  ;D

I have fixed my homepage with font-icon  ::)
like this

$label = '<a href="'.channel_url($cat->id, $cat->name).'" title="'. stripslashes($cat->name).'"><i class="icon-off"></i>'. stripslashes($cat->name).'</a>';



Thank you @ OlliPaust +1
  •  

PHPVibe A.

Here is another way:

replace:

/* Infinite scroll */


with
/* Channels lazy load */	
	if(jQuery('.sidebar-nav').html()){
	var $chz = $('.sidebar-nav');
	$chz.hide();
	$chz.imagesLoaded(function(){
    $chz.fadeIn(); // fade in when ready	
	 });	
	}
	/* Infinite scroll */


in /tpl/main/js/phpvibe_app.js

shpeedieTopic starter

  •  

Similar topics (7)