Category: Web Building

JW FLV player with Javascript playlist

Screen shot 2009-12-17 at 1.06.07 PM.jpg

This is an example of how to create a javascript-based Playlist selector for a JW FLV player. The playlist selector menu has 3 sections that toggle open and closed when you click on them. This allows the user to switch playlists, choosing from various topics.

The source code has not been cleaned up, but you should be able to get an idea of how to set this up from it.

Continue reading

jQuery UI Accordion does not function in IE7/WinXP

The Accordion is one of the handy interface widgets that can be generated using jQuery UI. There are several optional settings you can add into the function call, including animation, auto-height, etc. If you find it is not working on IE7try adding “animated:false” as one of the options.

If you are running a debugger on IE, and see the error “invalid option on line 486” this is definitely the problem.

Screen shot 2009-12-10 at 12.37.41 PM.jpg

Continue reading

.htaccess: allow anyone from one IP but require password from everywhere else

If you want your linux-hosted site to be accessible by anyone coming from a particular IP address, as say from within a corporate firewall, but also accessible from anywhere else as long as they authenticate with username and password, use this formula in the .htaccess file for the directory:

#this section may need to be modified to suit your password authentication setup:
AuthUserFile "/home/pathTo/.htpasswds/directory_name/passwd"
AuthType Basic
AuthName "webroot"
require valid-user
# allow users from inside firewall
Allow from 111.222.33
Satisfy Any
Continue reading

Make a Movie Clip on the Stage appear above a dynamically loaded Movie Clip

A while back, I worked on a flash game that teaches medical professionals how to find objects in a cardiac cart. A cart with 6 drawers isshown at left. When a drawer is clicked, it slides in from the top of the screen so that all the objects inside can be seen. The object of the game is to drag whichever object has been selected at random to a target at bottom right.

The original design allowed plenty of room for the drawers to move down to their open position without obscuring the target area.

But as time went on and more requirements came to light, the dimensions of the game had to be shortened so that the drawer overlapped the hand target when it was in its “open” position.

Continue reading