Using IIs as it I would use Apache - iis

I want to use IIS the way I use Apache. With that, I mean to, for example, create a simple html file, with only a "hello" message, put this file inside the IIS folder and then be able to access this html page thru eg.: localhost/mypage.html.
I can't figure it out how to make this. I've searched on Google, but nine has helped me.
My doubts are:
The IIS server is turned on, I saw this on the IIS Manager. So, what are the folder that I should place my html file and what are the default port that IIS uses so I can access my html file via localhost?

Create a new website and point to the folder where your html file resides
GO to IIS Manager->Right Click on Sites -> Add Website
Are you getting the localhost default screen
Restart Your server as whole,
See if the IIS Worker Process is running on the task manager,

Related

PhpStorm browser button custom url

Is it possible to change the url that the browser buttons in PhpStorm to go to a different url?
Currently these all take me to localhost:63342/[project name]/
I would like to direct these to a different address, [projectname].serveraddress:1111/ for example.
Currently my workaround is to use a PHP Web Page configuration but this required me to pick a browser at configuration level rather than being able to pick and choose.
I have a server config setup to automatically upload the files on change already.
Sure, just set up the Deployment entry and mark it as Default for this project.
When you are using "Open in Browser" or similar functionality, IDE looks for your default deployment entry and builds the URL based on those rules (web server URL + mappings).
If no default deployment entry is found then IDE builds URL for the built-in simple web server that uses localhost:63342/[project name]/path/file.ext URLs.
P.S. If it's a local server (files served directly from the original location) and no actual deployment is needed then use "In-place" type of config.

.htaccess Rewriting Tomcat Server

I am writing a website using Railo. My code is to be deployed on a Railo Server running on Tomcat, overlayed on a regular Apache+PHP server.
I need to send all requests to http://subdomain.myserver.co.uk/ and its child files to the directory /public_html/railo/tomcat/webapps/ROOT/subdomain/ directory.
I defined a subdomain in cPanel, with the document root as /public_html/railo/tomcat/webapps/ROOT/subdomain/, but still requests to http://subdomain.myserver.co.uk/ display files in /public_html/railo/tomcat/webapps/ROOT/. I can view my files if I request http://subdomain.myserver.co.uk/subdomain/
I've been fiddling with the .htaccess files for quite some time now, but I'm stuck
Is there any way I can do what I'm trying to achieve, or am I resigned to get those pages using http://subdomain.myserver.co.uk/subdomain/
The Railo documentation on adding a site to a Railo/Tomcat/Apache/Linux install is here:
http://wiki.getrailo.org/wiki/Installation:InstallerDocumentation:LinAddingSites
I would also personally recommend against putting your site files in ROOT/sitedir/ because the ROOT directory is already configured for localhost, and making a subdirectory into another site will cause overlapping host configs in the WEB-INF directories.
Instead, just use whatever the default is for your control panel, and update your Tomcat server.xml file to point to the directory that your control panel naturally puts sites in. This will make your Railo site and your control panel work very smoothly together.
Hope this helps!
If you want your tomcat application to serve at example.com and not at example.com/application then you need to deploy your application at /ROOT and not at /application. This will make it the "default web application" so it'll be able to serve directly from example.com.
Have a look at: http://tomcat.apache.org/tomcat-5.5-doc/config/context.html
Cherouvim's answer didn't work for me. Eventually I ended up putting my entire application in the ROOT directory

Modify the default website in IIS 6.0

I have IIS installed on a server.
It is currently on the intranet as http://mySite which has a few basic html pages that load when you go to that URL
I've made a virtual directory called MyWebApp, which sits at http://mySite/MyWebApp
How do I go about making MyWebApp the default site when you type mySite into the browser?
I don't want it to come up as mySite/MyWebApp when you visit the page either.. I just want it to always say mySite.
Wouldn't it just be simpler to build your app in your root directory? However, you can change the root directory of your IIS6 website by:
To change the home directory of a Web site using IIS Manager
In IIS Manager, expand the local computer, expand the Web Sites directory, right-click the Web site you wish to change, and click Stop.
Use Windows Explorer, to rename the LocalDrive:\Inetpub\Wwwroot directory to the name of your choice. Alternatively, you can copy the entire \Wwwroot directory tree to a new location.

Legacy ASP site issue

I'm dealing with an issue where there was a site setup, and the default.htm used an iframe which pointed to an ASP directory. It seems like the ASP directory isn't readable and not processed - is there anything special that needs to be done to the ASP directory like permissions-wise?
wwwroot/sitename
<iframe src="ASP/file.asp"></iframe>
wwwroot/sitename/ASP/file.asp exists, and several other asp files but they aren't getting referenced by the iframe.
Update: I'm getting a 404..
The page cannot be found
I think I have to create a virtual directory and name it ASP. I never use IIS though - does anyone know how this works? And would I need to restart IIS after creating the virtual directory?
Update #2: More info..
Execute permissions: Scripts Only
Application name: asp
For Authentication Methods, "Integrated Windows authentication" is checked
Local Path: Read
Update #3: I can access asp/file.htm file fine. Can anyone provide code for a simple test I could do to see if its working properly ( I have no ASP/VBScript experience )..
one of the top of the pages contains <%# LANGUAGE="VBSCRIPT"%>
Is this IIS6 by any chance? In IIS, under Web Sites there is a folder called Web Service Extensions. Make sure Active Server Pages are set to Allow and not Prohibited!
When you create a virtual directory for an ASP site in IIS, you have to make sure it is allowed to execute scripts. What version of IIS are you using? In 5.0 and 6.0, there should be a checkbox Run Scripts (such as ASP). Make sure that's checked.
Try putting a test.html file in the root directory of the site and then try to open it through wwwroot/sitename/asp/test.html - .html files won't be processed by asp.dll and so should display if the site is setup correctly even if there is some kind of asp.dll problem.
If you can't see a html file then I guess you will need to configure the website in IIS (not sure if a virtual directory is necessary from the information given) - check the 'home' tab to see if the path to the application is correct first.
If you can see the html file then I'd guess that asp is not properly installed (but that is a guess).

I cannot access files in IIS 6

I have a default IIS 6 install and I can access only .html files. If I create a html file I can see it on the browser. Any other files like ini for example are not visible (404). Any idea on what can be the issue?
Check the web service extensions are enabled (in IIS below the websites is a folder for them) for the content you are trying to share.
Check that the handler mappings is setup correctly (on the website properties)
This may help :
IIS & ASP.NET blocking file

Resources