I stumbled across YQL today and although I had heard about it in the past, today was the first time, I actually sat down and read the documentation and went through some of the example apps. I am amazed at how powerful it is and am just imagining the wonderful applications that can be built using YQL. It opens up the doors to pretty much anything using a SQL like syntax. Read the rest of this entry »
Posts Tagged ColdFusion
I came across a requirement today, where I had to sort a XML file by one of the attributes in one of its child nodes. I did some searching and came across these excellent posts by Ben Nadel. Obviously, that gave me some headstart and it was clear that XSLT was the way to go. I have not used a lot of XSLT in the past so my knowledge is a bit limited in this area.
After reading a couple of articles on the subject and understanding some basic stuff – here is what I came up with. Read the rest of this entry »
I was setting up a new Project in Flex Builder with Application Server Type as ‘ColdFusion’. I had the default values in the Flex Builder wizard. But the Wizard wont let me go past the second screen. I kept getting this error :-
Invalid root. The WEB-INF/flex folder must contain either flex-config.xml or services-config.xml.
And I was sure that the WEB-INF folder actually had the correct files under it. Read the rest of this entry »
I had a requirement to generate an Excel report based on some filter criteria. Since I am using ColdFusion for the project, I will be using ColdFusion code to demonstrate what I did but this can pretty much apply to any language that can run loops and write files.
My requirement was to have Excel’s Auto-Filters enabled when the user downloads the file via the browser. After searching a little bit, I realized its not that straight forward. I will probably blog about the harder way of doing it later, but here is what I ended up doing which turns out to be very simple and easy to do as well. Read the rest of this entry »
I had to re-install ColdFusion 9 on my MacOS today and having installed CF approx. a million times before, I thought it would only take few minutes.
Here is what I did :-
1) Went to /Applications/ -> Moved existing “ColdFusion 9″ folder to Trash.
2) Ran the CF Installer and everything went well. But finally, the installer got stuck at “Installing WebServer Connectors” – I waited a few minutes but then gave up.
3) Repeat Steps 1 and 2.
4) I then decided to try the installation with the in-built webserver. That worked, but I could not load any pages at all in browser. Basically, Apache was not working.
5) I opened Terminal. Ran the command “sudo apachectl start” – It says “Already running”. At this point, I was wondering whats wrong.
6) Ran the command “sudo apachectl restart” and it appeared as if it got restarted. No changes.
7) Did some Search and ran this command. “sudo apachectl configtest” to make sure the Apache config was fine. Turns out it was throwing this error. Read the rest of this entry »
This post of mine is coming after a long time, I know. The reason for this has been lack of time, being very busy with other things etc. I will try to be more frequent here hereafer.
Anyways, in a recent project, I had the requirement to show Twitter statuses on the homepage of the website I was working on. The first thing I did was, went straight to RiaForge and searched for any Twitter related CFC’s. I did find a couple of them and they all looked pretty good. However, since I only wanted to get the stautses and not the other fancy stuff like direct messages etc, I thought there must be an easier way of doing it.
That’s when I thought if the statuses are available as RSS feeds, I am done. CFFEED can do everything for me.
<cfset feedurl = "http://twitter.com/statuses/user_timeline/15172848.rss" /> <cffeed source="#feedurl#" properties="statusmeta" query="statuses" />
Thats it. The code above gives me a feed of my status updates in a ColdFusion query, which I can now use to display as I want. There are too many columns in the query with lots of useful information. I ended up using just the “rsslink” and “title” columns as those were the only 2 I wanted for my requirement.
Its nice to know that Twitter publishes these rss feeds and even nicer that I can use this in one line of code.
If you are using ColdFusion XPath functions to search/parse XML strings, you will probably have come across this one at some point. Not all, but most of the XML files have namespaces in them e.g. xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance”. If you use Xpath on a string that contains namespaces, chances are that you will get back the namespaces as well and sometimes you dont want these at all. You just want to deal with the real data. Read the rest of this entry »
This post is just a little tip that I think can take a lot of time in trying to solve.
I was building a variable , using cfsavecontent, to process later on and there was absolutely nothing wrong with the code according to me, as below :- Read the rest of this entry »
I had a cftextarea with richtext enabled and I had another dropdown which was supposed to change the value of the cftextarea when selected. So, I was doing it the old way as I would have imagined. Read the rest of this entry »
I have just released an update to coldfusiondocs.com . As the title says, I have added Railo support to the documentation, so now you get a new tab for Railo tags and functions and just like before, you can search and view the documentation.
I think it makes sense to add this as part of the documentaiton. As always, any feedback is more than welcome.