Re: CF and Spry
it may have something to do with casing - javascript is case sensitive On Jan 5, 2008 4:17 PM, Issac Rosa [EMAIL PROTECTED] wrote: Can someone see why the detailregion is not updating when using Spry.Data.JSONDataSet? If I use Spry.Data.XMLDataSet, the detailregion updates fine when I click a row. I am getting the resultset fine. Here is my code. index.html: !DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd; html xmlns=http://www.w3.org/1999/xhtml; head meta http-equiv=Content-Type content=text/html; charset=utf-8 / head titleSpry Dynamic Example 4/title script type=text/javascript src=/CFIDE/scripts/ajax/spry/includes/xpath.js/script script type=text/javascript src=/CFIDE/scripts/ajax/spry/includes/SpryData.js/script script type=text/javascript src=/CFIDE/scripts/ajax/spry/includes/SpryJSONDataSet.js/script script type=text/javascript var mydata = new Spry.Data.JSONDataSet(product.cfc ?method=getProductsreturnFormat=jsonqueryFormat=column,{path:DATA,pathIsObjectOfArrays:true}); /script /head body style ..hot { background-color: yellow; } ..red { background-color: red; } /style div spry:region=mydata p table width=100% border=1 tr th onClick=mydata.sort('prod_name','toggle'); style=cursor: pointer;Name/th th onClick=mydata.sort('cat_name','toggle'); style=cursor: pointer;Category/th /tr tr spry:repeat=mydata spry:setrow=mydata spry:select=red spry:hover=hot td style=cursor: pointer;{PROD_NAME}/td td style=cursor: pointer;{CAT_NAME}/td /tr /table /p /div div spry:detailregion=mydata h2{PROD_NAME}/h2 /div /body /html products.cfc: cfcomponent output=false cffunction name=getProducts returnType=query access=remote output=false cfset var q = cfquery name=q datasource=spry select * fromproducts_view order by prod_name asc /cfquery cfreturn q /cffunction /cfcomponent Thanks, Issac ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295940 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: stuck with a loop count
Thanks Isaac, Morgan * every one. i will try that out a little latter today if i can. i was also thinking that this strcture is kinda wierd. ideally i would like to make another table that just does a count on leads, the other math stuff. so i dont have cf doing it but the sql server. but i am pretty newb at sql server. so need to read up on how to do that, if its a better way get usr_id count leads count folledup, count dead, count (folledup-leads) As openLeads, count dead but there is a loop for each lead that gets counted and all. nm will play around a bit latter. ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295941 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: CF and Spry
Isaac. First off if you already don't know about it I would check out firebug as it lets you monitor requests. I think your only problem here is that your looking for json and your cfc is returning wddx. If you do not set a return format then it will return wddx. Simply add this to your component. returnFormat=json This of course can only only be done if your on ColdFusion 8, if you are not that you will need to you some kind of proxy between you calling template and the cfc. Hope this works!~ Dan Vega www.danvega.org On Jan 5, 2008 8:00 AM, AJ Mercer [EMAIL PROTECTED] wrote: it may have something to do with casing - javascript is case sensitive On Jan 5, 2008 4:17 PM, Issac Rosa [EMAIL PROTECTED] wrote: Can someone see why the detailregion is not updating when using Spry.Data.JSONDataSet? If I use Spry.Data.XMLDataSet, the detailregion updates fine when I click a row. I am getting the resultset fine. Here is my code. index.html: !DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd; html xmlns=http://www.w3.org/1999/xhtml; head meta http-equiv=Content-Type content=text/html; charset=utf-8 / head titleSpry Dynamic Example 4/title script type=text/javascript src=/CFIDE/scripts/ajax/spry/includes/xpath.js/script script type=text/javascript src=/CFIDE/scripts/ajax/spry/includes/SpryData.js/script script type=text/javascript src=/CFIDE/scripts/ajax/spry/includes/SpryJSONDataSet.js/script script type=text/javascript var mydata = new Spry.Data.JSONDataSet(product.cfc ?method=getProductsreturnFormat=jsonqueryFormat=column,{path:DATA,pathIsObjectOfArrays:true}); /script /head body style ..hot { background-color: yellow; } ..red { background-color: red; } /style div spry:region=mydata p table width=100% border=1 tr th onClick=mydata.sort('prod_name','toggle'); style=cursor: pointer;Name/th th onClick=mydata.sort('cat_name','toggle'); style=cursor: pointer;Category/th /tr tr spry:repeat=mydata spry:setrow=mydata spry:select=red spry:hover=hot td style=cursor: pointer;{PROD_NAME}/td td style=cursor: pointer;{CAT_NAME}/td /tr /table /p /div div spry:detailregion=mydata h2{PROD_NAME}/h2 /div /body /html products.cfc: cfcomponent output=false cffunction name=getProducts returnType=query access=remote output=false cfset var q = cfquery name=q datasource=spry select * fromproducts_view order by prod_name asc /cfquery cfreturn q /cffunction /cfcomponent Thanks, Issac ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295942 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: CF and Spry
Isaac. First off if you already don't know about it I would check out firebug as it lets you monitor requests. I think your only problem here is that your looking for json and your cfc is returning wddx. If you do not set a return format then it will return wddx. Simply add this to your component. returnFormat=json This of course can only only be done if your on ColdFusion 8, if you are not that you will need to you some kind of proxy between you calling template and the cfc. Hope this works!~ Dan Vega www.danvega.org ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295943 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: stuck with a loop count
ok... Morgan using what you showed i am now able to get a sum of all reps which is great! but its not then summing those up for manager, and then total for all.. it just repats the last iteration. !--- Display Market Header --- cfset sumTotal = 0!--- --- cfoutput query=get_Sales group=Market h3cfif get_Sales.Market IS 1 Industrial Sales Reps cfelse IT Sales Reps /cfif/h3 !--- Display The Manager of that Market --- cfoutput group=Manager !--- this is used to add up each manager's reps. Reset to 0 at the start of each new manager --- cfset sumTotal = 0!--- --- cfset subTotal = 0!--- --- h4#get_Sales.Manager#/h4 h5Name - Total Leads - Rep Company/h5 !--- Display The Sales guys under the Managers --- cfoutput group=usr_fname !--- Do a count on all the leads for each sales guy. this works just fine --- cfquery datasource=#request.dsn# name=get_leads Select Count(*) AS total From Leads WHERE rep_assigned = #get_Sales.usr_id# /cfquery !--- Display our basic info --- #get_Sales.usr_fname# #get_Sales.usr_lname# :: #get_leads.total#br CFSET sumTotal = #sumTotal# + #get_leads.total#!--- --- /cfoutputbr !--- This will display each manager's total for all their Rep's --- span class=style1Rep's Total: #sumTotal#/span!--- --- !--- this adds this manager's subtotal to the overall total --- !--- ---br by Market: #sumTotal# /cfoutput/cfoutput !--- This is the overall total for all managers ---br overall total: cfoutput#sumTotal#/cfoutput !--- Now for each loop of sales guys i want to sum up all there get_leads.total --- !--- A. for each managers group - This Works!--- !--- 1. Total by Market: dosnt work --- !--- 2. ovelrall total: dosnt work - sume for all in combined Markets so thats all the sales guys totals --- ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295944 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: CF and Spry
Thanks for the reply Dan, but if you notice in my call to the CFC when I create the DS, I am using returnFormat=json and I'm getting the data displayed in Region 1. var mydata = new Spry.Data.JSONDataSet(../product.cfc?method=getProductsreturnFormat=jsonqueryFormat=column, {path:DATA, pathIsObjectOfArrays:true}); There is a problem with Region 2. On first loading the page, Region 2 shows the data for the current row of the last record in the DS. When I click on a row (either column), Region 2 does not update (it goes blank removing the initial data from the last record of initial load). I am using Firebug and see that there aren't any errors in the request and the dataset appears to be returned without issues. Issac ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295945 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Whitespace from seemingly nowhere, what am I missing?!
Using CF8 CF7, when directly outputting the result of a function or method call, I see whitespace (it is actually some sort of special character) before the string. If I place the result in a variable and then output it, I don't see the whitespace... I'm assuming people must have come across this before, the following code demonstrates the problem: Example 1: cffunction name=silly cfreturn billy /cffunction cfoutput=#Silly()#=/cfoutput Output: = billy= Example 2: cffunction name=silly cfreturn billy /cffunction cfset foo = Silly() cfoutput=#foo#=/cfoutput Output: =billy= Anyone have any clues as to why this happens and what to do about it? Thanks in advance, Dominic -- Blog it up: http://fusion.dominicwatson.co.uk ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295946 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: Whitespace from seemingly nowhere, what am I missing?!
Do you have the component set to suppress whitespace? The problem is not about white space not suppressed. Some white space is actually *added*. -- ___ REUSE CODE! Use custom tags; See http://www.contentbox.com/claude/customtags/tagstore.cfm (Please send any spam to this address: [EMAIL PROTECTED]) Thanks. ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295950 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: Whitespace from seemingly nowhere, what am I missing?!
Silly indeed! And it is as silly under CF6 Note that if you cfoutput=#len(Silly())#=/cfoutput you get = 5=, thus the extra space is not actually returned by the function call, but is inherent to any function call inside cfoutput However cfoutput=#len(Silly)#=/cfoutput outputs =5= correctly. And if the function is defined in CFSCRIPT, no problem Definitely a bug, and it has been there for a long time. -- ___ REUSE CODE! Use custom tags; See http://www.contentbox.com/claude/customtags/tagstore.cfm (Please send any spam to this address: [EMAIL PROTECTED]) Thanks. ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295949 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: Whitespace from seemingly nowhere, what am I missing?!
Do you have the component set to suppress whitespace? cfcomponent output=false cffunction name=what output=false I am pretty sure you only need to do it at the component level but if it was set to true there you could control it on a per function basis as well Dan On Jan 5, 2008 5:11 PM, Dominic Watson [EMAIL PROTECTED] wrote: Using CF8 CF7, when directly outputting the result of a function or method call, I see whitespace (it is actually some sort of special character) before the string. If I place the result in a variable and then output it, I don't see the whitespace... I'm assuming people must have come across this before, the following code demonstrates the problem: Example 1: cffunction name=silly cfreturn billy /cffunction cfoutput=#Silly()#=/cfoutput Output: = billy= Example 2: cffunction name=silly cfreturn billy /cffunction cfset foo = Silly() cfoutput=#foo#=/cfoutput Output: =billy= Anyone have any clues as to why this happens and what to do about it? Thanks in advance, Dominic -- Blog it up: http://fusion.dominicwatson.co.uk ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295947 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: Whitespace from seemingly nowhere, what am I missing?!
Yeh and this happens outside of components (for me at least). The code I posted was from a plain ol .cfm file. Try it and see :) Dominic On 05/01/2008, Dan Vega [EMAIL PROTECTED] wrote: Do you have the component set to suppress whitespace? cfcomponent output=false cffunction name=what output=false I am pretty sure you only need to do it at the component level but if it was set to true there you could control it on a per function basis as well Dan On Jan 5, 2008 5:11 PM, Dominic Watson [EMAIL PROTECTED] wrote: Using CF8 CF7, when directly outputting the result of a function or method call, I see whitespace (it is actually some sort of special character) before the string. If I place the result in a variable and then output it, I don't see the whitespace... I'm assuming people must have come across this before, the following code demonstrates the problem: Example 1: cffunction name=silly cfreturn billy /cffunction cfoutput=#Silly()#=/cfoutput Output: = billy= Example 2: cffunction name=silly cfreturn billy /cffunction cfset foo = Silly() cfoutput=#foo#=/cfoutput Output: =billy= Anyone have any clues as to why this happens and what to do about it? Thanks in advance, Dominic -- Blog it up: http://fusion.dominicwatson.co.uk ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295948 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: Whitespace from seemingly nowhere, what am I missing?!
Silly indeed! And it is as silly under CF6 Aha, not just my code then! I've noticed that it also happens when accessing a value in a query using array notation, i.e.: cfoutput=#myQuery[col][row]#=/cfoutput Can't believe that's been around for so long and not fixed in CF8! I guess my only solution is to assign to a variable first - pain in the arse, but at least I know I have to do it. Thank you, Dominic ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295951 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
cfexecute help.
Hey guys, I've been suffering like a dog trying to get ffmpeg to work for a site I'm working on. For those of you who dont' know, ffmpeg is basically a command line utility that converts video formats to flv. Anyway, I got it to work nicely in a command line, I juts can't get it to work in my code. I've found that the problem seems to be that the process does not end. In some cases, when I end the process from task manager, it works. So, after some research, I found this on Ben Forta's site: http://www.forta.com/blog/index.cfm/2006/7/31/Using-CFEXECUTE-To-Execute-Command-Line-Utilities Which explains exactly my problem! I mean, I need to get a /c onto the command line somehow. However, I have no experience with batch files, or cfexecute, so I don't know how I could fit a /c onto the same arguments string as the rest of the ffmpeg command. Just putting ffmpeg /c doesn't seem to work, at least not in my limited testing. In other words, how do I get ffmpeg to end its own process after I use cfexecute to execute it? ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295952 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
using form.fieldNames and CFLOOP to insert selected radio buttons
I'm trying to insert the value of selected radio buttons using CFLOOP and #form.fieldNames#. It's returning the correct values that need to be inserted into the database, but it's also returning the value and name of my submit button. I thought using form.fieldNames was correct but I'm not sure how to return all the selected fields but not the submit? Thanks for any help! !--- // FORM --- cfform action=page.cfm method=get table cfoutput query=getAll group=statusName tr th class=rowStatusId colspan=3#statusName#/th /tr cfoutput tr class=#iif(currentrow MOD 2,DE('rowAltOne'),DE('rowAltTwo'))# td align=centerinput type=radio name=#dbId# value=7 //td td align=centerinput type=radio name=#dbId# value=8 //td td#dbNameFirst# #dbNameLast#/td /tr /cfoutput /cfoutput /table pinput name=inputButton class=formButton type=submit value=submit //p /cfform !--- // LOOPING and INSERT --- cfif isDefined(form.inputButton) cfloop index=i list=#form.fieldNames# !--- test output to make sure it's giving correct values --- cfoutput #i# br / #form[i]# br /br / /cfoutput !--- insert that bombs because of the text --- cfquery datasource=#dbname# name=addContact INSERT INTO contact FIELDS (contactDbId,contactTypeId,contactDate) VALUES (#Evaluate(i)#,#form[i]#,#DateFormat(Now(), '-mm-dd')#) /cfquery /cfloop cfelse ... Give me this: 361 dbId (correct) 8 - contactTypeId (correct) 807 dbId (correct) 7 - contactyTypeId (correct) INPUTBUTTON - how do I not output this? submit --- and this? !--- // ERROR --- Syntax error or access violation message from server: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near apos;FIELDS (contactDbId,contactTypeId,contactDate) VALUES (448,8,2008-01-05)apos; at line 2 ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295953 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: stuck with a loop count
Thanks Guys.. finally got it to work intended. ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295954 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
RE: cfexecute help.
I mean, I need to get a /c onto the command line somehow. However, I have no experience with batch files, or cfexecute, so I don't know how I could fit a /c onto the same arguments string as the rest of the ffmpeg command. Just putting ffmpeg /c doesn't seem to work, at least not in my limited testing. When you run ffmpeg from the command line yourself, you're actually running two programs, in a manner of speaking. You're running the command processor itself, and that's running ffmpeg for you: cmd /c ffmpeg ... Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber vendor-authorized instruction at our training centers in Washington DC, Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location. Visit http://training.figleaf.com/ for more information! ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295955 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: short and quick javascript dev project
Project Complete. Thanks Matt! On Jan 4, 2008 9:38 PM, Gonzo Rock [EMAIL PROTECTED] wrote: I have a javascript issue that I need to get resolved... actually developed. It's pretty simple really for someone who rocks javascript. The script works in a very simple mode with one total but now I'm trying to parse a group of text fields that contain numbers and add them up in groups. The user enters the data and the javascript SubTotals, Totals and GrandTotals. I am willing to pay via PayPal to get this taken care of this weekend... it should be a simple hour or so for someone on the other end of a phone who know what they are doing while I explain the important details. Reply Off List and we can connect up. Thanks, Gonzo Example: FormFieldName Value *Bold Value is what the javascript should calculate*. == == count1:A 6 count1:B 2 count1:C 1 count1:D 3 *SubTotal1 12 * ** count2:A 3 count2:B 1 count2:C 3 count2:D 2 *SubTotal2 9 * ** countn:z *SubTotaln * etc for some variable set of count groups with some variable set of members to subtotal and then Finally *TotalA* *9 * *TotalB* *3 * *TotalC* *4 * *TotalD* *5 * *GrandTotal 21 * ** ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295957 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: using form.fieldNames and CFLOOP to insert selected radio but tons
It's returning the correct values that need to be inserted into the database, but it's also returning the value and name of my submit button. I thought using form.fieldNames was correct but I'm not sure how to return all the selected fields but not the submit? Thanks for any help! CF has no way of knowing which fields you care about, and which you don't. Your submit button creates a form variable, just like any other form field. You can avoid this by using conditional logic within your loop to exclude the fields you don't want, or by not giving those fields names in the first place. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber vendor-authorized instruction at our training centers in Washington DC, Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location. Visit http://training.figleaf.com/ for more information! ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295956 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Simple Employment Application
Hello, I am new at coldfusion and am having trouble posting a simple employment application. As much as I have analyzed this, I can't seem to see my error. I would greatly appreciate any and all help. cfif isDefined('form.submitEmploymentApplication') cfsavecontent variable=emailToSend cfoutput table width=100% cellpadding=3 cellspacing=0 border=0 tr td width=160font face=arial size=2strongFirst Name:/strong/font/td tdfont face=arial size=2#trim(form.firstName)#/font/td /tr tr td width=160font face=arial size=2strongLast Name:/strong/font/td tdfont face=arial size=2#trim(form.lastName)#/font/td /tr tr td width=160font face=arial size=2strongAddress:/strong/font/td tdfont face=arial size=2#trim(form.address)#/font/td /tr tr td width=160font face=arial size=2strongCity:/strong/font/td tdfont face=arial size=2#trim(form.city)#/font/td /tr tr td width=160font face=arial size=2strongState:/strong/font/td tdfont face=arial size=2#trim(form.state)#/font/td /tr tr td width=160font face=arial size=2strongZip:/strong/font/td tdfont face=arial size=2#trim(form.zip)#/font/td /tr tr td width=160font face=arial size=2strongTelephone:/strong/font/td tdfont face=arial size=2#trim(form.telephone)#/font/td /tr tr td width=160font face=arial size=2strongEvening Phone/strong/font/td tdfont face=arial size=2#trim(form.phone_night)#/font/td /tr tr td width=160font face=arial size=2strongEmail Address:/strong/font/td tdfont face=arial size=2#trim(form.emailAddress)#/font/td /tr td width=160font face=arial size=2strongOccupation/strong/font/td tdfont face=arial size=2#trim(form.occupation)#/font/td /tr /tr td width=160font face=arial size=2strongClubs/Affiliations/strong/font/td tdfont face=arial size=2#trim(form.clubs)#/font/td /tr /tr td width=160font face=arial size=2strongPTA/School groups etc involvement/strong/font/td tdfont face=arial size=2#trim(form.pta)#/font/td tr td width=160font face=arial size=2strongTime to devote:/strong/font/td tdfont face=arial size=2#trim(form.devote_time)#/font/td /tr tr td width=160font face=arial size=2strongStrengths/strong/font/td tdfont face=arial size=2#trim(form.strengths)#/font/td /trtr td width=160font face=arial size=2strongBest Time to Reach You:/strong/font/td tdfont face=arial size=2#trim(form.bestTime)#/font/td /tr tr td width=160font face=arial size=2strongWould like some help with:/strong/font/td tdfont face=arial size=2#trim(form.help)#/font/td /tr tr td width=160font face=arial size=2strongIntentions/Expectations and questions:/strong/font/td
RE: Simple Employment Application
I am new at coldfusion and am having trouble posting a simple employment application. As much as I have analyzed this, I can't seem to see my error. I would greatly appreciate any and all help. What is it doing that it shouldn't? You will generally get more helpful answers on mailing lists when you provide more information. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber vendor-authorized instruction at our training centers in Washington DC, Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location. Visit http://training.figleaf.com/ for more information! ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295959 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: Simple Employment Application
When I post it I keep getting a line 35 error and when I remove the cfoutput section it posts wout errors, but obviously any it submits as a blank page. I am new at coldfusion and am having trouble posting a simple employment application. As much as I have analyzed this, I can't seem to see my error. I would greatly appreciate any and all help. What is it doing that it shouldn't? You will generally get more helpful answers on mailing lists when you provide more information. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber vendor-authorized instruction at our training centers in Washington DC, Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location. Visit http://training.figleaf.com/ for more information! ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295960 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: Whitespace from seemingly nowhere, what am I missing?!
Can't believe that's been around for so long and not fixed in CF8! Must be in the same agenda as correcting the empty list element bug ;-) -- ___ REUSE CODE! Use custom tags; See http://www.contentbox.com/claude/customtags/tagstore.cfm (Please send any spam to this address: [EMAIL PROTECTED]) Thanks. ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295963 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: Simple Employment Application
Hi Christine, best way to get a quick answer is to paste the exact error you receive but anyways, the error that I get is Element PHONE_NIGHT is undefined in FORM. That means that form.phone_night does not exist, or, there is no form element with the name form.phone_night. A quick look at the html code for your form showed up this: input name=Phone (Evening) type=text class=text id=Phone (Evening) style=width: 140px size=4 / The name of the input is wrong. Should be name=Phone_night. The CAUSE of an error is often not the line that the error output gives you, (the line number is only where the original error rears its head). Regards, Dominic -- Blog it up: http://fusion.dominicwatson.co.uk ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295964 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: Simple Employment Application
When I post it I keep getting a line 35 error and when I remove the cfoutput section it posts wout errors, but obviously any it submits as a blank page. I am new at coldfusion and am having trouble posting a simple employment application. As much as I have analyzed this, I can't seem to see my error. I would greatly appreciate any and all help. What is it doing that it shouldn't? You will generally get more helpful answers on mailing lists when you provide more information. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber vendor-authorized instruction at our training centers in Washington DC, Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location. Visit http://training.figleaf.com/ for more information! ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295962 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: using form.fieldNames and CFLOOP to insert selected radio but tons
I agree Dave. That's why I posted the question here. I would really appreciate any concrete solutions/options/direction from the other experts here. -Original Message- From: Dave Watts [mailto:[EMAIL PROTECTED] Sent: Saturday, January 05, 2008 6:36 PM To: CF-Talk Subject: RE: using form.fieldNames and CFLOOP to insert selected radio but tons It's returning the correct values that need to be inserted into the database, but it's also returning the value and name of my submit button. I thought using form.fieldNames was correct but I'm not sure how to return all the selected fields but not the submit? Thanks for any help! CF has no way of knowing which fields you care about, and which you don't. Your submit button creates a form variable, just like any other form field. You can avoid this by using conditional logic within your loop to exclude the fields you don't want, or by not giving those fields names in the first place. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber vendor-authorized instruction at our training centers in Washington DC, Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location. Visit http://training.figleaf.com/ for more information! ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295961 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: using form.fieldNames and CFLOOP to insert selected radio but tons
You can avoid this by using conditional logic within your loop to exclude the fields you don't want, or by not giving those fields names in the first place. I would really appreciate any concrete solutions/options/direction ... I provided two solutions. They're about as concrete as you can get, without me writing the code. Did you try either? The first would involve wrapping your CFQUERY with CFIF tags: cfloop index=i list=#form.fieldNames# cfif i is not inputbutton cfquery datasource=#dbname# name=addContact INSERT INTO contact FIELDS (contactDbId,contactTypeId,contactDate) VALUES (#Evaluate(i)#,#form[i]#,#DateFormat(Now(), '-mm-dd')#) /cfquery /cfif /cfloop Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber vendor-authorized instruction at our training centers in Washington DC, Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location. Visit http://training.figleaf.com/ for more information! ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295965 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: Simple Employment Application
Are you able to log into ColdFusion administrator? If so, find the logs section, open up the Application log, find any error message in there. That should give a clue to the source of the error. -Mike Chabot On Jan 5, 2008 9:45 PM, christine gardner [EMAIL PROTECTED] wrote: When I post it I keep getting a line 35 error and when I remove the cfoutput section it posts wout errors, but obviously any it submits as a blank page. ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295966 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Coldfusion Auction Script
We are currently looking for Simple auction script. simple means... we intend to use it for auctioning our own products in our website (NOT for multi auctioner). I found this...http://www.beyondsolutions.com/ any opinion on this script ? Tried to contact them twice, with no reply... Anyone has information on other similar script ? Thanks. ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:295967 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4