Cvermule

  • Subscribe to our RSS feed.
  • Twitter
  • StumbleUpon
  • Reddit
  • Facebook
  • Digg

Thursday, 23 March 2006

JavaScript Tip

Posted on 14:26 by Unknown
When dynamically creating an anchor in javascript, be sure to set not only the innerText (the text that appears between the open and closing tags), but also the innerHTML. Otherwise, if you try to view the said anchor in Firefox, it doesn't render.

Example:

var linkClose = document.createElement("A");

linkClose.href = "javascript:void(null)";
linkClose.innerText = "Close Window";
linkClose.innerHTML = "Close Window";
Read More
Posted in | No comments

Wednesday, 15 March 2006

Why Computers Sometimes Crash! by Dr. Seuss.

Posted on 07:07 by Unknown
If a packet hits a pocket on a socket on a port, and the bus is interrupted at a very last resort, and the access of the memory makes your floppy disk abort, then the socket packet pocket has an error to report.

If your cursor finds a menu item followed by a dash, and the double-clicking icon puts your window in the trash, and your data is corrupted cause the index doesn't hash, then your situation's hopeless and your system's gonna crash!

If the label on the cable on the table at your house, says the network is connected to the button on your mouse, but your packets want to tunnel to another protocol, that's repeatedly rejected by the printer down the hall...

And your screen is all distorted by the side effects of gauss, so your icons in the window are as wavy as a souse; then you may as well reboot and go out with a bang, 'cuz sure as I'm a poet, this whole sucker's gonna hang.

When the copy on your floppy's getting sloppy in the disk, and the macro code instructions's putting everything at risk, then you'll have to flash the memory and you'll want to RAM your ROM, and then quickly switch the power off and go and tell your Mom!

Well, that certainly clears things up for me. How about you?
Read More
Posted in | No comments

Tuesday, 9 August 2005

JavaScript Datepicker Test

Posted on 12:41 by Unknown
I've been looking for a good javascript calendar to use as a date picker. It's hard to find one that is as easy to implement as this one.



This calendar holds true to the "plug-n-play" mentality.
Read More
Posted in | No comments

Wednesday, 3 August 2005

Why Projects Fail

Posted on 12:32 by Unknown

  1. It takes one woman nine months to have a baby. It cannot be done in one month by impregnating nine women.

  2. Nothing is impossible for the person who doesn't have to do it.

  3. You can con a sucker into committing to an impossible deadline, but you cannot con him into meeting it.

  4. At the heart of every large project is a small project trying to get out.

  5. The more desperate the situation the more optimistic the situatee.

  6. A problem shared is a buck passed.

  7. A change freeze is like the abominable snowman: it is a myth and would anyway melt when heat is applied.

  8. A user will tell you anything you ask, but nothing more.

  9. Of several possible interpretations of a communication, the least convenient is the correct one.

  10. What you don't know hurts you

  11. There's never enough time to do it right first time but there's always enough time to go back and do it again.

  12. The bitterness of poor quality lasts long after the sweetness of making a date is forgotten.

  13. I know that you believe that you understand what you think I said, but I am not sure you realise that what you heard is not what I meant.

  14. What is not on paper has not been said.

  15. A little risk management saves a lot of fan cleaning.

  16. If you can keep your head while all about you are losing theirs, you haven't understood the plan.

  17. If at first you don't succeed, remove all evidence you ever tried.

  18. Feather and down are padding, changes and contingencies will be real events.

  19. There are no good project managers - only lucky ones.

  20. The more you plan the luckier you get.

  21. A project is one small step for the project sponsor, one giant leap for the project manager.

  22. Good project management is not so much knowing what to do and when, as knowing what excuses to give and when.

  23. If everything is going exactly to plan, something somewhere is going massively wrong.

  24. Everyone asks for a strong project manger - when they get them they don't want them.

  25. Overtime is a figment of the naïve project manager's imagination.

  26. Quantitative project management is for predicting cost and schedule overruns well in advance.

  27. The sooner you begin coding the later you finish.

  28. Metrics are learned men's excuses.

  29. For a project manager overruns are as certain as death and taxes.

  30. Some project finish on time in spite of project management best practices.

  31. Fast - cheap - good - you can have any two.

  32. There is such a thing as an unrealistic timescale.

  33. The project would not have been started if the truth had been told about the cost and timescale.

  34. A two-year project will take three years, a three year project will never finish.

  35. When the weight of the project paperwork equals the weight of the project itself, the project can be considered complete.

  36. A badly planned project will take three times longer than expected - A well planned project only twice as long as expected.

  37. Warning: dates in a calendar are closer than they appear to be.

  38. Anything that can be changed will be changed until there is no time left to change anything.

  39. There is no such thing as scope creep, only scope gallop.

  40. A project gets a year late one day at a time.

  41. If you're 6 months late on a milestone due next week but really believe you can make it, you're a project manager.

  42. No project has ever finished on time, within budget, to requirement

  43. Yours won't be the first to.

  44. Activity is not achievement.

  45. Managing IT people is like herding cats.

  46. If you don't know how to do a task, start it, then ten people who know less than you will tell you how to do it.

  47. If you don't plan, it doesn't work. If you do plan, it doesn't work either. Why plan!

  48. The person who says it will take the longest and cost the most is the only one with a clue how to do the job.

  49. The sooner you get behind schedule, the more time you have to make it up.

  50. The nice thing about not planning is that failure comes as a complete surprise rather than being preceded by a period of worry and depression.

  51. Good control reveals problems early - which only mean you'll have longer to worry about them.

