Install Coldfusion MX on IIS server

I am loading CFMX on the webserver and want to have IIS as the web server not the one in the program.  The problem is that the root directory of the IIS is not in C.  when I load CF I load it into the drive and give the directory a name.  Then I place the website into the main directory of the cf install - not the wwwroot folder.  The cf website will be the new default website and the other site will go away.  Every time I bring up the administrator I get a Page display error - pointing to the default site - but when i put in the IP address of the server then it comes up just fine.  The same goes for the new site.

What am I doing wrong??  


thanks!
ahillmanAsked:
Who is Participating?
 
KoldFuzunConnect With a Mentor Commented:
that looks correct. Sorry, I had a flood here yesterday, 6" of water in my place that we are cleaning up. As soon as I am able I will work with you on this again unless you fix it before then :)
0
 
ahillmanAuthor Commented:
Correction - to access the new site there is no error - you just get a windows login screen and then you gain access to the site.  Seems like a permission thing with the folders - but I have given read rights to all of them.
0
 
mrichmonCommented:
I think you may have installed wrong.

You want to install CF onto the C Drive - or whichever drive your windows install is on - it doesn't matter where the root of IIS is.  In fact it is better not to have the website root on the same drive as CF or other programs.

SO you install to C:/CFusionMX and choose IIS.

Then you configure IIS to point to the root of your website - which is not on the C drive.

This would be the best method.  So, while you could probably get it working this way, you would be better off uninstalling CFMX and reinstalling as above.
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
ahillmanAuthor Commented:
So I would do this:

There is no room on the C drive for coldfusion - so I need to install it onto the D: drive and put it into the D:\CFusionMX directory.  The site is outside of this directory on d:\CFfusion.  I then have IIS point the default site to D:\CFfusion.
0
 
ahillmanAuthor Commented:
I tried placing an index.htm file into my coldfusion site and the site launched just fine.  the .cfm files are not being recognized.  Any ideas?  Or is all this because I really need to load onto the C drive where windows was installed and not the d drive?
0
 
mrichmonCommented:
OK that is okay.

But you should not have IIS point to the CFusionMX install.

It needs to point to the root of the website.

Such as D:\Mywebsiteroot

0
 
ahillmanAuthor Commented:
thats what I did - I installed Coldfusion MX to D:\CFusionMX and then have my site sitting on the D:\  I then tell IIS to look at D:\mysitename.  When I install there are two places in the wizard where you have to specify 1) where to install coldfusion and 2)where is the web root.

The first one should go to d:\CFfusionMX and the webroot is d:\mysitename - correct?

0
 
mrichmonCommented:
Technically when I installed CF I only specified where to install cold fusion and left the root as default.

Then you specify during the install to use IIS over the built in CF runtime engine.

THen you specify in IIS where the actual web root is.  CF doesn't need to know this to function.  Because the web root may not even exist when you install CF to the server.

I still think the best bet would be a clean install.
0
 
ahillmanAuthor Commented:
I will try that out today and let you know if it works. Thanks for your quick responses!
0
 
ahillmanAuthor Commented:
Hello there again,

Looks like that didn't work either - I am beginning to think this is more of an IIS issue than a coldfusion issue.  I will leave this question open so if you come up with any ideas that resolve this issue I will gladly give you all the points.  I think I better post though in a different area for the IIS issue and see if I get any bites.

Thanks for your help and hopefully between the two of us
(or whom ever else participates) I can get this thing up!  Thanks!!
0
 
KoldFuzunCommented:
Are you using IIS 6? Check to be sure that .cfm is set up under "Home Directory>>Configuration>>App Mappings" in your IIS website. For IIS 6 you will need to allow the CF extensions under "Web Service Extensions" in the IIS MMC
0
 
ahillmanAuthor Commented:
Yea - I made sure the extensions are there.  
0
 
KoldFuzunCommented:
Have you made sure the service is running? Are there any errors in the event log?
0
 
