This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc | |
. ~/.bashrc | |
mkdir ~/local | |
mkdir ~/node-latest-install | |
cd ~/node-latest-install | |
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 | |
./configure --prefix=~/local | |
make install # ok, fine, this step probably takes more than 30 seconds... | |
curl https://www.npmjs.org/install.sh | sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Function is responsible for returning the parent of the current | |
* page. | |
* | |
* This function should be placed in your functions.php file, or equivalent | |
* | |
* @param unknown_type $post | |
* @return object |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# all php files :: disallow direct access of file | |
# between <?php and ?> | |
defined('_JEXEC') or die; | |
# index.php :: define variable with application | |
# between <?php and ?> | |
$app = JFactory::getApplication(); | |
# index.php :: define variable with document | |
# between <?php and ?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
return array( | |
'JAccess' => 'Joomla\\Access\\Access', | |
'JAccessRule' => 'Joomla\\Access\\Rule', | |
'JAccessRules' => 'Joomla\\Access\\Rules', | |
'JApplicationBase' => 'Joomla\\Application\\Base', | |
'JApplicationCli' => 'Joomla\\Application\\Cli', | |
'JApplicationDaemon' => 'Joomla\\Application\\Daemon', | |
'JRoute' => 'Joomla\\Application\\Route', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
find /var/www/joomla -type f -exec chmod 0644 {} \; | |
find /var/www/joomla -type d -exec chmod 0755 {} \; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Requires jQuery of course. | |
$(document).ready(function() { | |
$('.show-comments').on('click', function(){ | |
var disqus_shortname = 'YOUR-DISQUS-USERNAME'; // Replace this value with *your* username. | |
// ajax request to load the disqus javascript | |
$.ajax({ | |
type: "GET", | |
url: "http://" + disqus_shortname + ".disqus.com/embed.js", | |
dataType: "script", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function gallery_shortcode_defaults( $out, $pairs, $atts ) { | |
$out['link'] = 'none'; | |
return $out; | |
} | |
add_filter( 'shortcode_atts_gallery', 'gallery_shortcode_defaults', 10, 3 ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# jfindfiles -- Find used and unused content files in your Joomla website | |
# | |
# This scripts supports Joomla versions 2.5 - 3.x | |
# | |
# Copyright 2014 Rene Kreijveld - email@renekreijveld.nl | |
# | |
# This program is free software; you may redistribute it and/or modify it. | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
##################################################################################################### | |
# == wpmd 2 grav == # | |
# This script converts the headers from wp2md to Grav headers format # | |
# wp2md : https://github.com/dreikanter/wp2md ; with `wp2md -d ./ export.xml -ps {title}/item.md` # | |
# Grav : http://getgrav.org/ # | |
# @author : Tom Canac http://tomcanac.com/ # | |
# @version : 0.1 # | |
# @licence : CC-BY # |
OlderNewer