Read More
Posted in | No comments

Tuesday, 2 August 2005

Abbott & Costello's Purchase a Computer

Posted on 12:40 by Unknown
Costello Wants to buy a Computer from Abbott and phones his store:

ABBOTT: Super Duper computer store. Can I help you?
COSTELLO: Thanks. I'm setting up an office in my den, and I'm thinking about buying a computer.

ABBOTT: Mac?
COSTELLO: No, the names Lou.

ABBOTT: Your computer?
COSTELLO: I don't own a computer. I want to buy one.

ABBOTT: Mac?
COSTELLO: I told you, my names Lou.

ABBOTT: What about Windows?
COSTELLO: Why? Will it get stuffy in here?

ABBOTT: Do you want a computer with windows?
COSTELLO: I don't know. What will I see when I look in the windows?

ABBOTT: Wallpaper.
COSTELLO: Never mind the windows. I need a computer and software.

ABBOTT: Software for windows?
COSTELLO: No. On the computer! I need something I can use to write proposals, track expenses and run my business. What have you got?

ABBOTT: Office.
COSTELLO: Yeah, for my office. Can you recommend anything?

ABBOTT: I just did.
COSTELLO: You just did what?

ABBOTT: Recommend something.
COSTELLO: You recommended something?

ABBOTT: Yes.
COSTELLO: For my office?

ABBOTT: Yes.
COSTELLO: OK, what did you recommend for my office?

ABBOTT: Office.
COSTELLO: Yes, for my office!

ABBOTT: I recommend office with windows.
COSTELLO: I already have an office and it has windows! OK, lets just say,I'm sitting at my computer and I want to type a proposal. What do I need?

ABBOTT: Word.
COSTELLO: What word?

ABBOTT: Word in Office.
COSTELLO: The only word in office is office.

ABBOTT: The Word in Office for Windows.
COSTELLO: Which word in office for windows?

ABBOTT: The Word you get when you click the blue "W."
COSTELLO: I'm going to click your blue "w" if you don't start with some straight answers. OK, forget that. Can I watch movies on the Internet?

ABBOTT: Yes, you want Real One.
COSTELLO: Maybe a real one, maybe a cartoon. What I watch is none of your business. Just tell me what I need!

ABBOTT: Real One.
COSTELLO: If its a long movie I also want to see reel 2, 3 & 4. Can I watch them?

ABBOTT: Of course.
COSTELLO: Great, with what?

ABBOTT: Real One.
COSTELLO; OK, I'm at my computer and I want to watch a movie. What do I do?

ABBOTT: You click the blue "1."
COSTELLO: I click the blue one what?

ABBOTT: The blue "1."
COSTELLO: Is that different from the blue w?

ABBOTT: The blue 1 is Real One and the blue W is Word.
COSTELLO: What word?

ABBOTT: The Word in Office for Windows.
COSTELLO: But there's three words in "office for windows"!

ABBOTT: No, just one. but its the most popular Word in the world.
COSTELLO: It is?

ABBOTT: Yes, but to be fair, there aren't many other Words left. It pretty much wiped out all the other Words out there.
COSTELLO: And that word is real one?

ABBOTT: Real One has nothing to do with Word. Real One isn't even part of Office.
COSTELLO: Stop! Don't start that again. What about financial bookkeeping you have anything I can track my money with?

ABBOTT: Money.
COSTELLO: That's right. What do you have?

ABBOTT: Money.
COSTELLO: I need money to track my money?

ABBOTT: It comes bundled with your computer.
COSTELLO: What's bundled to my computer?

ABBOTT: Money.
COSTELLO: Money comes with my computer?

ABBOTT: Yes. No extra charge.
COSTELLO: I get a bundle of money with my computer? How much?

ABBOTT: One copy.
COSTELLO: Isn't it illegal to copy money?

ABBOTT: Microsoft gave us a license to copy money.
COSTELLO: They can give you a license to copy money?

ABBOTT: Why not? THEY OWN IT!

(LATER ON)

COSTELLO: How do I turn my computer off??
ABBOTT: Click on "START"..........
Read More
Posted in | No comments

Wednesday, 29 June 2005

Selecting specific objects on a Hibernate Query Join

Posted on 12:36 by Unknown
I ran into a problem when I was trying to select specific columns from multiple tables in a join. I was having trouble casting the returned fields into an object type.

I thought that I would share the two different solutions that I came up with when I found in the Hibernate documentation.

Let me know if you have questions...since I just found this, I may or may not be able to answer it, but I'll try.

Queries may return multiple objects and/or properties as an array of type Object[]

select mother, offspr, mate
from eg.DomesticCat as mother
inner join mother.mate as mate
left outer join mother.kittens as offspr