ahillmanAuthor Commented:
Yes -no errors - If I don't have the application mappings(extensions) then I don't have a login screen that pops up - but of course my applications don't work then.  when they are added in then I get the windows login screen and then it takes me to my site.  I  have tried giving full permissions to everyone on my website and even that makes me login through authentication.

Any ideas?
0
 
KoldFuzunCommented:
What are the permissions on the folder?

Also, what is the mapping for the extension, both for

Home Directory>>Configuration>>App Mappings

And

Web Service Extensions

TY
0
 
ahillmanAuthor Commented:
Well - the permission have web sharing and everyone has read persmissions.
The mappings I know are supposed to go to folder 1\jrun.dll but for some reason they are going to 2\jrun.dll. The 1 folder under wsconfig was empty but folder 2 has the jrun.dll and readme notes etc....

The services are going to :  root directory\CFudionMX\runtime\bin\jrunsvc.exe
0
 
ahillmanAuthor Commented:
CFusion was misstyped - it is correct on directory
0
 
KoldFuzunCommented:
I believe you should add SYSTEM to the permissions and set it to FULL CONTROL, if CF is using the system account. Or if it is using another account to run, then give that user FULL CONTROL.

Your mappings under Home Directory>>Configuration>>App Mappings should map to this for Windows 2003 Server, IIS6

(replace path with your own)

C:\CFusionMX\runtime\lib\wsconfig\jrun_iis6.dll


0
 
KoldFuzunCommented:
take a look at http://www.sanative.net/cfmappings.jpg to see how i have mine configured
0
 
ahillmanAuthor Commented:
Where did you locate the web extensions properties box you show on the right side?
0
 
KoldFuzunCommented:
if you are on Windows 2003 Server, it is under Web Service Extensions in IIS
0
 
ahillmanAuthor Commented:
We are on windows 2000 server
0
 
KoldFuzunCommented:
ok, then you wont have that option
0
 
ahillmanAuthor Commented:
And I was getting all jubilant because I thought that could be it!  :)  The other screen shot is like mine - only we aren't on IIS 6
0
 
KoldFuzunCommented:
Bummer, sorry :)

Does your CFMX folder have SYSTEM full control permissions on it?
0
 
KoldFuzunCommented:
hey also check to be sure that the JRUN connection filter is running under the ISAPI Filters tab. To check this, go into the MMC panel for IIS, right click on the Server (not virtual server), and select Properties. In the Internet Information Services tab, click the Edit button next to Master Properties. The ISAPI Filters tab is there.


Also your extensions should be mapped in IIS 5 (W2K) to:

(replace path with your own CFMX dir)

C:\CFusionMX\runtime\lib\wsconfig\1\jrun.dll
0
 
ahillmanAuthor Commented:
Taking a look now....
0
 
KoldFuzunCommented:
http://www.sanative.net/isapifilters.jpg

will show you how mine looks on my W2K server
0
 
ahillmanAuthor Commented:
Yep thats how mine looks...So you know - could not install to my C: drive had to go to D:
0
 
KoldFuzunCommented:
do me a favor, go into the services control applet, go into the properties of ColdFusion service, and change the account to the admin account and password. restart CFMX and then try it. You dont need to leave it set to this, just for testing
0
 
ahillmanAuthor Commented:
Local administrator or network administrator?
0
 
KoldFuzunCommented:
either one should work fine, try both :)
0
 
ahillmanAuthor Commented:
Says it couldn't start the application server due to login failure.
0
 
KoldFuzunCommented:
that's interesting. are you sure you typed the password correctly? ;) for network admin you have to use the domain\username or username@domain.com
0
 
ahillmanAuthor Commented:
okay - got it started under a different administrator password - forgot we retired the old one!  :)
0
 
KoldFuzunCommented:
okay cool :) will the CF pages run now?
0
 
