Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8935143
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T09:55:50+00:00 2026-06-15T09:55:50+00:00

on my localhost I develop modules for a cms. Hence I have a lot

  • 0

on my localhost I develop modules for a cms.

Hence I have a lot of urls like so:

cart.cfox.dev  
blog.cfox.dev  
orders.cfox.dev  

which map to

/var/www/cfox/modules/cart
/var/www/cfox/modules/blog
/var/www/cfox/modules/orders

Each time I setup a new module I create a new virtual host.

but they are all the same with one word changed.

What I was wondering is if there is a way to have one virtual host deal with all of these.

The other one is my hosts file is full of

127.0.0.1 cart.cfox.dev
127.0.0.1 blog.cfox.dev
127.0.0.1 orders.cfox.dev

Can we do the same thing there?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T09:55:52+00:00Added an answer on June 15, 2026 at 9:55 am

    I think the best way to handle these virtualhosts is a VirtualDocumentRoot. Specially with Apache 2.4 where, as I know, the DocumentRoot is not wrong anymore.

    UseCanonicalName Off
    VirtualDocumentRoot /var/www/cfox/modules/%1
    
    <Directory "/var/www/cfox/modules/*">
        # Apache < 2.4
        <IfModule !mod_authz_core.c>
            Allow from all
        </IfModule>
        # Apache >= 2.4
        <IfModule mod_authz_core.c>
            Require all granted
        </IfModule>
    </Directory>
    

    Can we do the same thing there?

    Unfortunately, no.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to develop an application for my localhost on which I can
I would like to develop URL's which look like the following: http://mysite.com/products/1/best-product-in-the-world Where all
I want to develop application that my database is not in the localhost, like
I have a weird problem. I develop my sites on localhost and after that
I'm using XAMPP to develop on my localhost. I would like to remove the
I develop a website with CMS WordPress. I don't have any errors on my
I'd like to start using my localhost to develop from. I am trying to
My typical workflow is that I develop on localhost, but with Google Apps Marketplace
i have two files:(localhost/template/) index.php template.php each time when i create an article(an article
I want to send a mail from localhost. I am using XAMPP to develop

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.