Common Inc v5

The following changes are required to ensure that the accessibility module works as expected in Drupal version 5.1x. common.inc has two functions that must be overridden for the module to work correctly. There is currently no patch file for this so changes need to be made manually.


<?php
# Change line 116
/**
 * Retrieve output to be displayed in the head tag of the HTML page.
 */
function drupal_get_html_head() { //~ change required for accessibility.module
  
$output = ( function_exists('accessibility_init') ) ? '' 
  
'<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />'."\n";
  return 
$output drupal_set_html_head();
}
 
# Change to new line 1839
  // Emit the correct charset HTTP header.
  
if ( !function_exists('accessibility_init') ) { //~ change required for accessibility.module
  
drupal_set_header('Content-Type: text/html; charset=utf-8');
  }



This stops the http and HTML headers from being sent by default. These are sent later while the accessibility module is processing - detecting the correct content type to send.

Comments

Hi, I am having real trouble

Hi, I am having real trouble locating where the second edit needs to be placed could you send me a file with it changed so i can see how it is supposed to be. Thnks

Text Search

Hi Robert, sorry you are having issues.

I don't think it would be advisable to send the file as you have have a different version than the one I have. Just check for all instances of drupal_set_header - just below the bootstrap function.

Br

Jamie
Making Drupal Mobile

Syndicate content