Category — Web Dev
Dreamweaver CS4 Copy/Paste Bug Workaround
If you are working with Dreamweaver CS4 and find that you have weird select – copy – paste problems, then read on.
Ever been working in code view and find that trying to highlight and copy any text (either ctrl-c or right click>copy) suddenly results in the entire page or code block you are working in being selected? Yeah, me to – and it has made me FURIOUS, going on 3 or 4 months now.
The only way I was able to get it to STOP doing that was to click somewhere in the code editor and make a change in the doc – like clicking Enter to make a new blank line and then deleting it again. Once the file was “touched” like that, copy again worked correctly. While this worked, it was EXTREMELY annoying, because it happened every single time I opened a bit of code that I wanted to grab a snippet from. Constantly clicking and making changes in files that I really didn’t want to change, only to start forgetting which ones I really wanted to save… Oh, how I loathed the day I upgraded from CS3!
Well, I’m glad to announce that I found a way to fix the stupid problem – not permanently – but at least I don’t have to use the stupid file change method anymore.
It appears that the problem is due to “workspace” issues. A CS4 Workspace is essentially a screen layout configuration that you can customize and save and return to at any point. For example, you may want certain windows open when you are writing your code, and other windows open when you are debugging the code, etc. CS4 ships with several neat Workspaces out of the box – I’ve primarily used the “Dual Screen” workspace for most of my time in the app. Well apparently something in the Workspace config gets borked and causes this problem.
To Fix the Problem:
- First, select the “Classic” Workspace and let the windows reconfigure themselves. The easiest way to do this is to select a new Workspace from the upper right hand side of the top of your Dreamweaver window, as seen below.
- Second, change back to your preferred workspace (like “Dual Screen” in my case) and the problem will be gone!
Now, be advised that it may show up again in a few weeks or a few days, or never – I don’t know. It doesn’t seem to be consistent – but it will at least give you some peace while you try to bang out that next web masterpiece.
A final thought – it may even work to select the Reset option – seen above as “Reset ‘Dual Screen’”, but I haven’t tested that myself personally. Drop a note if it you try that and works for you!
Happy coding!
March 20, 2010 34 Comments
Safari is the Browser Speed King
Wait, what!?
You heard it right. Apparently the boys in Cupertino weren’t just spewing marketease. Safari clocks in at 3.5 times faster that Firefox, 6 times faster than IE 8 and an amazing 42 times faster than IE 7.
Take a look at the full results on CNET.
Download Safari for the PC here.
December 8, 2009 1 Comment
Change System-Wide Default Java Version on Mac OS X
Changing the Java version on OS X is extremely easy.
Simply navigate to /Applications/Utilities/Java/Java Preferences.App and launch the app. There you can set the version of Java to use for both Applets and Applications.
Keep in mind that running a java -version command from a terminal will only reflect the Java Preferences.App settings if you haven’t specified a JAVA_HOME in your .bashrc or .profile, etc.
October 5, 2009 No Comments
Custom Login Page Plugin for WordPress
Here’s an easy way to make your own custom login page for WordPress! Takes 10 min tops, if you know the look you want.
Its a simple idea that makes this administrative task so much easier for an active site. This little WordPress plugin is great!
About the plugin from the Binary Moon page:
BM Custom Login is a plugin I developed to give people an easy way to add a custom WordPress login screen to their WordPress powered blogs. The idea of the plugin is to ease WP upgrading since you will not need to repeatedly make the same changes; this is particularly useful when working with clients. The download contains the plugin and a handy little login screen Photoshop kit to speed up development of your own screens.
All you have to do is use the Photoshop template to create your custom image. Then you upload the new image to the appropriate plugin sub-directory. That’s it! Presto-change-o, your new login page is now active and upgrade proof. Simple, elegant, easy. What more can you ask for?
While I don’t use the plugin for this blog (I’m the only one that logs in here!), I do use it for other WordPress installs that are interactive with clients. Its a very nice, easy to use addition to make your WP site look that much more refined.
Fantastic job Ben!
May 8, 2009 4 Comments
WordPress 2.7 Nested Comments
You may have noticed the “enhanced” comments section that is now featured on my blog.
It allows for the threading of comments – meaning that you can reply to a SPECIFIC comment, so it keeps the any discussion more organized. This is using a new standard feature of WordPress 2.7 that utilizes embedded Javascript handling of comment handling. It does require certain changes to your theme though. Once you’ve followed the theme change directions, you need to add style handlers to your CSS file to get the most out of the new enhanced display. It can be overwhelming at first, but it is pretty simple over all.
Check out these two great places to start for examples of the comment styling: Performancing and CDHarrison. Props to CDHarrison for my wholesale rip of his stylesheet for the comments section here. I’ll undoubtably play with it to make it my own, but his example is so good it may be a while.
Leave a comment below to see it in action!
March 6, 2009 2 Comments
Must Have Tool For RegEx Work
Like RegEx, but dislike its complexity?
Never fear! RegExr is here! This is a great, must-have tool that allows you to remove the typical iterative guess-work loop that happens when writting Regular Expressions. I don’t know about you, but normally, this is my RegEx process:
- Write what I think will work for a RegEx match.
- Upload and test.
- Crap, I’m wrong.
- Write it again.
- If you haven’t done this 5-7 times yet, Go To Step 2, otherwise Exit.
Know what I mean? RegEx is one of those things that I’ve used quite a bit over the years, but not enough to actually remember the syntax off-hand, like some can. In fact, each time I use RegEx, I kinda have to relearn it a bit. Thus, the iterative process above.
Well, RegExr ends all that, as it allows you to see what your expressions are matching in real time! To quote Mr. Frank: “Genius!!”
Its simple to use too. All you have to do is enter some sample text that you’d like to match in the big text box provided, and then use the top entry area to start writing an expression. Bits of the sample text that are matched by your expression will be highlighted, as you can see in the pic below.

