|
|||||||
New to SitePoint Forums? Register here for free!
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
SitePoint Articles
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'
|
|
|
|
|
|
#2 |
|
SitePoint Community Guest
Posts: n/a
|
Uncomplicated, easy to understand. Well-written.
|
|
|
|
#3 |
|
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 |
|
|
|
#4 |
|
SitePoint Wizard
![]() ![]() ![]() ![]() ![]() ![]() 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 |
|
|
|
|
|
#5 |
|
SitePoint Community Guest
Posts: n/a
|
What are all the "//" for? I have never seen this.
|
|
|
|
#6 |
|
SitePoint Community Guest
Posts: n/a
|
What are they? Protecting the quotes isn't required there, is it?
|
|
|
|
#7 |
|
SitePoint Wizard
![]() ![]() ![]() ![]() ![]() ![]() 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.
|
|
|
|
|
|
#8 |
|
SitePoint Community Guest
Posts: n/a
|
<option value="#i#" selected>#months[i]#</option>
should be: <option value="#i#" selected><cfoutput>#months[i]#</cfoutput></option> |
|
|
|
#9 |
|
SitePoint Community Guest
Posts: n/a
|
Thank you guys for your resourceful sites
|
|
|
|
#10 |
|
SitePoint Member
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. |
|
|
|
|
|
#11 |
|
SitePoint Community Guest
Posts: n/a
|
Thanks for Anonymous post.
It's a very useful article but please double check before posting code. |
|
![]() |
| Bookmarks |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
| Display Modes | |
|
|
|
All times are GMT -7. The time now is 12:21.








Linear Mode
