FlashBox v1.2: fixed error with comma in title

I came across a big bug in the caption. If you placed a comma in the title (which is used for caption) example: title=”bla, bla, bla” the image and the captions got hussled. I fixed this and added some new features (read more).

You can follow my progress in the Flashbox directory. A gallery example: Badass Robots used in film.

Download WordPress Plugin – Download FlashBox v1.2

If you have FlashBox v1.1 installed, you should delete the directory!

Download wp-FlashBox v1.2 wp-flashbox_v01.2.zip (20,1 kB)

ChangeLog FlashBox v1.2

  • Fixed: changed a minor bug created by v1.1 in css (inline style)
  • Fixed: comma in title bug (title=”bla bla, bla bla”)
  • Fixed: problems with Firefox 2 on Apple not really a solution [read more]
  • New: changed window.onload with domFunction to make it faster
  • New: [Flash] introduction of “thumbnail” navigation
  • New: [Flash] key navigation

Explanation:


domFunction
domFunction is an easy-to-use helper script, that allows other DOM scripting to run before window.onload; the practical benefit is that javascript doesn’t have to wait for images or other dependencies to finish loading anymore – it can begin as soon as the DOM is ready.
domFunction – by James Edwards [brothercake]

Key navigation

To resemble Lightbox just a little more, I’ve added keyboard navigation:

  • press “x” to close
  • press “n” or “→” (arrow right) to navigate to next image
  • press “p” or “←” (arrow left) to navigate to previous image

But because Flash is not the browser, you need to activate the .swf so it can “catch” keyboard instructions.
You need to click on the navigation first and then you can navigate with the keyboard.

Firefox 2 on the Mac bugs

Firefox on the Mac is a problem child with this project…

Version 1.0 revealed the first bug: FlashBox is not visible.
The solution to the problem seemed to be in the CSS:
I changed the transparency, the Flashbox was visible.

So this:

filter: alpha(opacity=60);
-moz-opacity: 0.6;
opacity: 0.6;

was changed into

background-image: url(../images/overlay.png); }
/* to make sure that IE 5.5 shows .PNG with alpha correct */
* html #overlay{ background-color: #000; background-color: transparent; background-image: url(../images/overlay.gif); filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="../images/overlay.png", sizingMethod="scale"); }

but I had to add a transparant (shadow) .PNG and a semi transparant .GIF
This bummed me out: this project was started to create a simple, enhanced version of lightbox

This fixed the visible bug, but created another:
Images of bug in Firefox 2 (Apple) [1] [2] [3]

So back to the drawing board.
Today I found the next bugs (not my bugs, but Mac Firefox 2 bugs ):

  • transparency with Flash in a layer above the normal page is not a possibility
    • so for ff2 apple is now a specific solution: no wmode=transparant
  • there can be no css-style with transparency in the html / css in the page where Flashbox is triggered
  • Flash embed can have no wmode=transparant if they are embedded in the page where Flashbox is triggered
    • FlashBox will move under the Flashfile if you change the wmode in the page that FlashBox trigger
    • NO flash in the page if you want it to work in Firefox 2 on the mac ….

Will this fix everything… well I would like to say yes.
But I see a rendering bug, when I scroll the browser.
Perhaps this is fixable in the Flash file itself, because it when you navigate to next img you will see everything.

    One thought on “FlashBox v1.2: fixed error with comma in title

    Comments are closed.