Modifying $variables['title'] to replace title with image

I'm working on my first D7 site and am trying to replace page titles with images using the 6.x code at http://drupal.org/node/221854 but I'm running into a problem that I haven't seen with D6. It appears that it's not possible to make any changes to $variables['title'] such as sanitizing the text and replacing the spaces with underscores, as is necessary to replace the title with an image.

Here's my code from my template.php file, it's certainly possible that I'm missing some key difference between D6 & D7:

// Prepare some general title text for use as a file name.
// Remove special HTML characters, trim whitespace, convert to lower-case
// repace spaces with underscores.
function clean_title($string)
{
$replace_chars = array("&", ":", ",", "'");
$cleanString = htmlspecialchars_decode( strtolower(trim($string)), ENT_QUOTES );
$cleanString = str_replace($replace_chars, "", $cleanString);
return str_replace(' ', '_', $cleanString );;
}

function MYTHEME_preprocess_page(&$variables) {
// substitute node title with an image, if a suitable replacement can be found.
// save original title text for use in head and breadcrumb.
$variables['breadcrumb_title'] = $variables['title'];
$variables['head_title'] = $variables['title'];
// Substitute title only for nodes...
$titleFile = clean_title($variables['title']) . '.png';

Blogroll?

Hi, folks

Drupal noob here. I apologize in advance for my ignorance.

I have set up a Drupal 7 installation. I've themed it and set up a few basic pages, and it's all good.

I would like to put a blogroll in a block in the right column. Each item in the blogroll would be the title of a blog, and it would link directly to that blog's url.

displaying place in Google maps

Hello, all the content of my site is about restaurants. The user has to fill in fields like country, city, address...

Is there a way to display automatically the restaurant in a Google map as the user enters the address?

Thanks

Just installed a module through admin. Where do I find it through ftp?

I installed the module, "Media" (http://drupal.org/project/media) through the module installation through the admin. I also installed the Youtube module which relates to the Media one (http://drupal.org/project/media_youtube). I am trying to find them through my FTP but I can not tell where on earth the files are located. Any suggestions? I'm looking in the typical spots but i see nothing.

user_build_content is not displaying html(with BR tags) in #markup for additional fields in user profile

I'm pretty new to Drupal 7. I am creating a new site where there I had added additional fields to the user profile under admin/config/people/accounts/fields.

I have added some fields of type 'Long Text' using the 'Text area(multiple rows)' widget. Lets say one I added was 'field_biography'.
The form to edit the user is good.
When I view the user the text entered in 'field_biography' is all on one line. When looking at the HTML sent to the browser

I see something like:

error after instaling the theme

after successfully installing the theme this error message appears

Pages

Subscribe with RSS Subscribe to RSS - Drupal 7.x