ahillmanAuthor Commented:
Nope :(  Still have that darn windows login!  If I put in the credentials then I get admitted to the site.  I have already gone through all of IIS on another this topic and exhausted that as a conclusion of fault.  It has to be something with the permission of seeing .cfm files.
0
 
KoldFuzunCommented:
so when you put the credentials in, will CF pages run? If that is the case, then the default domain is probably not set correctly for the virtual server
0
 
ahillmanAuthor Commented:
Yes the pages run perfectly. What do you mean about the default domain for the virtual server - can you walk me through to double check?
0
 
KoldFuzunCommented:
Do you have the "Basic Authentication" option checked in IIS under the virtual server security settings? If not, do so, and click the edit button to make sure the domain is set to the same domain as the user in the Anonymous Access options. Basic authentication is required even though you are allowing Anonymous access, because the anonymous accoutn still sends a username and password to the Windows server. At least that is my understanding
0
 
KoldFuzunCommented:
also you can try from the command line

adsutil set w3svc/DefaultLogonDomain "YOURDOMAINNAME"

You must be in the AdminScripts folder, which is installed into the Inetpub folder at IIS installation time. If you have never run these scripts before it will probably ask you to change to CScript, which is OK
0
 
ahillmanAuthor Commented:
Actually we have the windows authentication checked - even though you would think this would explain things it doesn't.  Even if I have nothing checked in the authentication beyond admitting users - I still get a windows authentication login.
0
 
KoldFuzunCommented:
K, remove the WIndows Authentication, this is likely the problem. Change it to Basic. Windows Authentication is pretty much only good for intranets, at least in my experience :)
0
 
ahillmanAuthor Commented:
Nothing is loaded into C:\Inetpub\wwwroot.  We have had that hacked into a few times so we run our sites from D: instead.
0
 
ahillmanAuthor Commented:
I still get a login screen - but good info to keep in mind for the future.
0
 
KoldFuzunCommented:
ya common problem unless you are strict with your security settings. You might be able to pull adsutil.vbs from the install CD and just put it whereever you want to run it to change the default domain
0
 
ahillmanAuthor Commented:
Just so you know - don't remember if I stated this here or not - but the previous webmaster disableds localhost in order to force the IP address to be used.  Is this causing problems?
0
 
ahillmanAuthor Commented:
So you are saying that its my default domain thats causing the problems?
0
 
KoldFuzunCommented:
potentially, i cant say for sure. I believe there are issues with disabling localhost, but cant say what
0
 
ahillmanAuthor Commented:
The reason given was also that localhost can pose security risks.
0
 
KoldFuzunCommented:
Default Logon Domain has caused me a lot of issues like you are seeing. I would like to set it to be sure, and the adsutil has always been the best at doing so.

Also make sure that the IUSR_ account you are using in the anonymous access tab has the same password as the account in Windows, especially if it is not the default password assigned by windows. Recently I went and changed this password and had to go into every virtual and change the password in the web serttings.... pain.

Also, make sure that account is not disabled, and that is has permissions to log on locally
0
 
KoldFuzunCommented:
localhost poses no security risk to my knowledge. it is a loopback address that only the local machine can make requests too. If there is some documentation behind that I would be highly interested in reviewing it!
0
 
ahillmanAuthor Commented:
The IUSR is a local account not in active directory.  How do I run the adsutil and where do I find it please?
0
 
ahillmanAuthor Commented:
The security issue was the answer I was given when asking the same question of why was it disabled?
0
 
KoldFuzunCommented:
i can email you a copy of adsutil if you like
0
 
ahillmanAuthor Commented:
Yes please - when I receive it I can just copy it to a floppy and then run it from our server?
0
 
KoldFuzunCommented:
you can. how do i email to you ;)
0
 
ahillmanAuthor Commented:
ahillman@fulton.cnyric.org - I will try it out and get right back to ya!  This is much better than sitting around reviewing everything for the 20th time just to be sure....
0
 
