<HTML>
<HEAD>
<TITLE>Re: [support] block.tpl.php CSS issue</TITLE>
</HEAD>
<BODY>
<FONT SIZE="4"><FONT FACE="Calibri, Verdana, Helvetica, Arial"><SPAN STYLE='font-size:11pt'>Mark — no I have not tried block_class. Let me check it out, thanks.<BR>
<BR>
Gary<BR>
<BR>
------------------------------------------------<BR>
<BR>
Message: 2<BR>
Date: Fri, 1 Oct 2010 10:20:09 -0400<BR>
From: Mark Shropshire <<FONT COLOR="#0000FF"><U>mdshrops@shropnet.net</U></FONT>><BR>
Subject: Re: [support] support Digest, Vol 94, Issue 1<BR>
To: <FONT COLOR="#0000FF"><U>support@drupal.org<BR>
</U></FONT>Message-ID: <<FONT COLOR="#0000FF"><U>0C952FF9-D9F5-4DF3-8A50-3806EC8FB348@shropnet.net</U></FONT>><BR>
Content-Type: text/plain; charset="windows-1252"<BR>
<BR>
Gary,<BR>
<BR>
Not sure if this has been recommended yet, but I have kept it in mind if I need it in the future:<BR>
<BR>
<FONT COLOR="#0000FF"><U><a href="http://drupal.org/project/block_class">http://drupal.org/project/block_class</a><BR>
</U></FONT><BR>
Mark<BR>
<BR>
<BR>
On 10/2/10 8:00 AM, "support-request@drupal.org" <support-request@drupal.org> wrote:<BR>
<BR>
</SPAN></FONT></FONT><BLOCKQUOTE><FONT SIZE="4"><FONT FACE="Calibri, Verdana, Helvetica, Arial"><SPAN STYLE='font-size:11pt'><BR>
Today's Topics:<BR>
<BR>
1. Re: support Digest, Vol 94, Issue 1 (Broyhill, Gary)<BR>
2. Re: support Digest, Vol 94, Issue 1 (Mark Shropshire)<BR>
<BR>
<BR>
----------------------------------------------------------------------<BR>
<BR>
Message: 1<BR>
Date: Fri, 1 Oct 2010 09:36:10 -0400<BR>
From: "Broyhill, Gary" <Gary.Broyhill@lr.edu><BR>
Subject: Re: [support] support Digest, Vol 94, Issue 1<BR>
To: "support@drupal.org" <support@drupal.org><BR>
Message-ID: <C8CB5C0A.D51E%Gary.Broyhill@lr.edu><BR>
Content-Type: text/plain; charset="iso-8859-1"<BR>
<BR>
Shai,<BR>
<BR>
That helps ... I guess I will need to find another way to deal with the style issues then. I am running a multisite setup with one theme in sites/all/themes, and have created CSS for "block-block-2" (for example) that I want to apply across all sites. In most of the sites, block-block-2 is my right sidebar, but for a couple it's the center image. I guess because the sites have different combinations of modules, the content of block-block-2 is potentially going to be different for each site? I am not sure how to compensate for this without adding an overriding style sheet for the sites that vary from my setup. I have 45 subsites and it's getting to be a bit messy.<BR>
<BR>
Gary<BR>
<BR>
---------------------------------<BR>
<BR>
Date: Thu, 30 Sep 2010 12:13:18 -0400<BR>
From: Shai Gluskin <shai@content2zero.com><BR>
Subject: Re: [support] block.tpl.php CSS issue<BR>
To: support@drupal.org<BR>
Message-ID:<BR>
<AANLkTi=htNU-4=LCLey3RUqdfQwyQ_CqmQWj+yd1UH=h@mail.gmail.com><BR>
Content-Type: text/plain; charset="windows-1252"<BR>
<BR>
Hi Gary,<BR>
<BR>
It's a bit confusing... and different themes deal with it differently. But<BR>
the underlying concept here that you are missing is that a module must be<BR>
responsible for a block. So in the case of "block-block-1" it is the block<BR>
module that is responsible. The menu module (as many other modules) also<BR>
creates blocks. So you might see "block-menu-1". For each controlling<BR>
module, the numbering starts over.<BR>
<BR>
But some themes don't use the "delta" or at least not in certain situations.<BR>
Like I just looked at a site (I think I used Genesis there) where I saw<BR>
"block-menu-nav" where "nav" was the name of the menu. There was no delta.<BR>
And on another site using Zen and Panels I saw a block in a panel get<BR>
"pane-menu-block-1. So now I've confused you. But I think I've gotten you<BR>
over the hump here, conceptually, yes? A module always "owns" a block.<BR>
<BR>
best,<BR>
<BR>
Shai<BR>
<BR>
On Thu, Sep 30, 2010 at 11:27 AM, Broyhill, Gary <Gary.Broyhill@lr.edu>wrote:<BR>
<BR>
> I?ve got a CSS problem related to block.tpl.php . I was looking at the<BR>
> API for block.tpl.php, and I?m a little confused over how Drupal assigns the<BR>
> block-block-x ID to come up with block-block-1, block-block2, etc.<BR>
><BR>
> >From the API: <div id="block-<?php print $block->module .'-'.<BR>
> $block->delta; ?>" class="block block-<?php print $block->module ?>"><BR>
><BR>
> So I see that the ID value comes from "block-<?php print $block->module<BR>
> .'-'. $block->delta; ?>" but where its the numbering controlled?<BR>
><BR>
><BR>
-------------- next part --------------<BR>
An HTML attachment was scrubbed...<BR>
URL: <a href="http://lists.drupal.org/pipermail/support/attachments/20101001/c883f1e4/attachment-0001.html">http://lists.drupal.org/pipermail/support/attachments/20101001/c883f1e4/attachment-0001.html</a><BR>
<BR>
------------------------------<BR>
</SPAN></FONT></FONT></BLOCKQUOTE>
</BODY>
</HTML>