I am working in PHP and want to add the source code as existing project in Netbeans 8.1 on Windows 7 using Ampps.
I have setup virtual hosts and edited the hosts file to create the local site www.mysite.com. Here is the code snippet
httpd-vhosts.conf file
<VirtualHost 127.0.0.1:80>
<Directory "c:/program files/ampps/www/mysite/www">
Options FollowSymLinks Indexes
AllowOverride All
Order deny,allow
allow from All
</Directory>
ServerName www.mysite.com
ServerAlias www.mysite.com
ScriptAlias /cgi-bin/ "c:/program files/ampps/www/mysite/www/cgi-bin/"
DocumentRoot "c:/program files/ampps/www/mysite/www"
ErrorLog "C:/Program Files/Ampps/apache/logs/www.mysite.com.err"
CustomLog "C:/Program Files/Ampps/apache/logs/www.mysite.com.log" combined
</VirtualHost>
Hosts file
127.0.0.1 www.mysite.com
Now as I set up a project in Netbeans with existing sources at the Run Configuration step, the Project URL appears as http:\localhost\www. I want this to be www.mysite.com. How to do this?
Any help appreciated.
Create project from existing source
The image shows the project URL as http:\localhost\www.If it is changed then it displays Project URL is not valid as below
Creating New Project
Add Project URL and remove index file text if not required.
Already Created Project
Right click on your Project and Select Properties. Select Run Configuration in the left tab. Edit the Project URL as shown in screenshot below.