KoldFuzunCommented:
sent
0
 
ahillmanAuthor Commented:
by the way is this an executable that you are sending? if so it won't make it past our security settings.  Also once I receive this - can I just run it from the floppy?
0
 
ahillmanAuthor Commented:
okay so i ran the script - still the same thing:  This is what shows up on my address bar:
http://serverIP/CFfulton/index.cfm
0
 
ahillmanAuthor Commented:
I was looking in the adsutil.vbs script and where do I need to name the domain name?
0
 
KoldFuzunCommented:
adsutil set w3svc/DefaultLogonDomain "YOURDOMAINNAME"  


Yourdomainname should be the name of your domain
0
 
ahillmanAuthor Commented:
But when I open the script to edit it - where in the script should I look?  :)
0
 
KoldFuzunCommented:
oh you dont need to... you just run that command from the command line
0
 
ahillmanAuthor Commented:
It doesn't recognize adsutil as a command - obviously I am missing something arent' I?
0
 
KoldFuzunCommented:
you need to be in that folder when executing the command. So if the file is on A:\scripts\ here is what you do

a:

cd scripts

adsutil set w3svc/DefaultLogonDomain "YOURDOMAINNAME"  


OR alternatively

A:\scripts\adsutil set w3svc/DefaultLogonDomain "YOURDOMAINNAME"  

0
 
ahillmanAuthor Commented:
so c:\inetpub\AdminScripts\adsutil ....
0
 
KoldFuzunCommented:
if that is where the file is, yes :)

open a command line window

cd to c:\inetpub\AdminScripts\

then

adsutil set w3svc/DefaultLogonDomain "YOURDOMAINNAME"  
0
 
ahillmanAuthor Commented:
Well - I did it and it ran just fine.  :)  BUT - still no go with the viewing of the site.  Still have that pesky login window.  do I need to stop services or restart or anything?
0
 
KoldFuzunCommented:
you should, but it probably isnt necessary.

are you certain that the IUSR_ user isnt disabled or had a password change?
0
 
ahillmanAuthor Commented:
the iusr is just a local profile on the guest account.  the settings are password never expires and user can't change password but the account isn't disabled.  does the iusr need to be in active directories?
0
 
KoldFuzunCommented:
it doesn't... it can be a local account

*thinking*
0
 
KoldFuzunCommented:
check the security settings on the folder CFusionMX\lib

Mine are set to Everyone Full Control
0
 
KoldFuzunCommented:
sorry that should be CFusionMX\runtime\lib
0
 
ahillmanAuthor Commented:
checking
0
 
ahillmanAuthor Commented:
I tried that - still no go - are you drained of solutions yet? ha!
0
 
KoldFuzunCommented:
also, just to be sure: Under the Anonymous user settings is "Allow IIS to control password" checked?

Also I just noticed most of my webs are setup using Windows Authentication checkbox, so I could be very wrong about my comments on that!
0
 
ahillmanAuthor Commented:
Yep - all there - and yes - I had changed my authentication back to windows.
0
 
KoldFuzunCommented:
you know, my entire CFusionMX is set to Everyone Full Control (will have to look into potential security risks with that!) . Is yours set the same?
0
 
ahillmanAuthor Commented:
No - I was concerned to do that - but I will try it out.
0
 
ahillmanAuthor Commented:
No go - I even gave full permission to everyone on the site directory - do you have directory browser checked?
0
 
ahillmanAuthor Commented:
When I installed CFMX - I loaded it to D:\CFusionMX and then I have the root being D:\ and then IIS pointing to the d:\mysitename.  Is this correct or do I need to reinstall?
0
 
ahillmanAuthor Commented:
Thank you for all of your help - hopefully a good nights rest will bring a solution to mind.  Have a good day - and again thanks for taking so much time out of your day.

:)
0
 
