Skip to content

Instantly share code, notes, and snippets.

View nash-ye's full-sized avatar
🎯
Focusing

Nashwan Doaqan nash-ye

🎯
Focusing
View GitHub Profile
@nash-ye
nash-ye / functions.php
Last active August 29, 2015 14:06
Revert Back the Arabic "Widgets" Translation.
<?php
add_filter( 'gettext', 'change_widget_translation', 10, 3 );
/*
* Change the Arabic "Widgets" translation.
*
* @return string
*/
function change_widget_translation( $translations, $text, $domain ) {
@nash-ye
nash-ye / functions.php
Last active August 29, 2015 14:05
A simple example to show the preferred way to load a Momtaz module.
<?php
add_action( 'after_momtaz_setup', 'sample_after_momtaz_setup', 11 );
/**
* Load all the necessary code after Momtaz setup.
*
* @return void
* @since 0.1
*/
@nash-ye
nash-ye / functions.php
Last active August 29, 2015 14:05
A simple example to show the preferred way to change Momtaz current layout.
<?php
add_action( 'after_setup_theme', 'sample_after_setup_theme', 11 );
/**
* An action for 'after_setup_theme' hook.
*
* @return void
* @since 0.1
*/
<?php
/**
* Event manager
*
* @since 1.3
*/
class EventManager {
/*** Properties ***********************************************************/
<?php
/**
* Priority Array
*
* @since 1.3
*/
class PriorityArray implements \IteratorAggregate, \ArrayAccess, \Serializable, \Countable {
/*** Properties ***********************************************************/