@ sign in front of variable

Sometimes in your programming you’ll need to use @ sign in front of a variable. For example, @$_REQUEST[“username”]; The @ sign is an error control operator. When prepended to an expression in PHP, any error messages that might be generated by that expression will be ignored. For example: $value = @$cache[$key]; // will not issue a notice if the index $key doesn’t exist.

Continue reading »

hook_update_last_removed()

Return a number which is no longer available as hook_update_N(). If you remove some update functions from your mycustommodule.install file, you should notify Drupal of those missing functions. This way, Drupal can ensure that no update is accidentally skipped. Parameters none Return value An integer, corresponding to hook_update_N() which has been removed from mycustommodule.install. Usage sample function hook_update_last_removed() {    // We’ve removed the 6.x-1.x version of mycustommodule, including database updates.    // The next update function is mycustommodule_update_6200()    return 6105; }

Continue reading »