Skip to content

Instantly share code, notes, and snippets.

Avatar

Mark Lee imarklee

View GitHub Profile
@imarklee
imarklee / gist:11366925
Created Apr 28, 2014
EasyBlog columns layout
View gist:11366925
.category-wrapper-3 .blog-post .blog-image {
float: none !important;
}
.category-wrapper-3 .blog-post .blog-image img{
width: 100%;
}
.category-wrapper-3 .blog-post {
width: 40% !important;
@imarklee
imarklee / EasyBlog.php
Created Apr 28, 2014
RokSprocket hack
View EasyBlog.php
<?php
// Comment the line below
//$itemId = EasyBlogRouter::getItemIdByCategories( $raw_item->category_id );
// Replace it with
$itemId = EasyBlogRouter::getItemId();
@imarklee
imarklee / gist:19dd5e0587c0bb689040
Created May 1, 2014
Yoo_nano3 conflict with EasyBlog comments
View gist:19dd5e0587c0bb689040
#frmComment .form-row.prm {
padding-right: 0 !important;
margin-right: 0 !important;
}
#frmComment textarea#comment{
border-radius: 0;
background: #fff !important;
}
@imarklee
imarklee / gist:85ef7d810afab59304f1
Created May 1, 2014
Remove avatar from EasyDiscuss search bar
View gist:85ef7d810afab59304f1
<div class="discuss-tablecell discuss-searchbar--left discuss-searchbar--avatar">
<?php if( $system->config->get( 'layout_avatar' ) ){ ?>
<div class="discuss-avatar avatar-medium avatar-circle pull-left">
<a href="<?php echo $system->profile->getLink();?>"><img src="<?php echo $system->profile->getAvatar();?>" alt="<?php echo $this->escape( $system->profile->getName() );?>" /></a>
</div>
<?php } ?>
</div>
@imarklee
imarklee / gist:5266c133f2cef30ebe32
Created May 13, 2014
Retrieve EasyBlog Category title
View gist:5266c133f2cef30ebe32
<?php
require_once(JPATH_ROOT.'/components/com_easyblog/helpers/helper.php');
$id = JRequest::getInt('id');
$view = JRequest::getWord('view');
if ($view == 'categories' && $id) {
$category = EasyBlogHelper::getTable('Category', 'EasyBlogTable');
$category->load($id);
View gist:49c07340f22122b384e1
<?php
// Include EasySocial's engine
require_once(JPATH_ADMINISTRATOR . '/components/com_easysocial/includes/foundry.php');
if (JFactory::getDocument()->getType() == 'html') {
// We also need to render the styling from EasySocial.
$doc = Foundry::document();
$doc->init();
$page = Foundry::page();
@imarklee
imarklee / gist:34a1e1506c31033be2ca
Created May 24, 2014
EasySocial: Retrieving user field data
View gist:34a1e1506c31033be2ca
<?php
require_once(JPATH_ADMINISTRATOR . '/components/com_easysocial/includes/foundry.php');
$db = Foundry::db();
$query = array();
$query[] = 'select b.`data`, b.`raw` from `#__social_fields` as a';
$query[] = 'inner joins #__social_fields_data as b';
$query[] = 'on a.id = b.field_id';
@imarklee
imarklee / gist:d970cb17dcdd2b3318f0
Created May 24, 2014
EasyBlog 3.9 category title retrieval
View gist:d970cb17dcdd2b3318f0
<?php
$id = JRequest::getInt('id');
$blog = EasyBlogHelper::getTable('Blog');
$blog->load($id);
$category = EasyBlogHelper::getTable('Category');
$category->load($blog->category_id);
@imarklee
imarklee / view replies
Created Feb 6, 2015
View replies easydiscuss
View view replies
<?php if (($category->canViewReplies() && $post->assignment->assignee_id == $my->id) || DiscussHelper::isSiteAdmin()){ ?>
View testing
<?php
echo "Hello"
You can’t perform that action at this time.