Archive for March, 2002
AntiJavascript
Thursday, March 28th, 2002gilmae mentioned this in a comment, and I give examples of why I’m stripping things from comments in comments, It Doesn’t Work. So here it is, The Problem With HTML.
First, some more basic problems. Aquarionics, being Neat, Cool, and generally Compliant, uses CSS for layout. It consists of various sections, set out in the code as <div> (DIVision) tags. This, for example, is in #content, which is slightly overlapping #header which contains the sweeping-curve logo. To the right is #cool containing Neatothings from the rest of the site. If I allowed all HTML in comments, someone could put in a few <div> tags and completely ruin the layout and readability of the site. Bad.
The same problem applies for Table-based designs with </td> tags. Those can really ruin someone’s day. So, HTML Bad.
PHP has a nice function called striptags(), which strips all HTML tags from a post except the ones you specify. “So don’t specify <script>” is the wise call, but it’s not that easy, because Javascript can be inside any normal tag. For example, I could have something in italics like this:
<em onMouseOver=“window.alert(‘Hah! You Lose!’)”>Go on. Touch me. I dare you, I double-dare you. I double plus infinity dare you</em>
Go on. Touch me. I dare you, I double-dare you. I double plus infinity dare you
Which isn’t exactly the end of the world, but it could be worse. I mean, it *could* be…
<em onMouseOver=“document.location=’http://www.goat.cx’”>Go on. Touch me. I dare you, I double-dare you. I double plus infinity dare you</em>
Go on. Touch me. I dare you, I double-dare you. I double plus infinity dare you
Or worse…
<em onLoad=“document.location=’http://www.goat.cx’”>Go on. Touch me. I dare you, I double-dare you. I double plus infinity dare you</em>
(No, I’m not putting that code in :-)
And those codes will not get stripped out. The latest version of striptags() cuts out all “alert” type Javascript, but doesn’t recognise the more simple kind that changes an innocent variable. Like the document.location. So no HTML.
Oddness
Wednesday, March 27th, 2002So, it’s been a strange week. Well, seven days.
I mean, Thursday I went to see a play with my long-standing mate Barry, and my not-quite-so-long-standing Drama Teacher, which was nice. And it spoke in rhyme, and had Martin Clunes in it, and was actually very, very funny.
Later that day, I was dragged into a gay bar in Soho (Okay, I walked in calmly. It’s not as if I was unaware of where I was going). This is another thing entirely, however, and one I just mention in passing.
As it were.
Then came today. Today I will not even attempt to explain, but revolved around me walking out of a bank with a grand more than I thought I owned (Go Me) Straight into the push-chair of someone I knew vaguely from school. She was (still is, I suppose) a couple of years below me, just over 19
She’s married. And has a four month old kid whose name – I think, I was a little dazed – is Smidge.
Scariness
So I wandered back to the station, and ran into someone who I was at school with, who is now working for a local clothes shop as a Person Who Lifts Stuff, as far as I can gather. I told them both I was doing freelance web design, which is technically true. Eventually I admitted the lie to the first, who sagely handed me an application form for the local Unwins (Off-license) and informed me that McDonalds down the road were hiring.
Never have I been more motivated to find a job.
Walked – nay, ran – to the train station, avoiding eye contact with everyone on the street just in case it was another blast from the past.
Ordered the Moulin Rouge soundtrack and DVD from Amazon (Didn’t preorder Buffy 4 DVD. self control 1, Buffy Nil) and finally sent off for my Discworld Convention Membership. And I’m *still*
Job Seek
Monday, March 25th, 2002From an email today:
Windows’ Developer (Permanent)
Our client, named by a leading national daily
broadsheet as ONE OF BRITAIN’S MOST VISIONARY
COMPANIES, needs a commercially focused Software
Engineer with a difference!!!
*snip*
you’ll be delivering
tomorrow’s applications today, eradicating
Flash. Ahhhhhh
Monday, March 25th, 2002So I was given a copy of Flash, Dreamweaver, Director, and all those other things I should not, as a Real Coder, ever use. But I use PHP, I am competant in Visual Basic, and this is being written in Windows. Obviously I’m not a Real Geek.
So today, I have mostly been learning Flash. And in doing so have created a monster. Well, this, anyway. No, it isn’t finished. Yet. It’s broken in a couple of ways, but I’m working on it, promise…
Yup, the eggs are gone. The site went down, and it was only slowing the site down anyway. This month’s appeal is a whole new one. Go visit it… (Editors note, the site seems to be down, so the icon is gone for the moment. It will return)
In other things, I’m still searching for jobs, and no hope for that as yet. Looking forward to next weekend, when I get to see Lonecat again. Fun
Disclaimer
Sunday, March 24th, 2002This is the disclaimer for SimExplorer. I liked it. Here it is:
By reading this comment, you agree to sell your first-born to Bil Simser of Calgary, Alberta, Canada, Earth and you agree not to quack like a duck while reading this comment. If it is discovered that you have quacked like a duck during the reading of this comment at any time, I reserve the right to sue you for damages. Damages, in this case, may be interpeted as all your money, your clothes, any first born children, your eternal salvation if you believe in such a thing, and anything else I can get away with.
You may not make illegal copies of this comment. Illegality of copies is determined by the laws of Estonia-on-Avon, a small principality covering approximately one half acre somewhere in Southern Alberta. A copy of these laws may be obtained by visiting Estonia-on-Avon, and asking Prince Bil to write down a copy for you. Punishment for illegal copies will also be left up to the Prince. You may not reverse engineer this software to attempt to discover the source code for use in your own products. If you wish to make modifications of this product, please contact me for further info. Infractions of this clause will lead to visit by a large man named Guido at late hours of the night.
This comment must be destroyed within 30 minutes of reading under full penalty of International law. You will be held responsible if this comment is not removed at the end of the appropriate time period. This agreement is not applicable in the states of New Jersey, Maryland, and Delerium or anywhere on the planet Earth.
This software is intended for individual use and may contain information that is confidential, privileged or unsuitable for overly sensitive persons with low self-esteem, no sense of humor or irrational religious beliefs. If you are not the intended recipient, any dissemination, distribution or copying of this software is not authorized (either explicitly or implicitly) and constitutes an irritating social faux pas.
Unless the word absquatulation has been used in its correct context somewhere other than in this warning, it does not have any legal or no grammatical use and may be ignored. No animals (especially moose) were harmed in the making of this software, although the cat next door is living on borrowed time, let me tell you. Those of you with an overwhelming fear of the unknown will be gratified to learn that there is no hidden message revealed by reading this warning backwards, so just ignore that Alert Notice from Microsoft.
However, by pouring a complete circle of salt around yourself and your computer you can ensure that no harm befalls you and your pets. If you have received this software in error, please add some nutmeg and egg whites, whisk and place in a warm oven for 40 minutes.
Are you still reading this? Don’t worry, I said this agreement is not applicable anywhere on the planet Earth so unless you’re installing it from the International Space Station, there’s nothing to get your pantyhose in a knot about. I will not be coming to your house and taking your children, however, if you have a daughter of legal age and pretty cute to boot then we should talk.
blueprint, and all its components and related programs, is free software but copyright 1999-2002 by Bil Simser. All rights reserved worldwide, so there. It is a labor of love by me. You are hereby entitled to use, mangle, obfuscate, and generally make use of the program as you see fit. You may NOT re-distribute or otherwise deploy this software as part of a compilation CD for profit without the express written consent of me.
No guarantees whatsoever are inferred. If blueprint doesn’t work: tough. If you lose a million bucks because blueprint messes up, it’s you that’s out the million, not me. If blueprint impregnates your cat, too bad. If you don’t like this disclaimer: tough. I reserve the right to do the absolute minimum provided by law, up to and including nothing. You may decline this agreement by going somewhere else and forgetting you ever were here. By using this software, the user hereinafter agrees to abide by all the terms and conditions of the this agreement that nobody ever reads anyway, as well as the Geneva Convention and the U.N. Charter and the Secret Membership Oath of the Benevolent Protective Order of the Moose people and such other terms and conditions, real and imaginary, as I shall deem necessary and appropriate, including the right to come to the user’s home and examine the user’s hard drive, as well as the user’s underwear drawer if I feel like it, raid your icebox, swim in your pool, take it or leave it, until death do us part, one nation indivisible, by the dawn’s early light, finders keepers, losers weepers, thanks you’ve been a great crowd, and don’t forget to tip your servers.
Violations of this license will be punishable by fine, imprisonment, death, any two of the above, or all three.
blueprint is designed, written and pretty much completely owned by me, Bil Simser, keeper of the sacred crown holy crown of cheese.
All Your Sims are Belong to Us.