Mac Newbie

Problems with the Mac OS X version of XAMPP, questions, comments, and anything related.

Mac Newbie

Postby alfred3x » 01. April 2008 05:49

Hello all. I've got 30+ yrs experience in IT. I'm just making the switch from PC to Mac. I've got some Linux experience, but am not completely comfortable there... which is why I opted for a Mac before jumping to Linux.

I've also been using XAMPP on the PC for a couple of years.

OK, that's my background. Here are a couple of questions:

1- when you start XAMPP on the Mac, does it remain "on" from one session to the next, or do you have to restart it every time? How do you set it up to start automatically?

2- How do you put the XAMPP bin directory on the path, so you don't have to type the entire path every time you want a XAMPP app?

3- Not XAMPP related: when typing in forms and textareas, how do you navigate the cursor on the text line? I'm talking about going back to the beginning of the line, or the end of the line, or going from one word to another? I've been using the arrow keys, one character at a tiime. :(

Thanks for the help!
- AAA
alfred3x
 
Posts: 29
Joined: 10. August 2006 19:00
Location: Toronto, ON, Canada

Re: Mac Newbie

Postby jmdirc » 02. April 2008 04:09

alfred3x wrote:1- when you start XAMPP on the Mac, does it remain "on" from one session to the next, or do you have to restart it every time? How do you set it up to start automatically?


Yes. It will stay on until you recall it and stop it. If you re-boot your computer it will be shut off in the mix. As for starting automagically on boot up. I've seen the directions somewhere - sorry can't remember. for some reason I can't access the preferences from the gui menu.

alfred3x wrote:2- How do you put the XAMPP bin directory on the path, so you don't have to type the entire path every time you want a XAMPP app?


I'm not sure what your asking. I've just copied the program icon to the dock.

alfred3x wrote:3- Not XAMPP related: when typing in forms and textareas, how do you navigate the cursor on the text line? I'm talking about going back to the beginning of the line, or the end of the line, or going from one word to another? I've been using the arrow keys, one character at a tiime.


I would think that depends on your text editor. In TextWrangler and TextEdit you can double click on a word to select it; you can triple click on a line/word to select the entire line. Once selected, you can drag it anywhere you want. Alt - arrow, will send the cursor one word; control - arrow will send cursor to start or end of line; cmd - up arrow will send cursor to start of document; cmd - down arrow will send to end of document.

hoped it helped
User avatar
jmdirc
 
Posts: 154
Joined: 10. February 2008 22:44

Postby alfred3x » 02. April 2008 05:47

alfred3x wrote:

2- How do you put the XAMPP bin directory on the path, so you don't have to type the entire path every time you want a XAMPP app?


I'm not sure what your asking. I've just copied the program icon to the dock.

Here's what I used:
Code: Select all
export PATH="/Applications/xampp/xamppfiles/bin:$PATH"

In file /Users/<myhome>/.bash_profile.

My problem now is to get my virtualhost to find the right directory. This is the code I have in /Applications/xampp/xamppfiles/etc/extra/httpd-vhosts.conf:

Code: Select all
NameVirtualHost *:80

<VirtualHost *:80>
    ServerName localhost:80
    DocumentRoot "/Applications/xampp/xamppfiles/htdocs"
</VirtualHost>

<VirtualHost *:80>
  ServerName lphsgrads
  DocumentRoot "/Users/<myuser>/Sites/lphsgrads"
        <Directory "/Users/<myuser>/Sites/lphsgrads" >
                Options Indexes FollowSymLinks ExecCGI
                AllowOverride FileInfo
                Order allow,deny
                Allow from all
        </Directory>
</VirtualHost>


I also tried to remove references to the xampp directory from the etc/httpd.conf file.

Sadly, I keet getting http://lphsgrads/xampp/index.php with a 404. Any help would be much appreciated.
alfred3x
 
Posts: 29
Joined: 10. August 2006 19:00
Location: Toronto, ON, Canada

Postby jmdirc » 02. April 2008 13:51

My address for that file is:

application/xampp/etc/extra/httpd-vhosts.conf

Still, I would suspect you would have to point it to the Mac's mini-server in order to use it on the internet. In 'Applications', I believe it is purely localhost, usually for development purposes. Try pointing to this folder instead:

at: <myuser>/Library/Webserver/Documents/
User avatar
jmdirc
 
Posts: 154
Joined: 10. February 2008 22:44

Postby alfred3x » 02. April 2008 14:51

jmdirc: thanks for your help and prompt replies.

localhost is fine if you're going to be developing only a single site. I work on several, so I need virtualhosts. I had the same issues when I was setting up XAMPP on Windoze. But once Izzy helped out on the XAMPP for Windows forum, I just took the template and used it over and over again to great success.

I copied that template over to my Mac setup, but it's still serving me the default localhost/xampp/index.php, under the guise of lphsgrads/xampp/index.php. Of course, I have lphsgrads pointing to 127.0.0.1 in the /etc/hosts file.

If anyone out there has experience with virtualhosts on the Mac, I'd appreciate a helping hand.

Thanks again.
alfred3x
 
Posts: 29
Joined: 10. August 2006 19:00
Location: Toronto, ON, Canada


Return to XAMPP for Mac OS X

Who is online

Users browsing this forum: No registered users and 7 guests