hack

KISS, chx, KISS!

  1. Index: includes/database/mysql/schema.inc
  2. ===================================================================
  3. RCS file: /cvs/drupal/drupal/includes/database/mysql/schema.inc,v
  4. retrieving revision 1

CiviCRM hook_user to not set an empty $_SESSION["civicrm"] for anonymous users - needed for Pressflow

  1. function civicrm_user( $type, &$edit, &$user, $category = NULL )
  2. {
  3.     $current_user = $_GLOBALS["user"];
  4.                
  5.                 if($current_user->uid == 0 && (arg(0) == "user" && is_numeric(arg(1)))) {
  6.                   retur

Fix for CiviCRM hook_user to not set an empty $_SESSION["civicrm"] for anonymous users - needed for Pressflow

  1. function civicrm_user( $type, &$edit, &$user, $category = NULL )
  2. {
  3.     $current_user = $_GLOBALS["user"];
  4.                
  5.                 if($current_user->uid == 0 && (arg(0) == "user" && is_numeric(arg(1)))) {
  6.                   retur

page_get_cache disable hack

  1. /**
  2.  * Retrieve the current page from the cache.
  3.  *
  4.  * Note: we do not serve cached pages when status messages are waiting (from
  5.  * a redirected form submission which was completed).
  6.  *

4.6 custom table -> 5.x filefield migration code

  1.   $result = db_query("SELECT * FROM {cv_files} WHERE uid = %d", $user46->uid);
  2.   $i = 0;
  3.  
  4.   while ($row = db_fetch_object($result)) {
  5.     $old_filepath = PK_46_PATH .'/'. $row->filepath;

Triggerblock module which may be nice to create?

  1. <?php
  2. /**
  3.   Triggerblock allows you to trigger when the triggerblock is shown.
  4.  
  5.   It also adds a new action which will publish old posts that are both sticky and promoted.
Syndicate content