Skip to main content
Participant
July 5, 2008
Question

CF Form issues

  • July 5, 2008
  • 2 replies
  • 285 views
90% of my pages use <cfif isdefined("form.xxx")> to execute a block of code after the submit button is pressed. This works on my test server and I have never had a problem with the code in past websites but I just started using a new hosting company, hostnexus, and when you press the a submit button the page reloads and totally skips everything in the <cfif isdefined... code section. Here is the test page link.

http://65.98.59.170/$sitepreview/Ozark-Development.com/test.cfm

Here is the code for the test page.
    This topic has been closed for replies.

    2 replies

    Inspiring
    July 5, 2008
    i have been with hostnexus for 5 years now and do not rememeber having
    any problems with cfform...

    my guess would be they do not have CFIDE folder properly mapped in the
    temporary site preview you are using...

    it may be work checking with them to make sure CFIDE is mapped properly
    / proper virtual dir is created in IIS. they are usually lightning fast
    in their support...

    Azadi Saryev
    Sabai-dee.com
    http://www.sabai-dee.com/
    OzarkwebAuthor
    Participant
    July 5, 2008
    Ken was right. As far as hostnexus goes, so far they are awesome; by far better than the company I was using before. Thanks for the help guys.
    Inspiring
    July 5, 2008
    Give the form a method:

    <cfform action="test.cfm" method="post" name="myForm" id="myForm">

    --
    Ken Ford
    Adobe Community Expert - Dreamweaver/ColdFusion
    Fordwebs, LLC
    http://www.fordwebs.com


    "Ozarkweb" <webforumsuser@macromedia.com> wrote in message news:g4mitb$3no$1@forums.macromedia.com...
    > 90% of my pages use <cfif isdefined("form.xxx")> to execute a block of code
    > after the submit button is pressed. This works on my test server and I have
    > never had a problem with the code in past websites but I just started using a
    > new hosting company, hostnexus, and when you press the a submit button the page
    > reloads and totally skips everything in the <cfif isdefined... code section.
    > Here is the test page link.
    >
    > http://65.98.59.170/$sitepreview/Ozark-Development.com/test.cfm
    >
    > Here is the code for the test page.
    >
    > <body>
    > <cfset X = 1>
    > <cfif X eq 1>
    > <p> cfif is working </p>
    > </cfif>
    >
    > <cfif isdefined("X")>
    > <p> isdefined is working </p>
    > </cfif>
    >
    > <cfif isdefined("form.submit")>
    > <p> form.submit is defined </p>
    > <cfelse>
    > <p> form.submit is not defined </p>
    > </cfif>
    >
    > <cfform>
    > <cfinput type="submit" name="Submit" id="Submit" value="Search">
    > </cfform>
    > </body>
    >
    OzarkwebAuthor
    Participant
    July 5, 2008
    That did it. Why would it work on my own server but not theirs I wonder. Must be a version difference, I am running CF 8 and they are running 7.

    Thank you,
    Matt