Skip to content

Instantly share code, notes, and snippets.

View ababushkin's full-sized avatar

Anton Babushkin ababushkin

View GitHub Profile
@ababushkin
ababushkin / gist:1221305
Created September 16, 2011 05:54 — forked from benjaminpearson/gist:1102194
Apps for a fresh Mac OS
1password - Password mangager
Adium - Instant messenger
Arq - Amazon s3 backup
Base - Sqlite db viewer
Caffeine - Keeps computer awake
Charles - Web debugging proxy
Cornerstone - SVN client
Cyberduck - FTP client
Delibar - Delicious bookmarking menu item
DiskWave - Monitor hdd space
@ababushkin
ababushkin / js-snippets-squiz-matrix.js
Created September 21, 2011 23:26
JavaScript Snippets for Squiz / MySource Matrix
/**
/**
* Changes the sort order of assets in Squiz Matrix
* Author: Nicholas Hubbard (http://www.zedsaid.com/blog/change-the-asset-map-sort-order-using-javascript-in-squiz-matrix)
*
* @param number id ID of the asset to move
* @param number parent ID of the parent that the asset is under
* @param number new_position New position of asset (0 is first in the sort order)
*
* @return string
@ababushkin
ababushkin / create-asset-squiz-matrix.php
Created September 21, 2011 23:36
PHP - Create an asset in Squiz / MySource Matrix
<?php
// First, include the Matrix bootstrap
// When ever a user makes any request to a Matrix page, this file is loaded (i.e. in the index.php file)
$SYSTEM_ROOT = "/home/websites/squiz_matrix/";
require_once $SYSTEM_ROOT . "core/include/init.inc";
// Now we need to log in
// The easiest user to work with is Root User
$root_user = $GLOBALS["SQ_SYSTEM"]->am->getSystemAsset("root_user");