I needed to implement a background in the template file (lightbox-like effect).
Here is what I did, nothing huge, but still worth to add it in the doc if it can help someone.

Copy the better_messages.tpl.php file from module into your theme.

Change those lines :

<div id="better-messages-default">
	<div id="messages-inner">
		<table><tbody>

per :

<div id="better-messages-default">
	<div style="background-color:#A6A6A6; position: fixed; top: 0; left: 0; width: 100%; height: 100%; -ms-filter:'progid:DXImageTransform.Microsoft.Alpha(Opacity=50)'; filter: alpha(opacity=50); opacity: .5;"></div>
	<div id="messages-inner" style="overflow: visible; display: block; position: fixed; z-index: 9999; width: 400px; top: 30%; left: 30%;-ms-filter:'progid:DXImageTransform.Microsoft.Alpha(Opacity=100)'; filter: alpha(opacity=100); opacity: 1;">
		<table><tbody>

Change the color code (grey) #A6A6A6 per your own...

Edouard

Comments

drupalorg’s picture

Hello, I tried this script, it works but I have problems!
Using the "position: fixed", I can not chiuedere more posts by drupal. Clicking on the X and nothing happens. Can you help me?

rutiolma’s picture

Hi,
nice trick Edouard.
I didn't have problem with this script as it is, but I think it's better not give any style to #messages-inner and let better-messages deal with it.

Cheers

bucefal91’s picture

Issue summary: View changes
Status: Active » Closed (outdated)

The 6.x version is no longer supported.