ahillmanAuthor Commented:
Hello there - I got it working!  There was a read only checked on one of the main folders and that was causing problems!  It figures - always the small things!

I do have another question though and I think maybe you could assist?  Let me know if I need to open another question though.
I am able to see my calendars and do searchs but when I want people to log into the calendar administration on my pages - they cant login.  When I test it on the server it works fine - when I test it on my developers server it works fine - so its not the code - seems that there is a persmissions thing stopping it.  I tried making the folder that contains the application shared but that didn't work - plus I want the security anyway.  Any thoughts?

Thanks!  Hope that water didn't cause too much of a headache yesterday!
Aimee
0
 
ahillmanAuthor Commented:
Scripts access was not checked either - that seems to be the real solution!  Still can't get my calendar application to login under IIS though - if you get the chance and you think of something - please let me know your thoughts.  I appreciated all of your devoted time!
0
 
KoldFuzunCommented:
Hi Aimee,

Ya the water did tons of damage... such is life. Trying depserately to get carpets replaced, ugh!


When you say "login under IIS" do you mean that you want to have a Widows username/password prompt and that it is not working on one of the servers?

TJ
0
 
ahillmanAuthor Commented:
I have a db in SQL 2000 that I use to authorize users to a calendar events application.  This application lets administrators add events to their respective calendars in the school district for everyone to view on our site.  The code behind the application is just fine - its just not letting me login.  No errors - just does what it is supposed to do if the username and/or password are not recognized.  The other pieces in my site that need to grab information from the same db are working just fine.

Any clue??

Sorry about your carpets - its a nightmare - had our basement flood and all of our things got ruined - been running our de-humidifier for weeks now!
0
 
KoldFuzunCommented:
Hmmm, you are certain that the users are in the database and the calendar datasource is correct? These are tough to pinpoint, because it is usually code-related if it is a CF-based login and not a Windows login. you could send your code to me for review if you like, but i also understand the need for secrecy on these types of apps :)
0
 
ahillmanAuthor Commented:
Well.....The application works great on the localhost:8500 developement server - I would think that if it was code related then it wouldn't work at all?

Here is the code though - just so you can get a feel for the application.

Login Form:
<CFIF IsDefined("Form.UserLogin")>
  <CFINCLUDE TEMPLATE="LoginCheck.cfm">
</CFIF>

Then your basic cfform for input.

Login Check:

<cfif ISDEFINED ("Form.UserLogin")>
      

<!--- Make sure we have Login name and Password --->
<CFPARAM NAME="Form.UserLogin" TYPE="string">
<CFPARAM NAME="Form.UserPassword" TYPE="string">

<!--- Find record with this Username/Password --->
<!--- If no rows returned, password not valid --->
<CFQUERY NAME="GetUser" DATASOURCE="#datasource#">
  SELECT *
  FROM [table]
  WHERE username  = <cfqueryparam value="#Form.UserLogin#" cfsqltype="CF_SQL_CHAR">
        AND password = <cfqueryparam value="#Form.UserPassword#" cfsqltype="CF_SQL_CHAR">
</CFQUERY>

<!--- If the username and password are correct --->
<CFIF GetUser.RecordCount EQ 1>
  <!--- Remember user's logged-in status, plus --->
  <!--- ContactID and First Name, in structure --->
  <CFSET SESSION.Auth = StructNew()>
  <CFSET SESSION.Auth.IsLoggedIn = "Yes">
  <CFSET SESSION.Auth.userID  = GetUser.userID>
  <CFSET SESSION.Auth.username = GetUser.username>
  <CFSET SESSION.Auth.fName  = GetUser.fName>
  <CFSET SESSION.Auth.userRole        = GetUser.userRole>
 
