Wednesday, November 24, 2010

Can I change /~user to /other on Mac Apache Server?

I have a Mac OS X computer. I know to access a users personal web space normally you have to type /~username but can I make it something else instead. Maybe mysite.com/bob.



I hate having to type the ~ and I might want to make it /sister or /mother instead of /momusername.



Don%26039;t just say I can can you give me a tutorial or explain how, and don%26039;t just post long blobs of run on text.



Thanks.Can I change /~user to /other on Mac Apache Server?
go into terminal



make symlinks to the user%26039;s directories in the main http docs directory.



that way YOU determine who can be accessed without the ~



cd %26lt;your docs directory%26gt;



ln -s ~sister/Sites/ sister



...Can I change /~user to /other on Mac Apache Server?
Mac Advisor hed: Be a webmaster with Mac OS X dek: OS X is the easiest platform for a personal or SOHO Web site. by Dennis Sellers



Did you know that if you can point and click, you can be a webmaster and run an Apache Web server on your Mac, especially if you%26039;re using Mac OS X?



But wait--let%26039;s back up and explain. You probably know that Mac OS X is Apple%26039;s new operating system, which puts a Mac user interface body on a Unix engine. Not only can it run classic Mac software and applications built especially for it, but it also runs some of the best open-source programs, including Apache, a Web server that, in fact, forms the basis for Mac OS X%26039;s file-sharing capabilities.



Open source is a term for the historical development model used by the Internet community to facilitate the distributed development of software. The basic idea: involve as many people as possible in writing and debugging code by publishing the source code and encouraging the formation of a large community of developers who will submit modifications and enhancements.



Apache is a powerful, flexible, HTTP/1.1-compliant Web server known for its stability. It%26039;s highly configurable, and can be extended with third-party modules. Apache is the world%26039;s most popular Web server, powering more than 60 percent of Internet domains, according to Netcraft%26039;s June 2001 Web Server Survey.



Mac OS X has a Web Sharing feature. But, you may say, the %26quot;traditional%26quot; Mac operating system has included a personal Web server in the past. And you%26039;d be right. However, X%26039;s Web Sharing is very different. It%26039;s a fully functional installation of the aforementioned Apache Web server.



When you first install Mac OS X, Web Sharing is inactive by default. And unlike Web Sharing in previous versions of the Mac operating system, you don%26039;t have to enable file sharing. Since Mac OS X is designed as a multi-user system, it presumes that file sharing is on.



In fact, multiple users can have multiple Web sites operating from the same Mac with Mac OS X. However, since Mac OS X is a multi-user system, the start-up process for this can be relatively fast or a bit slow. It all depends on how many user accounts are configured on your Mac, as well as how many files and folders are in the serving content locations. No matter how many users there are, when the Web Sharing process is finished, the Start button will change to a Stop button.



You can set up your Web site simply by adding HTML pages and images to the Sites folder in your Home folder. This means that if someone%26039;s browsing the Net and types in your computer%26039;s name, they can%26039;t run wild with access to your computer and all its files.



You can place HTML docs in your Sites folder and make them accessible by appending ~username/ to the URL of your Web server. You can use the short user name that%26039;s assigned to you. For example, if my Web server%26039;s IP address is 615.859.1.2, the URL, http://615.859.1.2/~dsellers, would cause the page, index.html, to load from the Sites folder. If your Mac%26039;s Web server is accessible through a domain name address, such as www.dsellers.com, then user sites can be accessed with a URL address such as http://www.dsellers.com/~dsellers.



You can place new pages in your Sites folder and create subfolders-e.g., %26quot;Docs,%26quot; %26quot;Images,%26quot; %26quot;Text%26quot;-within it.



Once you%26039;ve started Web Sharing, it%26039;ll keep on keepin%26039; on until you tell it otherwise or until you shut down your Mac. But when you restart your system, the process will automatically be implemented. To disable Web Sharing, open the Sharing System Preferences and click the Stop button.



Web Sharing only works when your Mac is connected to the Internet. If, like many folks, you access the Internet by modem, the downside to this is that your server will only be on the Internet when you%26039;ve dialed up and made a modem connection. If you%26039;re not connected, your server%26039;s not available. You can still Web Share, but you%26039;ll have to spread the word about when your Web site is actually available.



