Skip to content

Instantly share code, notes, and snippets.

Krikor Boghossian kricore

Block or report user

Report or block kricore

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View pl-PL.com_k2.ini
;/**
; * @version 2.8.x
; * @package K2
; * @author JoomlaWorks http://www.joomlaworks.net
; * @copyright Copyright (c) 2006 - 2017 JoomlaWorks Ltd. All rights reserved.
; * @license GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
; */
COM_K2="K2"
COM_K2_CONFIGURATION="Konfiguracja K2"
@kricore
kricore / webpack.config.js
Last active Mar 23, 2019
Kinda defeats the purpose of CSS modules but if you want to use (raw) Bootstrap alongside with CSS modules here you go:
View webpack.config.js
// "postcss" loader applies autoprefixer to our CSS.
// "css" loader resolves paths in CSS and adds assets as dependencies.
// "style" loader turns CSS into JS modules that inject <style> tags.
// In production, we use a plugin to extract that CSS to a file, but
// in development "style" loader enables hot editing of CSS.
// SASS loader
// https://medium.com/@Connorelsea/using-sass-with-create-react-app-7125d6913760
{
test: /\.scss$/,
View gist:5f90c8b2301b3016f61017b42b1b9e8b
#https://stackoverflow.com/documentation/reactjs/7480/setting-up-react-environment/24700/configure-webpack#t=201708110804335488513
# install react and react-dom
$ npm i react react-dom --save
# install webpack for bundling
$ npm i webpack -g
# install babel for module loading, bundling and transpiling
$ npm i babel-core babel-loader --save
@kricore
kricore / base.php
Created Jul 3, 2017
AllVideos 4.8.0 RC base.php file
View base.php
<?php
/**
* @version 4.8.0
* @package AllVideos (plugin)
* @author JoomlaWorks - http://www.joomlaworks.net
* @copyright Copyright (c) 2006 - 2016 JoomlaWorks Ltd. All rights reserved.
* @license GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
*/
// no direct access
View item.php
<?php
/**
* @version 2.7.x
* @package K2
* @author JoomlaWorks http://www.joomlaworks.net
* @copyright Copyright (c) 2006 - 2016 JoomlaWorks Ltd. All rights reserved.
* @license GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
*/
// no direct access
@kricore
kricore / functions.php
Created Dec 16, 2016
Filter the correct language on WordPress archive pages based on the lang $_GET param.
View functions.php
<?php
/**
* Language Detection
* @param $query,
* @uses pre_get_posts filter
* @return the modified query
*/
function kdk_exclude_category( $query ) {
if ( ($query->is_tag() && $query->is_main_query()) ||
@kricore
kricore / item.php
Created Aug 18, 2016
The item's admin form with tag drag n' drop reordering functionality. K2 2.7.x - Joomla! 3.x +
View item.php
<?php
/**
* @version 2.7.x
* @package K2
* @author JoomlaWorks http://www.joomlaworks.net
* @copyright Copyright (c) 2006 - 2016 JoomlaWorks Ltd. All rights reserved.
* @license GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
*/
// no direct access
@kricore
kricore / The inline player module
Last active Jun 6, 2016
Radiowave porting to other services
View The inline player module
<div id="jquery_jplayer_1" class="jp-jplayer"></div>
<div id="jp_container_1" class="jp-audio-stream" role="application" aria-label="media player">
<div class="jp-type-single">
<div class="jp-gui jp-interface">
<ul class="jp-controls">
<li>
<a href="javascript:;" style="display:block;" class="jp-play" title="Play"><i class="icon-play"></i><span>Listen Live</span></a>
<a href="javascript:;" style="display:none;" class="jp-pause" title="Pause"><i class="icon-pause"></i><span>Listen Live</span></a>
</li>
<li>
@kricore
kricore / view.feed.php
Created Jan 27, 2016
Hack: Add an extrafield to K2 feed items' title. Part of the view.feed.php item
View view.feed.php
$fields = json_decode($item->extra_fields);
$item->title = $this->escape($item->title);
if ($fields[0]->value && $fields[0]->value !== '')
{
$item->title = html_entity_decode($item->title.' - '.$fields[0]->value);
}
else
{
$item->title = html_entity_decode($item->title);
}
@kricore
kricore / default.php
Last active Sep 24, 2015 — forked from anonymous/default.php
Based on @buntom's gist. Removes the K2 item you are browsing from the list.
View default.php
<?php
/**
* @version 2.6.x
* @package K2
* @author JoomlaWorks http://www.joomlaworks.net
* @copyright Copyright (c) 2006 - 2014 JoomlaWorks Ltd. All rights reserved.
* @license GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
*/
// no direct access
You can’t perform that action at this time.