So here is what I discovered. It is something that Drupal is doing in rendering. Here is an uncomplicated html example that works fine in a .html file<div><br></div><div><div><div style="position:relative"></div>
<div> <div style="position: absolute;top:100;"></div><div> This is a test</div><div> <input type="button" value="test" /></div><div> </div></div><div></div></div>
<div><br></div><div>In Drupal, my outer div is the region, which I mark as relative positioning in the css. The inner div is a block, which I mark as absolute positioning in the css. The block appears correctly. The button, whether I create it via $mybutton=theme(button), or create it via $mybutton="<input type=button>, I have tried printing the variable from the template and inside the block, and the markup always ends up like this:</div>
<div><br></div><div><div></div><div> <div></div><div> block stuff</div><div> </div></div><div></div></div><div><input></div><br><div class="gmail_quote">On Tue, May 29, 2012 at 8:27 AM, Carl Wiedemann <span dir="ltr"><<a href="mailto:carl.wiedemann@gmail.com" target="_blank">carl.wiedemann@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Global variables are not necessary and should be avoided.<div><br></div><div>Does it *visually* appear outside of the enclosing divs, or are you talking strictly about the markup? The former could indicate a mere CSS error.</div>
<div><br></div><div>Consider providing a pastebin of both the preprocess and markup to help diagnose.<br clear="all"><div><br></div><font color="#333333">Carl Wiedemann</font><div><div><font color="#666666">Website design & development consulting | <a href="http://c4rl.ws" target="_blank">c4rl.ws</a></font></div>
<div><font color="#666666"><a href="mailto:carl.wiedemann@gmail.com" target="_blank">carl.wiedemann@gmail.com</a> | skype: c4rlww</font></div></div><br>
<br><br><div class="gmail_quote"><div><div class="h5">On Mon, May 28, 2012 at 9:50 PM, Jeff Greenberg <span dir="ltr"><<a href="mailto:listmail.ayendesigns@gmail.com" target="_blank">listmail.ayendesigns@gmail.com</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5">In D7, in template.php, I'm hooking preprocess_page and setting a $vars[] variable = theme_button. <div>
<br></div>
<div>In a block, I have this:</div><div><br></div><div><?php global $signup_button; ?></div><div>
<div><div id="signup"><?php print $signup_button; ?></div></div></div><div><br></div><div>The button appears in the page source outside of those enclosing divs. What am I doing wrong?</div><div>
<br></div>
<br></div></div>_______________________________________________<br>
themes mailing list<br>
<a href="mailto:themes@drupal.org" target="_blank">themes@drupal.org</a><br>
<a href="http://lists.drupal.org/mailman/listinfo/themes" target="_blank">http://lists.drupal.org/mailman/listinfo/themes</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________<br>
themes mailing list<br>
<a href="mailto:themes@drupal.org">themes@drupal.org</a><br>
<a href="http://lists.drupal.org/mailman/listinfo/themes" target="_blank">http://lists.drupal.org/mailman/listinfo/themes</a><br>
<br></blockquote></div><br></div>