Go Back   SitePoint Forums > Forum Index > Program Your Site > ColdFusion
Newsletter FAQ Members List Calendar Mark Forums Read

New to SitePoint Forums? Register here for free!

SitePoint Sponsor
 
Reply
 
Thread Tools Display Modes
Old Nov 13, 2003, 08:52   #1
ArticleBot
SitePoint Articles
 
ArticleBot's Avatar
 
Join Date: Apr 2001
Posts: 0
Discussion thread for Introduction to Data Structures in ColdFusion

This is a dedicated thread for discussing the SitePoint article 'Introduction to Data Structures in ColdFusion'
ArticleBot is offline   Reply With Quote
Old Nov 13, 2003, 08:52   #2
Anonymous
SitePoint Community Guest
 
Posts: n/a
Uncomplicated, easy to understand. Well-written.
  Reply With Quote
Old Nov 13, 2003, 12:54   #3
Anonymous
SitePoint Community Guest
 
Posts: n/a
Thanks for the info, nice to have it laid out that simply. But there are several bugs in your "real life" code samples:
- <cfset months = ArrayNew()> should be <cfset months = ArrayNew(1)>
- smart quotes won't work they have to be replaced with standard ""
- the variable selectmonth from the first part is named selectedmonth in the second part
  Reply With Quote
Old Nov 13, 2003, 13:38   #4
davidjmedlock
SitePoint Wizard
 
davidjmedlock's Avatar
 
Join Date: Dec 2002
Location: Nashville, TN USA
Posts: 2,039
Good eye for those details there. I'm not sure what happened with those smart quotes, excellent catch on the misnamed variables (I though I copied and pasted that code from a working version...) and the ArrayNew(1). I'll get with the editor...

Thanks again
davidjmedlock is offline   Reply With Quote
Old Aug 1, 2004, 09:23   #5
MyName
SitePoint Community Guest
 
Posts: n/a
What are all the "//" for? I have never seen this.
  Reply With Quote
Old Jun 24, 2005, 03:06   #6
Me Too!
SitePoint Community Guest
 
Posts: n/a
What are they? Protecting the quotes isn't required there, is it?
  Reply With Quote
Old Jul 21, 2005, 12:17   #7
creole
SitePoint Wizard
 
creole's Avatar
 
Join Date: Oct 2000
Location: Nashvegas Baby!
Posts: 7,978
It's most likely that those slashes were left in from either a form submission (from author to editor) or possibly when the content was input into the database using a PHP form.
creole is offline   Reply With Quote
Old Aug 1, 2005, 06:09   #8
Anonymous
SitePoint Community Guest
 
Posts: n/a
<option value="#i#" selected>#months[i]#</option>

should be:

<option value="#i#" selected><cfoutput>#months[i]#</cfoutput></option>
  Reply With Quote
Old Dec 23, 2005, 06:42   #9
Vusi Sambo
SitePoint Community Guest
 
Posts: n/a
Thank you guys for your resourceful sites
  Reply With Quote
Old Feb 13, 2006, 13:26   #10
datapacks.com
SitePoint Member
 
datapacks.com's Avatar
 
Join Date: Apr 2005
Location: Echo Bay Ontario Canada
Posts: 2
You can also use
<cfif selectmonth EQ #months[i]#>

so that your list menu displays the current month by default.
datapacks.com is offline   Reply With Quote
Old Oct 10, 2008, 03:37   #11
Danie
SitePoint Community Guest
 
Posts: n/a
Thanks for Anonymous post.
It's a very useful article but please double check before posting code.
  Reply With Quote
Reply

Bookmarks

« Previous Thread | Next Thread »

Thread Tools
Display Modes

 
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Sponsored Links
 
Forum Jump


All times are GMT -7. The time now is 12:21.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Copyright 1998-2009, SitePoint Pty Ltd. All Rights Reserved