Run with: httpd.exe -D parameter-name?

Problems with the Windows version of XAMPP, questions, comments, and anything related.

Run with: httpd.exe -D parameter-name?

Postby marijnkampf » 20. July 2011 11:50

I use Xampp for my local development, and would like to add a parameter-name to the httpd.exe call so it can be used in a IfDefine (

E.g.: httpd.exe -k runservice -D local
(the '-k runservice' is automatically added by Xampp I believe - I would like to be able to add '-D local')

Is it possible to set this up through Xampp so I don't have to manually add this to the Apache service, every time it (re-)starts?

In case there may be an alternative solution, I'm using the following .htaccess to provide different locations for the password file, whilst using a single .htaccess files for the dev and live servers.

Code: Select all
<IfDefine local>
AuthUserFile c:/localdev/location/.htpasswd
AuthName "Dev"
AuthType Basic
<IfDefine !local>
AuthUserFile /live/server/different/location/.htpasswd
AuthName "Live"
AuthType Basic

Source based on:
Posts: 1
Joined: 20. July 2011 11:20

Re: Run with: httpd.exe -D parameter-name?

Postby Terrabus » 16. February 2013 14:40

Bump. I'm also keen to find this out. On mac I got this happening by editing this file: xamppfiles/bin/apachectl

It's possible with the bat files, but they don't seem to be called by the control panel.
I thought it would make sense to edit the 'xampp-control.ini' [BinaryNames], but nope. This gets reset on running the control panel.

Would be much appreciative if anyone could solve all of my problems.
Posts: 1
Joined: 16. February 2013 14:30
Operating System: Vista

Re: Run with: httpd.exe -D parameter-name?

Postby hackattack142 » 19. February 2013 23:23


That is doable I have just not got around to adding custom parameters yet but it is on my list.
XAMPP Control Panel Developer
Latest CP: viewtopic.php?f=16&t=48932
Posts: 703
Joined: 20. May 2011 23:29
Operating System: Windows 7 Ultimate SP1 64-Bit

Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 87 guests