When this is done, you have to iterate over the Object array and cast it back into the object type that each one is and call the constructor of
the item you are using.

for (Iterator lIterator=lFamilyList.iterator();
lIterator.hasNext();)
{
Object[] lObjectArray = (Object[]) lIterator.next();
Family lFamily = new Family((String) lObjectArray [0],
(String) lObjectArray [1],
(String) lObjectArray [2]);
System.out.println("Mother: " + lFamily.getMother());
System.out.println("Mate: " + lFamily.getMate());
System.out.println("Offspr: " + lFamily.getOffspr());
}

or as an actual typesafe Java object

select new Family(mother, mate, offspr)
from eg.DomesticCat as mother
join mother.mate as mate
left join mother.kittens as offspr


When this is done, you just have to cast it back to it's appropriate class when you iterate.

   for (Iterator lIterator = lFamilyList.iterator();
lIterator.hasNext();)
{
Family lFamily = (Family) lIterator.next();
System.out.println("Mother: " + lFamily.getMother());
System.out.println("Mate: " + lFamily.getMate());
System.out.println("Offspr: " + lFamily.getOffspr());
}

assuming that the class Family has an appropriate constructor.
Read More
Posted in | No comments

Wednesday, 8 June 2005

EL OR LA COMPUTER

Posted on 14:45 by Unknown
A Spanish teacher was explaining to her class that in Spanish, unlike English, nouns are designated as either masculine or feminine.

"House" for instance, is feminine: "la casa."

"Pencil," however, is masculine: "el lapiz."

A student asked, "What gender is 'computer'?"

Instead of giving the answer, the teacher split the class into two groups, male and female, and asked them to decide for themselves whether "computer" should be a masculine or a feminine noun.

Each group was asked to give four reasons for its recommendation.

The men's group decided that "computer" should definitely be of the feminine gender ("la computadora"), because:

  1. No one but their creator understands their internal logic

  2. The native language they use to communicate with "other computers" is incomprehensible to everyone else

  3. Even the smallest mistakes are stored in long term memory for retrieval later

  4. As soon as you make a commitment to one, you find yourself being changed by them "for the better".


The women's group, however, concluded that computers should be Masculine ("el computador"), because:

  1. In order to do anything with them, you have to first get their attention, and then turn them on

  2. They have a lot of data but still can't think for themselves

  3. They are supposed to help you solve problems, but half the time they ARE the problem

  4. As soon as you commit to one, you realize that if you had waited a little longer, you could have gotten a better model.


The women won.
Read More
Posted in | No comments
Newer Posts Older Posts Home
Subscribe to: Posts (Atom)

Popular Posts

  • My approach to drop down menus using JavaScript
    Drop down menu <div> <iframe></iframe> <div></div> </div> Hide outer div by setting the Style.Visibility...
  • Can you use JavaScript to read and write to a file?
    Now I was searching high and low for the answer to this question. The big answer that I got was, JavaScript cannot read or write to files. H...
  • Musicovery
    I found this site courtesy of http://www.i-am-bored.com . The name of the site is Musicovery . This is a site where you can listen to musi...
  • EL OR LA COMPUTER
    A Spanish teacher was explaining to her class that in Spanish, unlike English, nouns are designated as either masculine or feminine. "H...
  • The candidates from a Web Developer's perspective.
    Obama is RESTful » Idol Hands: Days in the Life of an Alpha Geek I'm sorry to include just a link, but it's not my posting so I'...
  • Oracle Tuning
    For most efficient access, the order that tables are specified can make a difference. The optimiser will re-order table access based on the ...
  • Eclipse can detect null pointer reference
    Eclipse has the ability to detect null pointer reference but it's not enable by default. To do so, go to the preferences. In the Java...
  • Introducing...
  • Programmer's Genesis
    1. In the beginning GOD created the Bit and the Byte. And from those he created the Word. 2. And there were two Bytes in the Word; and not...
  • Capturing the close event.
    When programming a thin-client application using HTML and JavaScript and you want to capture the closing event, it is not as easy as one thi...

Categories

  • amazon
  • browser specific
  • coding
  • Eclipse
  • error
  • example
  • funny
  • google
  • grep
  • hacks
  • javascript
  • jott
  • music
  • null
  • phone
  • search
  • search engine
  • tip
  • tool
  • unix
  • web development
  • yui

Blog Archive

  • ▼  2008 (5)
    • ▼  September (1)
      • The candidates from a Web Developer's perspective.
    • ►  August (1)
    • ►  July (1)
    • ►  June (1)
    • ►  January (1)
  • ►  2007 (6)
    • ►  December (1)
    • ►  September (1)
    • ►  July (1)
    • ►  June (1)
    • ►  March (2)
  • ►  2006 (10)
    • ►  November (1)
    • ►  August (1)
    • ►  May (2)
    • ►  April (4)
    • ►  March (2)
  • ►  2005 (10)
    • ►  August (3)
    • ►  June (2)
    • ►  February (5)
  • ►  2004 (9)
    • ►  October (2)
    • ►  September (7)
Powered by Blogger.

About Me

Unknown
View my complete profile