Categories
Contact Doug!
Learn About Doug!
View Doug Boude's online resume
updated 11/18/2009

View Doug Boude's profile on LinkedIn
Link to me!

Follow Doug Boude on Twitter
Follow me!

Be Doug's friend on Facebook
Befriend me!
(I promise not to follow you home)
OO Lexicon
Chat with Doug!
Recent Entries
You may also be interested in...
Web Hosting

<< March, 2009 >>
SMTWTFS
1234567
891011121314
15161718192021
22232425262728
293031
Search Blog

Recent Comments
Re: My Top 20 Life Lessons for Boys and Young Men (by jeffrey scott berry at 9/16 2:42 PM)
Re: Equivalent of SQL "TOP X" in Oracle (by Mark Foster at 7/07 4:04 PM)
Re: SQL Forward Engineering with Visio 2003 Professional (by Thomas at 6/26 4:41 AM)
Re: One Shot Query to Recalculate Orderby Field - MySQL (by gary at 6/17 6:46 PM)
Re: DON'T GET SICK IN ARKANSAS! (by r. wood at 5/25 12:00 AM)
Re: SQL Forward Engineering with Visio 2003 Professional (by Andrew at 4/30 6:14 AM)
Re: Basic Ajax Select List Filter in PHP (by good at 2/04 5:26 AM)
Re: Family Law: The Weapon of Choice for Woman Scorned (by swalker at 2/03 2:15 AM)
Re: Approaches to Building Strings: The Imploding Array (by bantal silikon at 2/01 9:44 PM)
Re: Disappearing IE Popup Window During Save/Open Dialog (by AddisonDean at 1/15 9:59 AM)
Re: My Top 20 Life Lessons for Boys and Young Men (by Alex at 1/13 8:45 PM)
Re: Array Loop Modifications in CFSCRIPT (by Alex at 11/25 11:18 AM)
Re: Array Loop Modifications in CFSCRIPT (by Abram at 11/14 11:32 PM)
Re: Recursive Functions in ColdFusion (by Dwayne at 10/25 3:47 PM)
Re: Porting Coldfusion Code to Mura (by dh at 10/16 10:14 AM)
Re: Viewing Option Text (in IE7) that's Wider than the Select List (by Devil May Cry at 9/26 1:38 AM)
Re: Why I Hate ORMs (a solicited rant) (by guideX at 9/12 11:38 PM)
Re: Recursive Functions in ColdFusion (by KP at 8/08 7:13 PM)
Re: American Airlines, YOU SUCK! (by Alison at 7/23 4:48 PM)
Re: SQL Forward Engineering with Visio 2003 Professional (by Harshad at 7/11 9:17 AM)
Archives
Photo Albums
Funnies (5)
Family (3)
RSS

Powered by
BlogCFM v1.11

30 March 2009
Changing Scriptaculous' Sortable ID Parser

My scenario:

I'm using Scriptaculous and CF8 to create a "stacked" PDF based on a user's re-ordering of a list of uploaded files (you can check out the live app here). In order to do this simply, I'm making the file name part of the sortable list item's ID value, like so: ID="file~#filename#" . Well, Scriptaculous has a built in way of dealing with sortable item ID values, where it's looking for some text followed by an underscore followed by a numeric value. In order to break away from this assumption, the latest version of Scriptaculous (1.8.2) offers an option called "format" that allows you to specify a regular expression to override the default one.

So, here's my code that creates the unordered list of files:

   <cfdirectory action="list" directory="#uploadedfiles#" name="qryFiles" />
   <div id="filelist">
    <ul id="filestack">
     <cfoutput query="qryFiles">
      <li id="file~#name#" class="fileitem" ext="#listlast(name,".")#">#name#</li>
     </cfoutput>
    </ul>
   </div>

and here's the JS I use to turn this list into a sortable:

Sortable.create('filestack',{format:/^file~(.*)$/});

Executing the following JS will show you that the regex is correct:

alert(Sortable.sequence('filestack'));

Not hard stuff, but it took me a while to piece it all together so I thought I'd share in case it saves someone else a little time.

Posted by dougboude at 11:30 AM | PRINT THIS POST! | Link | 0 comments



13 March 2009
Hey, Did You Catch South Park Last Night?
Die Disney, Die

I can't tell you how excited I was last night when I saw the previews for South Park and saw that the Disney Channel and the Jonas Brothers had found their way into the crosshairs of the South Park writers! I myself have been a long time HATER of the Disney Channel, despising its infinitely flowing pre-pubescent stream of sickening, mind numbing garbage that's as incoherent and directionless as the pre-pubescent kids who are addicted to sucking on Walt Disney's grotesque lactating channel. And so I savored every single moment of last night's South Park, shouting out as many "hoo RAH"s and "YEAH!"s as laughter.

If you didn't catch it, let me summarize it for you.

Micky Mouse is a tyrannical mobster who turns larval human beings (teenagers) into icons and idols for girls and boys who are aware that they have genitals but don't quite know what they're for just yet. He gives the closet liberals an excuse to let the TV babysit their children by coating the adolescent inuendos, potentially compromising boy-girl scenes, and "near kiddie porn" with a thin layer of "just say no". In this scenario, Micky has groomed the Jonas Brothers to get the little girls' vaginas all tingly, only to turn around and encourage those same confusedly horny pupal girls to take vows of chastity until their wedding night. The Idiot Brothers try to take a stand against Mobster Mouse only to be beaten down like the skanky ho's they are, until Micky accidentally reveals his true objectives to the general public and is rejected...at least until the closet liberals have had a night to think it over or just plain forget what they heard.


