View Full Version : .clearfix works in browsers, but wont show in Dreamweaver Design View

01-05-2008, 11:12 AM
I have used the css .clearfix trick on two divs which werent clearing a floated element.

It works great in web browsers, but as im designing my site in Dreamweaver CS3 the fix doesnt render or show in Dreamweavers Design View.

The fix is -

.clearfix:after {
.clearfix {display:inline-block;}
/* Hide from IE Mac \*/
.clearfix {display:block;}
/* End hide from IE Mac */

Does anyone know a way to make Dreamweaver Design View show the clearfix? Previously I was just using <br style="clear:both"> after the two divs to make them clear and this method displayed fine in Dreamweaver and as the clearing problem only affects two divs I may just go back to it. Surely a well designed site should look right in all browsers AND dreamweaver?

Also, using the clearfix trick fails Dreamweavers cross-browser compatability check, whereas using a few <br style="clear:both"> instead passes the check fine.

Are there any better alternatives to Dreamweaver? I do like DW's built in uploading of files, templates, in-built validation functions etc

01-05-2008, 05:21 PM

So? It doesn't really matter, as it'll render correct in browsers; why do you need to see it there?

And no, a well-designed site doesn't mean it'll show up correcly in Dreamweaver. Its design view is not a web browser.

01-06-2008, 10:15 PM
I would like to see it in DW as that is where im designing the webpage.

I know that DW isnt a browser, but its a shame a leading product cant display html and css the same as a browser does. Why have Design View at all if it isnt going to display the same as a browser?

Then again the same can be said for browsers not showing the same as DW.

Swings and roundabouts I guess!! :)