<CFQUERY DATASOURCE="#datasource#" NAME="getlocs">
Select *
From [table]
WHERE username = '#session.auth.username#'
</CFQUERY>
<cfset "session.auth.loclist" = "">
<cfloop query="getlocs"><cfset "session.auth.loclist" = Insert(",#locID#,", session.auth.loclist,0)></cfloop>

  <!--- user is logged in--->
   
        <cflocation url="{appropriate url}" addtoken="no">
 <cfelse>
 <cflocation url="LoginForm.cfm">
 
      </CFIF>
      
</cfif>
0
 
KoldFuzunCommented:
questions

GetUser.RecordCount EQ 1
Are you certain there is only one user with the username and password you are testing?

are you certain Form.UserLogin is being passed?
0
 
ahillmanAuthor Commented:
The username is unique - and yes the userlogin is being passed - at least it is under the developement server.
0
 
KoldFuzunCommented:
try outputting form.UserLogin on the production server and see if it displays a value on the page
0
 
ahillmanAuthor Commented:
What happens is:

when I login from the production form - it does work - since it takes me to the location specified by the login check.  I use the session.auth.username to identify to the administrator that is logged in who they are.  id - #session.auth.username#  - this outputs correctly.
0
 
ahillmanAuthor Commented:
Here is a text of the application on the site - notice the username is identified:
 
You are currently logged in as tvanduze

Calendar Administration
Add New Event

You can add new events from this section, and view all events in the calendar.
 Modify Event

Edit/Delete Events.
 
 
0
 
KoldFuzunCommented:
ok so I am confused :)

You can login on both the dev and production server? (dev is development, as you know, production is the live server)
0
 
ahillmanAuthor Commented:
I can login on the dev server which uses the CFMX local server - but the production server just goes back to the login form - like it is supposed to do if the username is not found.
0
 
ahillmanAuthor Commented:
This is really strange - when I logged into the CF adminsitrator on the production server and then with out closing it out I tried went and viewed the new site - then tried to log into the application - it worked!  So I then closed the window which logs me out of both the CF administrator and the application - I went and opened the website again and tried to log into the application and the thing didn't work.  Why when the administrator was open did it work and not when it wasnt open???  
0
 
KoldFuzunCommented:
are sessions enabled on the production server? In the CF Administrator go to Memory Variables and ensure the "Enable Session Variables " option is checked
0
 
KoldFuzunCommented:
hehe, ya i think you need to enable session variables in the admin... i believe the cf administrator tool temporarily enables them during its use, which is why it may be working
0
 
ahillmanAuthor Commented:
All three are enabled
0
 
ahillmanAuthor Commented:
:(
0
 
KoldFuzunCommented:
Ok, are you using an application.cfm file? if so it should have the following in the cfapplication tag

sessionmanagement="yes"
0
 
KoldFuzunCommented:
fyi, you must have an application.cfm if you are using sessions :) you probably know this already tho
0
 
ahillmanAuthor Commented:
Yep - and it is set to yes

<cfapplication      
      name="[name]"
      sessionmanagement="Yes"
      clientmanagement="no"
      setclientcookies="no"
      setdomaincookies="no">
0
 
ahillmanAuthor Commented:
And you thought this was going to be a walk in the park! HAHAHAHAHAHAHA  - one thing I have learned about CF or any other language - nothing is as it seems!
0
 
KoldFuzunCommented:
thats wierd... it seems to me that the session is not being instantiated. Can you replace the LoginCheck.cfm with a test file and output all session and form variables?
0
 
KoldFuzunCommented:
hehe, I been doing CF since 2.0, so I know that the stuff that seems the easiest to solve is always the thing that will drive ya nuts. and usually when you find the solution it was as easy as you thought!
0
 
KoldFuzunCommented:
actually just replace the logincheck with a file that does this:

<CFQUERY NAME="GetUser" DATASOURCE="#datasource#">
  SELECT *
  FROM [table]
  WHERE username  = <cfqueryparam value="#Form.UserLogin#" cfsqltype="CF_SQL_CHAR">
        AND password = <cfqueryparam value="#Form.UserPassword#" cfsqltype="CF_SQL_CHAR">
