Am using a subtheme of Panels_960gs, which is a subtheme of Boron, and I'm getting the following error:

Strict warning: Creating default object from empty value in boron_preprocess_html() (line 35 of template.php)

The boron_preprocess_html() function looks like this:

function boron_preprocess_html(&$vars) {
  if (module_exists('rdf')) {
    $vars['doctype'] = '<!DOCTYPE html PUBLIC "-//W3C//DTD HTML+RDFa 1.1//EN">' . "\n";
    $vars['rdf']->version = 'version="HTML+RDFa 1.1"';
    $vars['rdf']->namespaces = $vars['rdf_namespaces'];
    $vars['rdf']->profile = ' profile="' . $vars['grddl_profile'] . '"';
  } else {
    $vars['doctype'] = '<!DOCTYPE html>' . "\n";
    $vars['rdf']->version = '';
    $vars['rdf']->namespaces = '';
    $vars['rdf']->profile = '';
  }
}

Simply enough, it's assuming that the $vars['rdf'] variable exists and is an object, but in this case it just simply doesn't exist!

FYI I have the core RDF enabled on Drupal 7.7.

CommentFileSizeAuthor
#1 boron-n1242362.patch604 bytesdamienmckenna

Comments

damienmckenna’s picture

Status: Active » Needs review
StatusFileSize
new604 bytes

Here's a patch that ensures the $vars['rdf'] object exists.

berliner’s picture

works for me

resplin’s picture

Works for me too.

danlinn’s picture

Status: Needs review » Patch (to be ported)

I'll get this applied as soon as I can get to it.

danlinn’s picture

Version: 7.x-1.1 » 7.x-1.2
Status: Patch (to be ported) » Closed (fixed)

Added to 1.2 release

resplin’s picture

I just downloaded and checked 7.x-1.2 and the theme appears unchanged from 1.1. I suspect a packaging problem.

roske’s picture

It's not I applied the patch by hand and it works.

resplin’s picture

Status: Closed (fixed) » Active

Reopening because the patch does not appear to be in the package.

designerbrent’s picture

Looks like the patch never made it into the code, neither the dev or the release.

tlattimore’s picture

Not sure what comment #5 is about but it looks like this never got in. Committed to 7.x-1.x head.

http://drupal.org/commitlog/commit/14454/15c902d4bda7c59f15563fa7edeab1b...

tlattimore’s picture

Status: Active » Fixed

Oops. closing based on #10.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

jemmyn’s picture

using theme541 from template-help.com which and they unfortunately no longer offer support for this theme. my web host upgraded to php 5.4 and my site kept throwing this error message:

Warning: Creating default object from empty value in theme541_preprocess_html() (line 31 of /home4/terryspe/public_html/adcutah/sites/all/themes/theme541/template.p

This patch fixed it. Thank you thank you!

NOTE: theme541 - Lifted from Adaptivetheme for D7, full credit to Jeff Burnz
* ref: http://drupal.org/node/887600