Skip to main content

Social icons at sidebar

ClassiBase classifieds script Forums General help Social icons at sidebar

This topic contains 0 replies, has 0 voices, and was last updated by  info 4 years, 11 months ago.

Viewing 1 post (of 1 total)
  • Author
  • #2128 Reply


    For those who may want to have their social icons at side bar, I share what I’ve done for myself:

    1. Create a css file (name it style.css) and upload it to yoursite . com/public/yourstylelocation/
    This is the content{} li {float:left;padding:0 2px 0 0;list-style:none;} li a {display:block;width:32px;height:32px;} li a.rss {background: url('./social/icon_rss.png') no-repeat;} li a.fb {background: url('./social/icon_facebook.png') no-repeat;} li {background: url('./social/icon_twitter.png') no-repeat;}

    2. Upload the icons png files (see names above) to yoursite . com/public/yourstylelocation/social/
    You can get icons here

    3. At admin panel /settings / header/footer add this line to your custom header

    <link rel="stylesheet" href="/public/yourstylelocation/style.css"/>

    4. At admin panel /appearence / widgets add the code below, as text, at the area you want it displayed.
    Be sure to mark it as PHP format.
    Hope it works (it does for me…) and you enjoy it

     $selected_category = self::$_vars['selected_category'];
     $selected_location = self::$_vars['selected_location'];
     $base = BASE_URL;
     $latest = 'rss/';
     $featured = 'rss/featured/';
     $rss_latest = __('RSS latest ads');
     $rss_featured = __('RSS featured ads'); 
     $arr_page_title[0] = View::escape(Category::getName($selected_category));
     $y_url = Location::url($l, $selected_category);
     $categ = str_replace(BASE_URL, "", $y_url);
     $latest .= 'latest/';
     $rss_latest .= ':';
     $rss_featured .= ':';
     $arr_page_title[1] = View::escape(Location::getName($selected_location));
     $y_url = Location::url($selected_location, $l);
     $local = str_replace(BASE_URL, "", $y_url);
     if(!$selected_category) {
     $latest .= 'latest/';
     $rss_latest .= ',';
     $rss_featured .= ',';
     else {
     $arr_page_title[1] = ', '. $arr_page_title[1]; 
     $latest .= $local;
     $featured .= $local;
     $social = ""; 
     $social .="<ul class=\"social\">"; 
     $social .= "<li><a href=\"$base$latest$categ\" class=\"rss\" title=\"$rss_latest $arr_page_title[0]$arr_page_title[1]\"></a></li>";
     $social .= "<li><a href=\"$base$featured$categ\" class=\"rss\" title=\"$rss_featured $arr_page_title[0]$arr_page_title[1]\"></a></li>";
     $social .= "<li><a href=\"\" target=\"_blank\" class=\"fb\" title=\"Follow us on Facebook\"></a></li>";
     $social .= "<li><a href=\"\" target=\"_blank\" class=\"tw\" title=\"Follow us on Twiter\"></a></li>";
     $social .="</ul>";
     echo $social . '<br/>';
Viewing 1 post (of 1 total)
Reply To: Social icons at sidebar
Your information:

  • Classifieds Business Newsletter

    Get discounts and tips about growing your classifieds website.