On a particular Dolphin CMS setup I was working with, my Flash illustration was overlapping the DHTML drop-down menu, so that I couldn’t see all of that menu. That menu was a necessity to run the site cleanly, so I had to find some means of getting the Flash and DHTML to play well together.
So, in searching Google for something to the effect of “Flash z-order”, I ultimately came to some pages explaining that the more recent browsers/browser versions came equipped with capabilities which allow Flash swfs to operate alongside DHTML elements as if the two were meant to work together.
Basically, the code calling the Flash swf just needs to state something to the effect of <param value="opaque" name="wmode" />.
The following is the precise code used to call my particular swf, reformers.swf:
<object height="150" width="920" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"> <param value="/media/reformers.swf" name="src" /> <param value="opaque" name="wmode" /> <embed height="150" width="920" wmode="opaque" src="/media/reformers.swf" type="application/x-shockwave-flash"></embed> </object>
I’m not sure how long this site will be in its current state, but for now at least, the following link should illustrate the meshing of the DHTML and Flash swf.
I really needed to be able to contain MXML markup code in my Flex blog, yet Wordpress MU (Multi-user) has some HTML and Javascript filtering in effect for security purposes. Since my blogs aren’t used by others, I figured it would be safe to disable that functionality, but it really is not the easiest thing to achieve.
I searched on Google and found a blog dealing with the matter at http://dev.robertmao.com/2007/07/18/get-rid-of-boring-wpmus-post-htmljavascript-filtering/. Since the blogger’s English wasn’t the greatest, I figured I can offer similar information here, hopefully, in a way that is easier to understand.
To achieve this, a very slight modification of one of WPMU’s (Wordpress Multi-user) PHP files, kses.php, which resides in the wp-include folder, will be necessary to achieve this. Using any plain text editor with a basic search function should suffice to edit the file.
Doing a simple text search of wp-include/kses.php for the word “filtering” should yield something similar to the following:
1028 1029 1030 1031 1032 1033 1034 1035 1036 | function kses_init_filters() { // Normal filtering. add_filter('pre_comment_content', 'wp_filter_kses'); add_filter('title_save_pre', 'wp_filter_kses'); // Post filtering add_filter('content_save_pre', 'wp_filter_post_kses'); add_filter('excerpt_save_pre', 'wp_filter_post_kses'); add_filter('content_filtered_save_pre', 'wp_filter_post_kses'); |
To remove the HTML/Javascript filtering, just comment out the add_filter lines below the // Post filtering by inserting a set of // backslashes, resulting in the following:
1028 1029 1030 1031 1032 1033 1034 1035 1036 | function kses_init_filters() { // Normal filtering. add_filter('pre_comment_content', 'wp_filter_kses'); add_filter('title_save_pre', 'wp_filter_kses'); // Post filtering //add_filter('content_save_pre', 'wp_filter_post_kses'); //add_filter('excerpt_save_pre', 'wp_filter_post_kses'); //add_filter('content_filtered_save_pre', 'wp_filter_post_kses'); |
As of this writing, the version of WPMU is 2.6.3, so these lines will reflect that version, though the search for the keyword “filtering” should still yield similar results in other versions.
With the drive of a starving coyote I scoured the internet, searching for a means of removing the drop down menu from the otherwise fabulous Dolphin CMS by Boonex. And with the luck of Wile E. Coyote, I failed miserably. Realizing that if it can’t be found on Google then it doesn’t exist, I knew that it must be created. So began my foray.
One method I’ve found for altogether removing the dreaded drop down menu (which is so eager to be partially hidden by flash swf animations) is to edit the general.css file which resides within the /templates folder structure. In the default template, this file is /templates/tmpl_uni/css/general.css. Replacing the tmpl_uni name with the name of the current template should suffice to find it.
To remove, or hide, the drop down menu, simply find the line in general.css which looks something like this:
.subMenu { background-image:url(../images/h_menu_bg.png);
And change it to something like this:
.subMenu { visibility:hidden; /*background-image:url(../images/h_menu_bg.png);*/
Really, all that is needed is the visibility:hidden; but the /* and */ are used to comment out the loading of the drop down menu’s background image so that visitor’s browsers don’t waste time and energy downloading an image that won’t be used.
For ease of use, I herein offer an altered general.css file from the default tmpl_uni template.
File: general.css
[EDIT: November 9, 2008]
WARNING: Over time I came to learn that the drop-down menu is very much needed for many of the basic features for Dolphin. Though there are workarounds, it’s far less troublesome to just keep the drop-down menu as it is. I’ll be working on a new post today detailing the simple method of having Flash swf files blend with the HTML elements on the page, so that the drop-down menu isn’t hidden behind it.