fusiongrokker

Entries for month: July 2008

Goodbye WordPress, Hello Mango!

I figured since I was finally going to have some proper ColdFusion hosting, I might as well check out the latest and greatest from our various CFML blogging engines. I'd used BlogCFC in the past, so this time I decided to give Mango a test drive. So far, I'm really liking it. Mango has an integrated database setup and the option to import from WordPress exports and BlogCFC. It's apparently got easy but powerful plugin support (which I intend to explore soon), and is supposed to be one of the easier blogs to skin -- again, something I intend to explore soon.

With some help from Laura in the Mango support forums, I was able to work through some quirky import issues (pages that belong to a category aren't supported in Mango, but apparently I had them in WP -- this was throwing an error during import, should be fixed in an upcoming release, I'm sure) and got all of my old posts and comments imported. I managed to remember what my FeedBurner password was, so I even managed to pull off the switch without upsetting continuity in aggregators like ColdFusionBloggers, Feed Squirrel and AXNA. Although I have to apologize if it ends up causing doubles of anything.

Lastly, I also setup request forwarding from my previous host (on another of my domains still temporarily hosted there) to my new host and domain, pretty much just like Ray did when he moved to ColdFusionJedi.com. Since my old host didn't support SES urls, I had to use the ID from the url to lookup the post title and forward the url to this domain.

So how do you like the new domain? Eh?

Posted in Meta | Mango | 3 Responses July 23 2008

File upload gotcha: PDFs get different mime types per browser

I've had some time over the last few days to start adding some of the "nice to have" features to a client site before delivering it, and one of those was the ability to upload product images and related PDFs, rather than having to teach them to always follow the naming scheme and how to use FTP. While testing my uploads in various browsers, I came across something I found to be very odd.

When you upload a PDF in IE, the file you receive has what I believe is the correct mime type: "application/pdf" however when you upload the same PDF file using the same code, in Firefox (tested in FF 2 and 3), the mime type is "application/download". I can't explain it. I have no idea why it's wrong. But it is, and consistently so. Could this be the one thing that is implemented correctly in IE and incorrectly in Firefox?

At any rate, it's a simple thing to accommodate. Note the accept attribute of the <CFFile> tag in the code sample below:

<cftry>
<cffile action="upload" 
        accept="application/download,application/pdf" 
        filefield="form.pdfUpload" 
        nameconflict="overwrite" 
        result="result" 
        destination="#expandPath('/path/to/save/your.pdf')#" />
<cfif variables.result.fileExisted neq "NO">
    <cfset msg = "PDF was overwritten." />
<cfelse>
    <cfset msg = "PDF was saved." />
</cfif>
<cfcatch type="application">
    <cfif findNoCase("The MIME type of the uploaded file", cfcatch.message)>
        <!--- invalid mime type --->
        <cfset msg = "Invalid file type. Please only use a PDF file. File was not saved." />
    </cfif>
</cfcatch>
</cftry>

Posted in ColdFusion | 23 Responses July 18 2008

If you legitimately receive Spam, do you report it to GMail?

Often times I subscribe to people's blog posts when I leave a comment, because I'm interested in other folks' comments as well. Unfortunately, this occasionally means that a spam comment ends up in my inbox:

Is it spam? I did kind of ask for it?

 

My question is this: Should I report this as spam? I mean, I did kind of ask for it (not really... but yeah... but no). The last thing I want is for GMail to start filtering all blog comment emails as spam. I think this is where some transparency with Google could help. What exactly do they do with a message after we mark it as spam? Or heck, give us configurable white/black lists. What do you do?

Posted in Meta | 8 Responses July 17 2008

Post Your Verity Snippets to CFSnippets.org

You're developing your CFML in Eclipse, right? And you're probably using CFEclipse and Subclipse to go along with that. Of course!

But are you using Snippets? You should be!

And you should be using the SnipEx client built right into CFEclipse. Todd Sharp's CFSnippets.org is a free public SnipEx library focused on ColdFusion and CFML developers. And as of today, thanks to yours truly, there is a Verity Library, too. It's often said that one could make a career out of implementing and tuning Verity, so it's obviously something that can be very complex and difficult to remember between uses. I'm no Verity pro, but I've added my most frequently used snippet and I'm curious to see what other developers have done with Verity.

So go on, post your snippets. Let's all make searching easier and search results better.

Posted in ColdFusion | Community | 1 Response July 15 2008