[CB v1.5.7] Fresh install, can't get to Site admin, all links on page redirect to home.

Hello,

I just installed CF10 developer, Got CB installed with my MSSQL database. For the most part everything went fairly smooth. At the end of the installation it had asked me if I wanted to use ReWrite and I selected yes and selected IIS7 as that is what I’ve got it installed on.

After the installtion, I clicked on the go to Administration button and it redirected me to my homepage. The odd part is that the URL is http://beta.isoportal/cbadmin/security/login. If I click any link the URL changes, but the page stays the same.

Example:

Entries RSS
http://beta.isoportal/blog/rss

Login
http://beta.isoportal/cbadmin/security/login

About
http://beta.isoportal/about

Home
http://beta.isoportal/

All these show the same homepage with my first entry, yada yada…

Does anyone have any idea what the cause is? Or how to fix?

Please let me know if I need to provide any further detail.

Thanks,
Marco

Hi Marco,

Yes, definitely a rewrite issue. Can you post the web.config created for you and paste it here. Anybody else running IIS7? I will try on my windows machine tomorrow.

However, if you want, remove the rewrites for now by doing the following

  1. Open the config/routes.cfm and in the SESBaseURL() add “index.cfm” to the end of the routes like this:

// Base URL
if( len(getSetting(‘AppMapping’) ) lte 1){
setBaseURL(“http://#cgi.HTTP_HOST##getContextRoot()#/index.cfm”);
}
else{
setBaseURL(“http://#cgi.HTTP_HOST##getContextRoot()#/#getSetting(‘AppMapping’)#/index.cfm”);
}

  1. Remove the web.config and restart CF or the application using index.cfm?fwreinit=password here

That at least should allow you to do everything until you can resolve this IIS issue.

Luis F. Majano
CEO
Ortus Solutions, Corp
www.ortussolutions.com

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

Social: twitter.com/lmajano facebook.com/lmajano

Okay, followed your instructions for workaround. However, Removing the web.config caused an endless loop of some sort. All is working with just the web.config in place & adding /index.cfm

Thanks and I hope we can get the correct rewrite rules in place soon.

-marco

attached web.config

web.config (2.79 KB)

Marco, I have my windows machine now. Can you tell me if you are using the download from the gocontentbox.org site or from github?

Marco,

I did a fresh install and deployed with cf10 on an IIS 8.5 in a windows 8 machine. The web.config attached which is untouched, worked perfectly for both the admin and site.

I would make sure that the “Rewrite” module is installed in IIS first.http://www.iis.net/downloads/microsoft/url-rewrite

Did you verify that you have that module installed?

Yes, I have re-write installed. I was using IIS7 & Windows 7. I installed re-write myself and I know it is working.
If I remove the web.config, or even just remove all the rules from within the web.config, nothing works. So in some way the re-write is working, but something is slightly off.

The workaround did work.

// Base URL
if( len(getSetting(‘AppMapping’) ) lte 1){
setBaseURL(“http://#cgi.HTTP_HOST##getContextRoot()#/index.cfm”);
}
else{
setBaseURL(“http://#cgi.HTTP_HOST##getContextRoot()#/#getSetting(‘AppMapping’)#/index.cfm”);
}

But I cannot delete the web.config, it just literally kills it.

Everything seems to be working now with the above setup, but URL’s look like:
http://beta.isoportal**/index.cfm/**cbadmin/layouts

Note the bold /index.cfm/

Let me know if you need anything else from me. I have not really changed anything. This is an Out of the Box installation.

On a side note. Pretty freakin cool!!!

I do have a question about creating a Members section so that users that signup to the site can have a Members area. My project, is to create a members only area of the website that has reporting features. Any High overview suggestions as to what direction I would take. Do i use modules for that?

thanks,

Marco, do me a favor.

Open the web.config and look for the last like this one:

and do this instead:

This will add the rewritten URLs to the IIS log files. Do that and verify your log files and see what is the issue. I would also make sure that your CF10 installation is fully patched. I know it had several IIS rewrite issues in the initial versions. This is the last update level:

ColdFusion 10 Update 12 Tuesday, 12 November 2013

As for your question about member sections, we do this all the time for client projects. It all depends on the complexity of your security and rules. The way to go is to write a custom module for it that extends the UI modules and the admin modules. This is something we actively work on, so if you need professional services, we can surely get you going in no time.

I think i might take you up on that once I stop pulling out my hair with CF Builder. Yeah, I know you all love it, but I am a Dreamweaver guy and every time I try to go to CF Builder I can never seem to get the Server to setup with CF(any version) and IIS. Server always says “Stopped”. I use IIS because I love it over Apache, personal preference. I’ve just blown about 4 hours … Again… trying to get CF Builder to play nice with CF10 & IIS 7.5. (still not working) I wish the CF team would get their heads out of their bums and write some solid how to documentation that does not revolve around their own built in web server!

/Rant over! Thanks for the ear! ha!

But ya, once I get going to where i can make modules ( BTW - i’m trying to use CF builder explicitly because of your tools ) , I would gladly talk Professional services to steer me in the right direction on a member section.

Thanks,

Marco, with ColdFusion builder it will say stopped for a very good reason. But first is ColdFusion installed on the same machine as CFB or are you trying to connect remotely to ColdFusion?

  1. If you are trying to do this locally, then you will need to Run as Administrator for CFB to work right.
  2. If remote, you have to make sure that the Admin services have been started and that CFB has beeb run as Administrator.

If you follow that, you should have no more issues with CFB.

Also, sometimes when you are having issues with rewrites you might have missed rebuilding your IIS connectors after a CF update.

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

Yeah, had some trouble with that also Brad. When I remove the Connectors, I have to use some strange batchfile I found that adds them back, otherwise when i click “add” the Sever Cluster is missing, whereas normally it says cfusion there. Strange stuff happening. I was able to find a batch file called c:\Coldfusion\cfusion\ConnectorInstall0.bat and when I ran that it added it back and my server started to work again.

Andrew & Luis, I made a youtube video of what i’m going through on both Re-Write and CF Builder.
http://youtu.be/xaJFij6vmvE

Update to the above video. Re-Write is now working after brad suggestion.

So I take it that CF 10 Updates to Update 12 + Remove / Add back Connectors fixed the Re-Write issue.

CF builder issue still not solved, but i guess I could start a new thread about that one.

Thanks for all the help guys! I love how great the support has been here!

Luis, when do you have time to talk Professional Services?

Marco,

First, no need to create a new thread, just reply here and I’ll continue to reply.

As you have the rewrites working, then I will skip over that bit. The connectors can be setup with another and the right tool for the job, is in the location you installed ColdFusion 10. By default this is ColdFusion 10 on the c:\ drive. Inside that folder you will find the cfusion folder, so click in there. You need to then go down to the runtime folder and go inside that and last you will need to enter the bin folder.

Here you will find the wsconfig.exe file, that is used by ColdFusion to install its connectors. Be warned right here, this is for each an every installation. So if you have another instance called cfusion2, then you would need to go into that folder and then the runtime etc.

Now I would suggest that when running that tool, remove everything and re-add these back because it just might be possible something else that is required may be configured incorrectly. That is more of a safe guard than anything else, so that we know it is setup correctly.

Now for ColdFusion Builder, I could not here you on the video the music you had playing in the background made it impossible to understand and continue watching the video. So I will again ask how you have ColdFusion installed, is it locally on your desktop with ColdFusion Builder or is installed on another machine you are trying to reach remotely?

This is important to know when setting up the server in CFB.

But first, I can’t vouch for other Operating System, but on Windows even though your account might be an Administrator, applications are run in your account. This means running CFB and trying to connect, start and stop ColdFusion will not work. The solution is to right click on the icon and select run as Administrator from the properties, this will provide an easier way to run it each time as an Administrator.

Once you have run it as an Administrator, you can then go to Add Server and start putting in the details.

The very first screen is how you would connect to the servers administrator dashboard, so if you are going to type in 127.0.0.1/cfide/administrator/ then you would put in the following details.

The name of the server is a description that will be shown in the servers list, I usually do local - ColdFusion XX as I usually have multiple instance and remote locations to get at. But whatever works for you. I usually skip the description but you can enter anything here that helps describe your server. ColdFusion 10 needs CF+TOMCAT bundle, so you need to select that.

The host name would be entered as 127.0.0.1 as that is how I reference it locally, as described above. If the IP or domain is different to the Administrator, then enter that instead. If the webserver port is 80 as it is by default on IIS, then enter 80 in the port box. Otherwise enter the port that is used in accessing the Administrator Dashboard.

The only other two things left, is to enter the username and password that you use to access the Administrator.

Now comes the next part, the server settings is going to based on the version and instance of ColdFusion you are going to connect too, this will be different if you are going to be connecting this to a remote server as it will need to be type in manually if not mapped, but the important thing to remember is that the server home goes to the instance or version of ColdFusions home folder.

By default that is C;\ColdFusion10\cfusion as cfusion is the name of the default instance, the document root should then be automatically populated and there is no need to change this, unless you are trying to connect to a remote server as you will need to type this in manually as these are the locations that ColdFusion need on the server that ColdFusion is running on.

If you have ColdFusion installed and running as a service, then leave the Use Windows Serivce selected or select it and then press finish. Provided you are running as CFB as an Administrator, you should have no issues from here.

So I found the problem. I was clicking the SSL checkbox on the first screen. All other instructions you provided I was already doing. Once I did not check the SSL checkbox, it works.
Not sure what that SSL thing is for, but apparently I am not using that feature. LOL

Self inflicted pain.

Thanks Brad for all your help and taking the time to be so detailed!

lol… SSL is for secure connections like https://127.0.0.1/

lol, yeah, I know what SSL is. But for some reason, I was not paying attention to that detail and I kept clicking that box… Bonehead move!

Yes, like you thanked Brad for my detailed response.

Hey I’m willing to take credit for anything good, but it was Andrew who wrote the long detailed reply :slight_smile:

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

Oops! Sorry… thanks Andrew!

That’s ok with me, as long as you got it all working is the main thing.