View Portfolio View Links to Web Related Help View Web Development Code Samples View Shawn Lambert's Resume
You are in the Code Library section
JavaScript
Note: Due the nature of programming languages, the changes in browsers and my lack of dilligence in transferring these samples not all of this code may work. Rest assured it did at one time.
Simple Browser Detection Code
Detects web browser brand and version. Helpful for inconsistancy between browsers.
Cascading Menu
This is the best dynamic/cascading menu system I have found to date. it is relatively easy to modify and allows for all kinds of style changes through its stylesheet, plus it is multi-browser compatible.
News Ticker
These news tickers were popular once. I doubt that with bandwidth increases and Flash that anyone would want to use one any more.
Pop Menu
This is the same as Cascading Menu Code only it used a text link in place of an image.
Pop Up Windows
Ahh, what would we do without pop-ups.
Simple Image Roll-Over
Roll-overs are still cool, I don't care what anyone says. I do agree they should be more subtle.
Screen Resolution Detection
This can be helpful in detecting users screen resolution. It used to be that you new emphatically that 800x600 was kosher. Now with the advent of LCD's and CRT's of all sizes the resolution gambit is spread so that almost no category has more than 25%, which makes determining the Lowest Common Denominator frustrating.
Screen Resolution Detection Advanced
This bit of code actually determines the size rather than throwing a function based on parameters, like the one above does.
Perl
Note: Due the nature of programming languages, the changes in browsers and my lack of dilligence in transferring these samples not all of this code may work. Rest assured it did at one time.
Simple Random Number Generator
Simple random number generator. You'd be surprised at how often you can use these little gems.
Java
Note: I usd to have about 10-12 Java applets and applications... which I did back in 1998-1999. They were stored on floppy discs. As I went to post them, they all seemed to be corrupt, half the code missing in most cases. The one below is all that survived in its entirety. I will eventually rewrite the code for posting here, although I doubt I will recompile them.
Simple Password Protection
This isn't a very secure way to password protect as someone could just download your class file and decompile your code to get the password... which for the sake of my sample is "entermywebsite".
Lingo
Note: Since Lingo is written in-frame in most cases I have supplied the .dir files so you can look at my code (if you have Director).
45's Card Game
This adaptation of the game 45's (a very local game, but loved by many... locally) using Director and Lingo. I was never able to figure out the AI for this. But the program does the following for 4 people: Shuffle, deal, remove appropriate cards from an array (which I made visible), deals a kitty, if the human player bids it allows you to choose cards to keep and subsequently redeals up to 5 cards. The program also allows you play a card, but that's where it fails. I got the AI to make plays based on heirachy, but I could not resolve the problem of subtle play.
CSS / Website Style Concerns

Note: I've gotten a lot of interest/questions about accessibility and DIV design versus table design. Obviously, we follow WC3 as closely as we can, but consider these points: 1. Not all Broswers are yet 100% CSS compliant 2. You still cannot do everything with a DIV that you can with a Table (I plan to prove it here when I get some time) 3. Beauty is visual and if you want to compromise on what the user sees, for the sake of a few users' accessibility, then you will have to comprimise on the beauty of the design and sometimes on the functionality.

That being said most of the accessibility recommendations out there are very vaild and should be considered in any design.

EM to Pixel to Point Conversions Table
I have generated a small chart for visual reference for those wishing to switch to em from px and pt sizes. Keep in mind that users who deifne their own font sizes will destroy your design if you define your fonts using em sizing. Some people argue for using relative sizes of page layout (ie width="100%" vs width="800") to compensate for this factor. I have found nothing but trouble when using the former in regards to width. And make no mistake, the impact of the user on a broken site is the same as one that has a hard time readin the fonts.
© 1997-2006 Electric Designer. On the web since 1997.
All logos are property of their respective owners.
All images, or text on this site cannot be used without expressed permission.