</CFQUERY>

<!--- If the username and password are correct --->
<CFIF GetUser.RecordCount EQ 1>
  <!--- Remember user's logged-in status, plus --->
  <!--- ContactID and First Name, in structure --->
  <CFSET SESSION.Auth = StructNew()>
  <CFSET SESSION.Auth.IsLoggedIn = "Yes">
  <CFSET SESSION.Auth.userID  = GetUser.userID>
  <CFSET SESSION.Auth.username = GetUser.username>
  <CFSET SESSION.Auth.fName  = GetUser.fName>
  <CFSET SESSION.Auth.userRole       = GetUser.userRole>
 
<cfoutput>#Form.UserLogin#<br>
#GetUser.RecordCount#
</cfoutput>
<cfdump var="#SESSION.Auth#">


This will tell us where the problem is
0
 
KoldFuzunCommented:
oops, take out the cfif :)
0
 
ahillmanAuthor Commented:
thinking....
0
 
ahillmanAuthor Commented:
Well - I am annoyed now - I set up the loginform to go to the the test.cfm instead of the the login chech and it is still taking me to the designated page as though it went through the login check!
0
 
KoldFuzunCommented:
cached probably.... try closing the browser and reopening, maybe restart the CF service if you can to clear the CF cache
0
 
ahillmanAuthor Commented:
Okay - its working properly the output was correct.

admin
[number] struct
FNAME admin
ISLOGGEDIN Yes
USERID [id was here]
USERNAME admin
USERROLE [role was here]
0
 
ahillmanAuthor Commented:
Here is another twist:

I have made the site live now - if you try to log into it through the www.fulton.cnyric.org address it doesn't work - if you use the server IP address then it does log you in.
0
 
KoldFuzunCommented:
ok, cool. so the structs are being created properly, the form fields are being passed and the record count is only 1, correct?

0
 
ahillmanAuthor Commented:
Yep - and never mind about it working through the IP address - it was cached.  :)
0
 
KoldFuzunCommented:
ok, so from looking at the LoginCheck.cfm I do not see any reason why it would be working. Is there any reason why the calendar page (or any page it calls/includes) might be pushing to the login page? Any exception catches, etc?
0
 
ahillmanAuthor Commented:
Can you rephrase?
0
 
KoldFuzunCommented:
ok, after logging in what page is the user directed to? Does that page have any cflocation or cfinclude tags in it?
0
 
ahillmanAuthor Commented:
that is the defualt page after loggin into it.  The page is set up for 3 user roles.  If you are an administrator then you get to see everything - if your userrole is greater than 2 then you see the next level - if just 3 then you are a default user.  No other cflocations etc...
0
 
KoldFuzunCommented:
try commenting out the cflocation tag and see what happens
0
 
ahillmanAuthor Commented:
on the login check form?
0
 
KoldFuzunCommented:
yea :)
0
 
ahillmanAuthor Commented:
The login form just returns to itself.
0
 
ahillmanAuthor Commented:
actually - if I actually comment out the whole cflocation - (both of them) then I get a blank white page.
0
 
KoldFuzunCommented:
so your form submits to logincheck.cfm, and in logincheck.cfm you have 2 cflocations:

<cflocation url="{appropriate url}" addtoken="no">

<cflocation url="LoginForm.cfm">

comment out

<!--- <cflocation url="LoginForm.cfm">  --->

replace with LOGIN FAILURE
0
 
ahillmanAuthor Commented:
looks like this:

<cflocation url="viewAdmin.cfm" addtoken="no">
 <cfelse>

 <cflocation url="LoginForm.cfm" addtoken="no">
0
 
KoldFuzunCommented:
<cflocation url="{appropriate url}" addtoken="no">

I wonder if this tag is causing the session to be lost.... so lets try this:

