How can I allow div to float outside the main container
I have tried with padding, margin, overflow, etc. The one thing that seems to work is by setting negative margin, but in that case the div is hidden by the main container.
Here's the HTML/PHP:
<div class="purchase_options_meta clearfix">
<div class="purchase_options">
<?php if (function_exists('gb_deal_has_attributes') && gb_deal_has_attributes()): ?>
<div id="deal_attributes_wrap" class="section ">
<?php gb_add_to_cart_form() ?>
</div>
<?php else: ?>
<div class="buy_button gb_ff font_x_large">
<?php if ( gb_deal_availability() || !gb_is_deal_complete() ): ?>
<a href="<?php gb_add_to_cart_url(); ?>" class="button"><?php gb_e('Buy it!'); ?> <span><?php echo str_replace('.00','',gb_get_formatted_money(gb_get_price())) ?></span></a>
<?php elseif ( gb_is_sold_out() ) : ?>
<a class="button"><?php gb_e('Sold Out!') ?></a>
<?php else : ?>
<a class="button"><?php gb_e('It’s over!') ?></a>
<?php endif ?>
</div>
<?php endif ?>
</div>
.purchase_options { position: relative; } .buy_button { position: absolute; background: url(http://topgreekgyms.fitnessforum.gr/wp-content/uploads/2012/12/Button.png) no-repeat center; color: white; height: 67px; width: 375px; left: -36px; z-index: 9999; } .button { background-color: transparent; color: #FFFFFF; } .button:hover { background-color: #ffffff; color: white; } .buy_button a { font-weight: bold; font-size: 29px; font-family: arial; padding: 12px; display: block; white-space: nowrap; position: relative; }
I would greatly appreciate any help!
Kat
-
Patrick -
Thanks - 1 reply
SignatureFreelance WordPress Developer | Free WordPress Themes | Free WordPress Plugins | Free WordPress Support{{ DiscussionBoard.errors[7493874].message }}-
katindo -
Thanks - 1 reply
{{ DiscussionBoard.errors[7496782].message }}-
Patrick -
Thanks - 1 reply
SignatureFreelance WordPress Developer | Free WordPress Themes | Free WordPress Plugins | Free WordPress Support{{ DiscussionBoard.errors[7496859].message }}-
katindo -
Thanks
{{ DiscussionBoard.errors[7496912].message }} -
-
-
-