1 2 Previous Next 27 Replies Latest reply: Feb 10, 2014 4:54 PM by etresoft
Loopi Level 1 Level 1 (0 points)

Hello, can anyone please tell me, what happened to the websharing button in system preferences? I had this always enabled on my MBP. The button is simply not there, and the Sites folder in my user folder is missing, too. What's wrong here? How can i show current webprojects to my customers on the road?


MacBook Pro (15-inch Late 2008), OS X Mountain Lion
  • 1. Re: Where is web sharing?
    whitewater2 Level 3 Level 3 (665 points)

    OS X Mountain Lion does not include Web Sharing as an option in the Sharing preference pane. Mountain Lion does include the Apache HTTP Server, an open-source web server. For information about enabling and using Apache, see http://httpd.apache.org.

     

    http://support.apple.com/kb/HT5230?viewlocale=en_US

     


  • 2. Re: Where is web sharing?
    Ryan M. Level 6 Level 6 (8,180 points)
  • 3. Re: Where is web sharing?
    Loopi Level 1 Level 1 (0 points)

    thanks for your response. i really have to do all this stuff instead of ticking a box?? i will not mess around with the terminal. i can't believe they removed this feature.

    no more keychain sync for my macs, no more simple websharing? what gets removed next, the mouse pointer? very disappointed.

    Apple, fix this. until then, i am back to Lion. thanks for nothing. crap.

  • 4. Re: Where is web sharing?
    etresoft Level 7 Level 7 (24,270 points)

    You have always had to do all of that to get a PHP, MySQL, etc. all running. All Apple has done is remove the web sharing checkbox. You can still start Apache with:

    sudo launchctl load -w /System/Library/LaunchDaemons/org.apache.httpd.plist

  • 5. Re: Where is web sharing?
    Loopi Level 1 Level 1 (0 points)

    sorry, this NOT true.

     

    -download and run latest MySQL installer

    -install included MySQL PrefPane and tick "run on startup"

    -go to Sharing Preferences and tick "Web Sharing"

     

    simple steps and you have a running localhost with PHP and MySQL ready.

  • 6. Re: Where is web sharing?
    etresoft Level 7 Level 7 (24,270 points)

    What is not true?

     

    Getting PHP and MySQL properly configured is more involved than that. See my User Tip for setting up a local web server on Lion: https://discussions.apple.com/docs/DOC-3083

     

    I will update that for Mountain Lion shortly.

  • 7. Re: Where is web sharing?
    webdaveb Level 1 Level 1 (0 points)

    So every time I restart I have to open terminal and manually start apache? pita. Is there a way to make apache start on system startup, like with the former sharing preference panel? I was so excited to upgrade this weekend, but now I'm holding off.

  • 8. Re: Where is web sharing?
    etresoft Level 7 Level 7 (24,270 points)

    No. Once you load it with "launchctl load -w", it will always run at startup. I have updated my User Tip above and added Mountain Lion instructions.

  • 9. Re: Where is web sharing?
    RobertJ Level 4 Level 4 (1,190 points)

    You can use a simple AppleScript to turn the Apache Server On or Off. Here is the script

     

    tell application "Finder"

     

    set Choose_app to display dialog "Start or Stop Apache" buttons {"Start", "Stop", "Cancel"} default button 3 with icon 1

     

    if button returned of Choose_app = "Start" then

     

    do shell script "sudo apachectl start" with administrator privileges

     

    else if button returned of Choose_app = "Stop" then

     

    do shell script "sudo apachectl stop" with administrator privileges

     

    end if

     

    end tell

     

    This script will ask you for your admin password to complete since you are using "sudo".

     

    The best article I've found to configure Apache on Mountain Lion is here

     

    http://coolestguyplanettech.com/downtown/install-and-configure-apache-mysql-php- and-phpmyadmin-osx-108-mountain-lion

  • 10. Re: Where is web sharing?
    Loopi Level 1 Level 1 (0 points)

    hey all, thanks again for all your efforts. it is still very annoying why apple removed this.

    now i have to learn applescripts or terminal commands instead of a simple checkbox. it is ridiculous.

    i continue to use 10.7 and all is good for me. thanks again to all responses.

  • 11. Re: Where is web sharing?
    RobertJ Level 4 Level 4 (1,190 points)

    You don't have to learn AppleScript. Just

     

    1. Open a new window with AppleScript Editor
    2. Paste the above code in
    3. Save with File Format = Application
    4. Don't check either of the two option boxes

     

    Put the scrip somewhere. It is equivalent to "Checking/Unchecking" the checkbox.

     

    As far as the rest of the Apache configuration, if you were running PHP or something else on Lion, you had to do it then or on Tiger.

     

    Mountain Lion updated the Apache Server to the latest version. The config is simple and only involves uncommenting a few lines.

  • 12. Re: Where is web sharing?
    etresoft Level 7 Level 7 (24,270 points)

    The Apache Web server is not a simple sharing feature. It takes a fair amount of technical expertise to run. Anyone who can configure Apache should be able to figure out how to start it. If you want to run it, you only have to turn it on once.

  • 13. Re: Where is web sharing?
    RobertJ Level 4 Level 4 (1,190 points)

    etresoft wrote:

     

    The Apache Web server is not a simple sharing feature. It takes a fair amount of technical expertise to run. Anyone who can configure Apache should be able to figure out how to start it. If you want to run it, you only have to turn it on once.

     

    However, if you change anything in a conf file, enable PHP for example or enable a user's Sites directory, you need to stop/start it or simply use the

     

    sudo apachectl restart

     

    command to "restart" it.

  • 14. Re: Where is web sharing?
    Joy Denton1 Level 1 Level 1 (0 points)

    I think Apple is hoping people will buy Mountain Lion Server which is $20. This provides a GUI frontend for Apple Server Services as well as Web, Mail and son on. Most folks who do much testing of web apps on their Macs have used MacPorts and other utilities to get their systems working as needed to support PHP and MySQL web apps. This is an anmoying issue but really it is not a huge problem. There is something called Webmin which can be downloaded from www.webmin.com which provides a browser-based frontend to various system administrative functions on Unix which OS X happens to be under the hood.

1 2 Previous Next