<!---<cflocation url="viewAdmin.cfm" addtoken="no"> --->
Login Success

 <cfelse>

 <!--- <cflocation url="LoginForm.cfm" addtoken="no"> --->

Login Failure
0
 
ahillmanAuthor Commented:
showed login success
0
 
ahillmanAuthor Commented:
Actually showed login success twice
0
 
KoldFuzunCommented:
ok, so now we know logincheck.cfm works properly. you can undo those changes.

Our problem is either in the process of the cflocation or in the viewAdmin.cfm page. any place in the viewAdmin.cfm where you StructClear() the session? or reset any of the session values?

Maybe try doing a cfinclude instead of a cflocation to viewAdmin.cfm
0
 
KoldFuzunCommented:
"Actually showed login success twice" that is wierd.... i do not see anything within that page which may cause that, unless you accidentally have "login success" there 2x
0
 
ahillmanAuthor Commented:
Could be -

well I changed the cfinclude to a cftemplate - and that logs me in - but how do I keep the user logged in though - anytime the user goes somewher else they have to relog in.
0
 
KoldFuzunCommented:
for some odd reason CF is not saving the session variables to memory. Are you running on clustered servers?
0
 
ahillmanAuthor Commented:
Nope - I am going to change the logincheck back though so I can maintain my code.  Very strange!  
0
 
ahillmanAuthor Commented:
I added this to my viewAdmin.cfm which is the default page and it seems to be working - give me a minute to test.  Let me know if you come up with a less messy way.

<cfif isDefined ("#session.auth.username#")>
IsloggedIn
</cfif>
0
 
ahillmanAuthor Commented:
Nope - didn't work out - shoot - thought it would be a good work around.
0
 
ahillmanAuthor Commented:
When I log into the CF administrator it never comes up properly - I have to insert the server IP address first and then the login screen pops up for the CF administrator - would this be interfereing with the session variables?
0
 
ahillmanAuthor Commented:
by the way - do you want me to open a new question up for this issue - so you can get awarded more points??  :)
0
 
KoldFuzunCommented:
oh wait, are you guys using host headers for your site. meaning, do you have a single IP address on the server and multiple website using that IP?

If you want to open a new question that is fine. Im not too worried about points ;)

 also do you have setclientcookies="yes" in your application.cfm application tag?
0
 
ahillmanAuthor Commented:
setclientcookies is ="no",
there is X-Powered By: ASP.Net set as a host header - its in there from out .asp site - do I need to remove it for the .cfm site to work? I really don't know anything about the headers. And yes we only have a single IP address on the server - but only one website - our default - we will be adding an intranet later.

0
 
KoldFuzunCommented:
setclientcookies is ="no" needs to be YES, which is why it isnt working ;)

X-Powered By: ASP.Net  - no biggie. I always remove this to remove MS's insistance on adding their branding to everything. it does nothing except add that info to the headers of the site.



0
 
KoldFuzunCommented:
http://www.experts-exchange.com/Web/WebDevSoftware/ColdFusion/Q_21062477.html

This link will give you more info on your problem!
0
 
ahillmanAuthor Commented:
YOU HAVE GOT TO BE KIDDING ME!!!!!!!
Oh man....................that did it - where do I send my check - the least I can do is buy you new carpets! HAHAHA
0
 
KoldFuzunCommented:
hehe, ty for the offer but not necessary ;) When I started programming I used to bug the heck out of Ben Forta, so I am happy to offer the same help to others. The landlord and I just got through tearing out the carpets and awaiting the insurance adjuster...
0
 
ahillmanAuthor Commented:
Happy repairs - and just so you know - I am keeping your KoldFuzun name in mind for any upcoming issues we may have with our intranet! :)
0
 
KoldFuzunCommented:
excellent, ty. You have my email address, and I would be happy to give you my IM info and phone number... happy to know everything is ok :)
0
All Courses

From novice to tech pro — start learning today.