Installing ColdFusion 8 Help Files into Homesite+

Yes, I still use homesite+ for CF coding! It still just works and is not nearly as bloated or cumbersome as Dreamweaver, when doing ColdFusion coding.

The new CF8 Help Files (homeSiteForcf8.zip) don't properly install. Here's what I did to make them work: Install as per directions, except in step 2 of Adobe's directions DON'T install into the "homesite-root" directory (which is your homesite's main install location). INSTEAD install into the Help folder which is inside homesite's root folder.

Hope this helps someone else out who is struggling with them.

Fix for firefox requiring users to right-click and select "Spell check this field"

Starting with a recent version of firefox, rich-text or WYSIWYG text editors no longer cause firefox to automatically spell check. Users needed to right click and select "Spell check this field" every time they went to a page with this type of editor.

The solution is to add the following line of code into the text editor:

gecko_spellcheck : true

For example, in tinyMCE, the code block might look like:

<SCRIPT LANGUAGE="JavaScript">
<!--//
tinyMCE.init({
      gecko_spellcheck : true,
      theme : "advanced",
      mode : "exact",
      elements : "body",
      theme_advanced_layout_manager : "SimpleLayout",
      theme_advanced_toolbar_location : "top",
      theme_advanced_buttons1 : "fontselect,separator,bold,italic,underline,strikethrough,separator,bullist,numlist,outdent,indent,separator,link,unlink,separator,justifyleft,justifycenter,justifyright,justifyfull,separator,hr,sub,sup,separator,code,separator",
      theme_advanced_buttons2 : "",
      theme_advanced_buttons3 : "",
      auto_focus : "body"
   });
//-->
</SCRIPT>

In looking for this solution, I found MANY people with the same problem I had. If this helps you, please post a comment in my blog.

Ken.

What FTP Client do you use?

I use to use CuteFTP way back, but then changed over to Van Dyke's AbsoluteFTP years ago. I can't recall why we made this change, but it seemed better.

Lately, however, AbsoluteFTP (now called SecureFX) likes to download 0-sized files about once every 3 times on one of our computers. Other programs don't do this and it doesn't happen on any computer.

I used to like how CuteFTP allowed multiple instances at a time (i.e. one for the public folders and one for the admin folders). This made it easy to upload changes made in 2 seperate areas without having to navigate folders.

So, I think we'll change to a new FTP client.

What do you use? What do you like about it? What are it's drawbacks?

Cold Fusion: Way to set default values for XML elements?

I was working on an XML conversion project recently, and found that neither the IsXmlElem(), IsXmlNode(), nor the IsXmlAttribute() functions would work if I was looking for a non-existent element (the throw errors if the element doesn't exist).

I know that XML should all be standardized so all elements always exist. However, this client is using an old Oracle system which doesn't always include all the XML elements. In fact it leaves them out when they're null.

So, I wrote the following function to work like a cfparam for XML elements:

<cffunction name="xmlParam" hint="This function works like a cfparam for xml elements. Returns result." returntype="string" output="No">
   <cfargument name="scope" type="xml">
   <cfargument name="name" type="string">
   <cfargument name="default" type="string">
   <cfset var result = "">
   <cftry>
      <cfset result = Trim(Evaluate("scope.#Arguments.name#"))>
      <cfcatch type="Expression"><cfset result = default></cfcatch>
   </cftry>
   <cfreturn result>
</cffunction>

While, I REALLY hate using a cftry to do this, I can't see any other way. Perhaps you know one??

Dynamically eveluating the IsXmlElem function

I was having problems dynamically evaluating with the IsXmlElem function:

#IsXmlElem(xml.abc.def)#

worked fine, but:

<cfset a = "xml.abc.def">
#IsXmlElem(a)#

didn't. To make this work you need to:

<cfset a = "xml.abc.def">
#Evaluate("IsXmlElem(#a#)")#

Notes:

* The setting of the a variable can be dynamic. This is great if you have a list of elements and are looping over them to check for their existisnce.

* This also works of IsXmlNode and IsXmlAttribute.

More Entries