http://coldfusion.com logo
Join Slack
Powered by
# cfml-beginners
  • p

    Patrick

    09/28/2022, 4:24 PM
    https://cfdocs.org/datecompare
  • a

    Adam Cameron

    09/28/2022, 5:35 PM
    Use a thread for a given topic pls peeps.
  • g

    gsr

    09/28/2022, 11:01 PM
    i am defining my cfc and i am missing something here which i can't seems to find what is going, i have applicatoin.cfc where mappings for the cfc is setup as this.mapping[com], now i have cfc which is inside a cfcs/service folder and that cfc is calling the other cfcs in other folder, so i am trying to use <cfset admin = new com.common.tbladmin() but i am getting an error `Could not find the ColdFusion component or interface com.common.Tbladmin.``, probably a path issue
    • 1
    • 1
  • n

    Nikola Mikasinovic

    09/30/2022, 7:54 AM
    Is There a way to set a cfset from a integer to a long integer, because i get a error that the value is too long for a integer
    a
    • 2
    • 1
  • g

    gsr

    10/04/2022, 12:29 PM
    i am trying to filter the list from the array of structs to display only values needed, what went wrong here https://trycf.com/gist/50f3aeab1dabcdc78b722f3d02dd154a/acf?theme=monokai
    c
    a
    a
    • 4
    • 7
  • o

    Ookma-Kyi

    10/04/2022, 9:16 PM
    Should I hash my reset tokens or just store them as plain text in the database?
    p
    • 2
    • 1
  • g

    gsr

    10/04/2022, 11:00 PM
    i am modifying this code from cflib to make it work with sql server but i am using stored procedures and for reports, i am planning to add a code if the records are more than 500, just show 500, so i am trying to use a reuseable function where i can pass the spx to it because our spx are usually called in the cfquery tags as
    exec sp_proclist
    so trying to make it work in the function so i can pass thatquery to the function and it fetches that many records, not sure it will work that or i need to modify my reports because the reports are quite quite big and too many to count Here is my trying on github https://trycf.com/gist/2dde579d38157ccf83019557ea62a742/lucee5?theme=monokai
    p
    e
    a
    • 4
    • 13
  • u

    Umair Khan

    10/05/2022, 4:49 PM
    does anyone know the library for QuickBooks payments written in ColdFusion?
    p
    s
    e
    • 4
    • 8
  • g

    gsr

    10/09/2022, 2:41 PM
    is CRSF is same as sameorigin nonce or different?
    a
    • 2
    • 3
  • a

    Angad Yadav

    10/10/2022, 5:11 AM
    Hi Guys, Is anyone can share ColdFusion 2018 installer link with me, Please?
    p
    • 2
    • 5
  • e

    epipko

    10/12/2022, 7:30 PM
    If you're using VS Code to write your code for CF, would you share extensions that you're using?
    p
    c
    • 3
    • 5
  • n

    Nikola Mikasinovic

    10/13/2022, 8:05 AM
    Hello, I have a though problem. I want to generate a QR Code in a CFDocument PDF. But it seems that I cant use any JavaScript in it. Is it possible to use Javascript in a CFDocument PDF? If you want i can show you the code too if its necessary :)
    a
    p
    f
    • 4
    • 6
  • g

    gsr

    10/14/2022, 4:45 PM
    Hi, I am tryng to setup a windows Schedule service to restart cf server, in the bin directory, all i can see is the cfstart.bat, isn't there any cfrestart.bat file, and if i have to use cfstart.bat, is its working, it will restart again ? and while i was testing the cfstart.bat, i noticed it does not close the cmd after it starts, so how does windopws schedulr can close that cmd, do i need add some commands in arguments?
    r
    a
    • 3
    • 10
  • g

    gsr

    10/17/2022, 3:19 PM
    we have an application which is running for multiple countries and may users can be at same time, This piece of code is showing an error on The page
    Copy code
    cflock timeout="10" scope="Session" type="Exclusive">
    		<CFPARAM NAME="Session.loginid" DEFAULT=0>
     	</cflock>
    i check some tutorials and getting a very vague answer, some say do not use it, some say names should be used instead of scope, so not sure ho can i fix it
    m
    r
    +3
    • 6
    • 28
  • r

    Ryan Theiss-Aird

    10/17/2022, 7:25 PM
    In CF 2021 update 5, does anyone understand the note about slashes in XML Path? Taken literally it seems to be saying you can no longer put slashes in XPath expressions, which doesn't make any sense.
    b
    m
    • 3
    • 5
  • n

    Nate Smith

    10/18/2022, 6:12 PM
    I created a UDF that works fine when I call it thusly: <cfoutput> #getvocab("6700.6")# </cfoutput> I am having some difficulty using it to perform the function on an XML item: #getVocab(xmlDoc.TreatmentEpisode.ProviderTreatmentEpisodes.Episdoe[MainIndex].FirstContactExpCode)# It seems to return nothing. So I don't think I am passing the value of the XML node in correctly. What am I doing wrong or what should I look at to test. The function is full of awfulness, but I will post it if it would be helpful. If it is the way I am passing the argument, is there an easy rule of thumb to remember when to do what? TIA
    a
    e
    • 3
    • 6
  • e

    epipko

    10/18/2022, 6:21 PM
    Can anyone suggest a simple solution for autosuggest input. I'd like a user to enter data into a field and result to change with every char added.
    a
    p
    +2
    • 5
    • 17
  • r

    Rob W

    10/23/2022, 7:47 AM
    stupid question where in coldbox would you add a function that would be visible in your view thats global for instance i want to create a function that replaces spaces with hyphens for a url public string function makeUrl(url) { replace bit here return url; } where would you store this?
    a
    g
    d
    • 4
    • 3
  • n

    Nikola Mikasinovic

    11/03/2022, 4:48 PM
    Hey, Does someone know how to include api's through a HTTP request and how do I communicate with it?
    b
    s
    • 3
    • 7
  • a

    Anders Lars

    11/04/2022, 6:35 PM
    Hey - I am looking for a code snippet to dynamically return the current class and function that I am in. Say for use in tracing or logging where you don't have a stack trace. I swear I saw a video (I think on refactoring and modernizing code) and there was a part where the presenter showed a snippet of code to do this. I guess that included getFunctionCalledName(), alongside something else. Anyone have something like this they use? -- ideally that works in Lucee. tnx!!
    • 1
    • 1
  • h

    hpeter16

    11/07/2022, 10:47 PM
    Does anyone know how we should secure
    <cfexecute>
    tag against the command shell injection attack?
    b
    • 2
    • 12
  • s

    Simone

    11/08/2022, 6:22 PM
    i am doing a cfdump of session, i want to put ** where the word in the struct key is either "pass" or password
    a
    s
    • 3
    • 26
  • s

    Simone

    11/08/2022, 6:22 PM
    any clue how can i do it, still retaining the <cfdump
    a
    • 2
    • 1
  • e

    epipko

    11/09/2022, 9:07 PM
    Is it possible to build coldfusion related selects using cfml only? I see some examples using javascript or ajax, but I don't know any of them.
    d
    m
    +3
    • 6
    • 13
  • e

    epipko

    11/10/2022, 11:28 PM
    How do I output result of a query as double-quoted comma-delimited list? I've tried <cfset myList = QuotedValueList(getDiv.style_id)>, but it shows single-quoted list
    c
    a
    • 3
    • 5
  • s

    siteadvice

    11/15/2022, 9:01 PM
    I'm struggling with understanding the right syntax for what I need to do so hopefully one of you fine people on this channel can enlighten me. I'm creating a query object that contains a set of prices, populated from a database query. This part works fine.
    <cfset maxpriceQuery = QueryNew("id,maxprice","integer,integer")>
    <cfset QueryAddRow(maxpriceQuery, #get.recordcount#)>
    <cfset intMaxPriceLoop = 1>
    <cfloop query="get">
    <cfset QuerySetCell(maxpriceQuery, "id", #id#, intMaxPriceLoop)>
    <cfset QuerySetCell(maxpriceQuery, "maxprice", #maxprice#, intMaxPriceLoop)>
    <cfset intMaxPriceLoop = intMaxPriceLoop + 1>
    </cfloop>
    Then I want to be able to select from that query, something like this...
    select top 2 id from maxpriceQuery where maxprice <= #getprice.price#
    But I don't know how. Can someone help? I thought maybe I could use this...
    <cfquery name="getmydata" datasource="maxpriceQuery">
    ...but that's evidently wrong because maxpriceQuery is not a valid datasource. I'm sure I did this once years ago but I'll be darned if I can figure out how. :-)
    m
    a
    • 3
    • 8
  • r

    Risen Joe

    11/17/2022, 5:03 PM
    @here I'm having some issues in Coldfusion application like component with the name already exists in cflayout tag so can anyone help on this? Thanks
    m
    • 2
    • 1
  • j

    johnbarrett

    11/23/2022, 7:38 AM
    I am trying to modernize some code, and could use some help. How can I change this code to cfscript? The code below is processing a form, which is not shown, because it's just a basic form. Thanks in advanced for any help!
    Copy code
    <cfif #form.conversionType# is "CtoF">   <cfinvoke component="convertTemp" method="ctof" returnvariable="newtemp" temp=#form.temperature#>
            <cfoutput>#form.temperature# degrees Celsius is #newtemp# degrees Farenheit.</cfoutput>
        <cfelseif #form.conversionType# is "FtoC">
            <cfinvoke component="convertTemp" method="ftoc" returnvariable="newtemp" temp=#form.temperature#>
        <cfoutput>#form.temperature# degrees Fahrenheit is #newtemp# degrees Celsius.</cfoutput>
    </cfif>
    a
    c
    +4
    • 7
    • 8
  • g

    gsr

    11/28/2022, 4:51 PM
    i want to log the sql passed to cfquery in every cfquery we are using storedproc how can i log my queries to know what parameters passed
    v
    m
    +2
    • 5
    • 8
  • g

    gsr

    11/29/2022, 1:13 AM
    isQuery fails when its a storedproc called in cfquery or cfstoredproc, is there a udf or a java method which can detect its a query?
    b
    m
    s
    • 4
    • 54
1...45678Latest