Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.

  1. #1

    Default Cookis Problems

    I have the following code in my page:

    <cftry>
    <cfldap action="QUERY"
    name="auth"
    attributes="cn"
    start="cn=users,dc=dummyDomain,dc=com"
    server="server.dummyDomain.com"
    username="dummyDomain\#form.uid#"
    password="#form.password#">
    <cfset isAuthenticated="yes">
    <cfcookie name="Authenticated" value="Yes" expires="#DateAdd('H', 5,
    Now())#">
    <cfcatch type="ANY">
    <cfset isAuthenticated="no">
    </cfcatch>
    </cftry>

    <cfif isAuthenticated EQ "no">
    <cflocation url="is_login.cfm">
    <cfelse>

    Then I have the page as I want it to display. My question is that the cookie
    is evidently not ever getting set. How can I use a cookie on this page so that
    everytime the page loads it doesn't go to the login page? I want to use LDAP
    login to secure this page. Preferably I would also like to narrow it down to a
    specific group also.

    Thanks for any help.

    jgrantham Guest

  2. Similar Questions and Discussions

    1. problems with 8.0 Rc4
      I've been trying to check that my current application working on postgres 7.4 will work with 8.0. I've not checked the application yet but I'm...
    2. problems with preLoadNetThing and fileName (was problems with preLoadNetThing and importFileInto)
      You don't want to leave the QT member in your cast when you publish your movie - it's not really there, it's linked. When you run the movie it will...
    3. IE6 problems
      I have a login script to a website where a user logs in through a standard webform with a username and password that needs to be validated. My...
    4. I having problems with IIS
      I just tried to view a page that I had earlier on my own personal web site and was not able to view it. I then tried just plain old localhost and...
    5. Why am I Having Problems ?
      On 8/2/03 1:08 PM, in article 6TUWa.216121$o86.33889@news1.central.cox.net, "Spam@markris.com" <Spam@markris.com> wrote: A Relationship requires...
  3. #2

    Default Re: Cookis Problems

    Hi

    I have found that if you set a CFCOOKIE on a page before a CFLOCATION the cookie doesn't get set.
    The code isn't going into a CFLOCATION after the CFCOOKIE is it?

    Zoe
    zoeski80 Guest

  4. #3

    Default Re: Cookis Problems

    It was. I got it fixed by using a javascript like the following:

    <Script language="javascript">
    document.location.href ="http://mydummysitecom/is_login.cfm";
    </Script>
    jgrantham Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139