First, type in text that you want to match. Second, start writing your expression and watch for highlights below.
RegExr also has a Replace mode, that allows you to watch the replacements happen in real time. This is particularly helpful when writing preg_replace PHP statements, or when you are using something like RedirectMatch for 301 URL redirects.
RegExr also has helpful light weight RegEx documentation and examples available right in the tool. Even better, this great tool has a desktop version for download as well. Just look in the lower right hand corner, under the docs section, for the current desktop download URL. As of this writing, you can find the desktop tool here.
Best of all, this awesome tool is FREE!
February 1, 2009 1 Comment
301 Redirect and RedirectMatch
There is a lot of information available on the net for how to use a 301 redirect in a .htaccess file.
But, largely it all tells you how to do the same 4 or 5 things. What if I needed something different? SOL, baby.
Recently I worked on migrating an old ASP based website to a new WordPress installation. Everything went pretty well, except that the old site was pretty darn popular and there are literally thousands of links to it all over the net. We didn’t want to lose those links and dump them all into an ugly 404 not-found error page, but yet given the fairly sweeping changes that were made, there was no real way to do a one-to-one mapping from the old pages to the new.
As a result, we wanted to take any ASP page call and simply redirect it to the root of the site. There is an added challenge in that the site actually has multiple domains pointing to it, which added a bit of complexity. I had tried modrewrite changes, but they didn’t seem to be working very well. It also seemed a bit heavy handed, when what I really wanted to do was a “simple” redirect.
As you may know, there is a mechanism to do that, and it is simply called Redirect, and it works as follows:
Redirect 301 oldfile newfile
Unfortunately, the syntax only works for explicit matches, meaning that you have to specify EVERY .asp page and explicitly point it to another location. UGH. Not good for a site with well over a hundred pages of content. Even if I was willing to type them all in, since we wanted to redirect everything to the root anyway, adding all of these redirects would be huge waste of processing overhead.
What to do? After reading way too much information online and slogging through the Apache docs for a few hours, I stumbled across RedirectMatch, a great way to add a little regular expression logic to your redirect calls.
Using this simple tool, I was easily able to redirect ANY .asp file to the root.
RedirectMatch 301 (.*).asp /
Simple. Elegant. No modrewrite.
Of course, now that I know what I’m looking for, finding it again would be pretty easy.
Googling 301 redirect regex match gives me the right answer on the second hit. Go figure!
Unfortunately, that’s actually NOT where I found the info. That was a much more convoluted process. A shout out to WebWeaver for introducing me to RedirectMatch!
February 1, 2009 1 Comment