The only thing I WISH SO BADLY that this episode would have included is some reference to Hanna Montana. If only in effigy, I would PAY to see that blossoming, overrated, overpaid skank taken out of existence! There are few things in history, life, the earth, and the entire universe I could think of that have lesser value than one nanosecond of Hanna Montana and the gelatinous hodge podge of random stupidity she spews in between the artificial studio-generated laughter that erupts every 8 seconds (on average...I've timed it). And what's even more sickening is the fact that the children...the up and coming next generation...they're addicted to it. I shudder to think what the product of a general diet of Disney Channel on a daily basis will be when these kids DO hit puberty!

Yeah, you can probably tell that I despise the Disney Channel. A lot.

Disney, please just die.

Doug out.

Posted by dougboude at 10:53 AM | PRINT THIS POST! | Link | 7 comments
12 March 2009
Easy Way to Grab Remote SQL Data

Okay, this is just too cool so I thought I'd share it.

Let's say you have access to a database on a remote server somewhere, and there's data there that you would love to have a copy of locally. Options, options, options...well, if we aren't using SQL Express we have lots of options for migrating the data. But in our case, we ARE using SQL Express, so we don't have easy access to linking servers and other more advanced commands. Wouldn't it be just perfect then if we could simply do a SELECT * INTO MyNewLocalTable from [remote table]? Turns out that I CAN if I turn on an option that is turned off by default. So first, I execute these two lines in a query window (I'm using SQL Server Management Studio Express):

sp_configure 'Ad Hoc Distributed Queries', 1
RECONFIGURE

 

Then, I execute THIS query (well, one like it with suitable values substituted):

SELECT * INTO MYDATABASE.dbo.MyNewTable
FROM  OPENDATASOURCE(
   'SQLOLEDB',
   'Data Source=[url to remote server here, including port if needed];User ID=[sql username];Password=[sql password]'
   ).REMOTEDATABASE.dbo.SourceTable

 

Worked like a charm! Now I have a local copy of the remote data. In my case I migrated a little over 80,000 rows and it took about a minute or less. Saweeeet.

Doug out.

Posted by dougboude at 5:47 PM | PRINT THIS POST! | Link | 34 comments
09 March 2009
Using Fireworks CS4 for Interface Driven Development
For those who are interested, I gave a 45 minute presentation at the Alamo Area CFUG last week on using Fireworks CS4 as a supplement to the Interface Driven Development methodology. I'm by no means an expert, but I do believe that what I've learned over the last several weeks might prove beneficial to other developers, especially those who are "one man shows" building products from the ground up. Oh, and a special shout out to Dee Sadler, whose gracious sharing of knowledge pointed me in the right direction.

Useful links are given at the end of the recording that point to add ons required to do some of the things I demo'd. Also, Connect didn't do a very good job at keeping video and audio in sync, so the audio tends to be ahead of the video by a few seconds.

Hope you find it helpful!

Doug out.
Posted by dougboude at 3:47 PM | PRINT THIS POST! | Link | 2 comments
02 March 2009
Gotta Give Adobe Kudos for Persistence!
My trial version of Fireworks CS4 expired yesterday, so I went to the Adobe store to explore upgrade possibilities from version MX2004. I was greeted by a very nice (but suspiciously semi-robotic) sales associate named (also suspiciously based on some of the english) "Randy". I found some humor in Randy's blatant insistence that I make my purchase RIGHT NOW, so thought I'd share the short thread. In the following conversation, I am "Visitor".... Enjoy!

Please hold as we route your chat to an Adobe Representative.
Welcome to Adobe.com! My name is Randy. May I assist you with your selection today?

Randy: Hello, how can I help you?
Visitor: i'm wondering if i can upgrade to fireworks cs4 from fireworks mx2004
Randy: Hi there.
  (long pause here...)
Randy: I'll be glad to help you with that.
  (another long, long pause here...)
Randy: Let me check that for you.
  (yet another long pause...)
Randy: You can upgrade from Fireworks MX 2004 to Fireworks CS4 for US $149.
Randy: Shall I forward direct link to upgrade it?
Visitor: yes, thank you
Randy: Okay.
Randy: Please click here to view the purchase link for 'Fireworks CS4 '.
Randy: Please go ahead with the order processing and let me know if you need any help.
Randy: I'll standby to hear the order number and the total order value since it helps me to verify the order and confirm that the order has gone through successfully.
Randy: Please let me know if you need any help.
Randy: Is that okay?
Visitor: i won't be ordering today. have to route it through purchasing.
Randy: I request you to place the order now. Since it helps me to verify the order and confirm that the order has gone through successfully.
Randy: It will take only few minutes to complete the order process successfully..
Randy: If you wish, I'll stay online and provide any information needed which may help you to take the decision.
Visitor: i won't be ordering today. have to route it through purchasing.
Randy: If you wish, I'll stay online while you discuss to get the approval and provide any information needed which may help you to take the decision.
Visitor: everybody has gone home for the day. There's nobody for me to discuss it with at this time.
Randy: Okay, please contact us on this live chat when you're ready to buy. We will be happy to help you.
Randy: I'm happy to help you. Do you have any other questions for me?
Visitor: no thank you
Visitor: but I appreciate your nagging persistence.
Randy: You're welcome. It's my pleasure to help you today.
Randy: Thank you for visiting Adobe.com today! We'd like to hear your comments. Please click on the 'Close' button in the upper right corner and take a moment to complete a short survey. Thank you!
Posted by dougboude at 6:53 PM | PRINT THIS POST! | Link | 3 comments