By the way, all Web servers have a default home page. Web Sharing uses a file named index.html, the default file name specified in the configuration files for the Apache Web server. In other words, it%26039;s the default for serving HTML documents in each directory in the Web server. This can only be overridden with the Terminal application or a product such as iTools. More on both of those in a moment.



Once you%26039;ve got your Web server up and going, you can test it by using the Mac that%26039;s working as the server, or from another machine. If your Mac has a fixed IP (Internet Protocol) address on the Internet, you can access it by typing the address in a Web browser that%26039;s Internet connected. If your computer or network has its own domain name, you can access the server by typing in its server name (the old faithful %26quot;www%26quot; moniker) and domain name (dennis-sellers, for example) together (www.dennis-sellers.com).



However, if your Web server isn%26039;t connected to the Internet, you can enter the server%26039;s private IP address from your own Mac or from another Mac on your local network. Ditto if you%26039;re connecting from behind a firewall on a private IP network. (A firewall is a computer or router configured to act as a security gateway between your LAN and the Internet.)



Either way, an Apache default document should download from the Web server to your client Mac and pop up on-screen. The default page tells you what type of server (Apache, naturally) is being used to serve up your Web documents, and provides links for more information. Eventually, you%26039;ll want to replace the default page with your own files.



What%26039;s nifty about Apple%26039;s new operating system is that it hides all of Apache%26039;s expansion modules and configuration options. All of the Web server%26039;s advanced options are still there; Apple has just chosen to cloak them under a friendly user interface.



Although Apple has hidden Apache%26039;s advanced options, power users can still access them via the included Terminal application, which offers command-line access to the Unix core that hums beneath Mac OS X%26039;s Aqua interface. If you%26039;re a Unix guru, you can go ahead and test-drive the command line to get familiar with the characteristics of the Unix shell in Mac OS X.



However, if you%26039;re not a Unix-head, prepare for some initial intimidation. You%26039;ll want to check out the Terminal to see that it%26039;s not really that difficult to use the command line for certain tasks. The best way to get started is to walk through Apple%26039;s online Terminal tutorial.



Tenon Intersystems%26039; iTools provides a Web-based graphical administration interface to Apache and a comprehensive suite of Internet server tools. The latest release, version 6, lets you configure and remotely manage Apache, DNS, and FTP, along with a range of other Mac OS X Internet services, by using a standard browser on any platform.



The centerpiece of iTools is the Administration Server, which extends Apache in two important ways. First, you get a graphical interface that manages the syntactically demanding Apache configuration file. And you can access this interface from any Web browser, which by definition gives you the ability to configure Apache remotely.



With Tenon%26039;s new Aqua graphical user interface, webmasters will also be able to manipulate Apache, DNS, and FTP directly on Apple%26039;s Aqua desktop. The new graphical user interface (GUI) will co-exist with Tenon%26039;s secure, remote browser-based administration, enabling webmasters to switch between desktop management and %26quot;anywhere, anytime%26quot; browser-based control.



Because all the needed Web server capabilities will be available using Tenon%26039;s iTools 6 on Mac OS X, webmasters will only need to consider Apple%26039;s upcoming new server product if they need additional file sharing, NetBoot, or other advanced hardware features.



And if you really need more powerful Web-serving features, you%26039;ll want to look into Mac OS X Server, Mac OS X%26039;s big brother. It%26039;s designed to combine the strengths of AppleShare IP with the power of Mac OS X, integrating services for file sharing, Internet and Web serving, networking, client management, and e-mail. Mac OS X Server, which ranges in price from $499 for a 10-user license to $999 for an %26quot;unlimited%26quot; license, comes bundled with Apache, mySQL, and PHP (also known as AMP). With PHP, you can develop and host a wide variety of sites for delivering content, conducting e-commerce, or any application that requires connecting to a database server and extracting its data.



Mac OS X is satisfactory for developers who want to download and install PHP themselves. For those who want the software pre-installed and ready to go, Mac OS X Server is the way to go. For more info, go to the Mac OS X Server Web site.



By the way, the Apache Web server is open-source software overseen by the Apache Software Foundation, which exists to ensure %26quot;that the Apache projects continue to exist beyond the participation of individual volunteers, to enable contributions of intellectual property and funds on a sound basis, and to provide a vehicle for limiting legal exposure while participating in open-source software projects.%26quot;

No comments:

Post a Comment