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 | |
/** | |
* @file | |
* Configuration file for Drupal's multi-site directory aliasing feature. | |
* | |
* This file allows you to define a set of aliases that map hostnames, ports, and | |
* pathnames to configuration directories in the sites directory. These aliases | |
* are loaded prior to scanning for directories, and they are exempt from the | |
* normal discovery rules. See default.settings.php to view how Drupal discovers |
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 | |
/** | |
* Défini une nouvelle url d'accès | |
* -- | |
* Define menu items and page callbacks. | |
* | |
* This hook enables modules to register paths in order to define how URL requests are handled. | |
* Paths may be registered for URL handling only, or they can register a link to be placed in a menu (usually the Navigation menu). | |
* A path and its associated information is commonly called a "menu router item" * This hook is rarely called (for example, when modules are enabled), and its results are cached in the database. |
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
/** | |
* | |
* @param unknown_type $form | |
* @param unknown_type $form_state | |
* @return multitype:string NULL | |
*/ | |
function multifiles_example_form($form, &$form_state) { | |
$form['#tree'] = TRUE; |
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
function MYMODULE_enable() { | |
// Check if our field is not already created. | |
if (!field_info_field('field_myField')) { | |
$field = array( | |
'field_name' => 'field_myField', | |
'type' => 'text', | |
); | |
field_create_field($field); | |
// Create the instance on the bundle. |
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
#sites/all/modules/[TONMODULE]/tonmodule.module | |
function tonmodule_views_api() { | |
return array('api' => 3,'path' => drupal_get_path('modules', 'tonmodule') . '/includes/views',); | |
} | |
#sites/all/modules/[TONMODULE]/includes/views/monmodule.views.inc | |
function tonmodule_views_query_alter(&$view, &$query) { | |
if( $view->name == "Administrer" ) { | |
watchdog('monmodule', 'test'); | |
} |