R
R
Robotex2011-06-27 17:21:13
Apache HTTP Server
Robotex, 2011-06-27 17:21:13

Madfish Webtoolkit: multiple sites on the same host?

I'm thinking of using this framework in the project: habrahabr.ru/blogs/cpp/61563/ (promises high speed). But I have this question: in Apache, you can create several sites on the same machine with different domains. Is it possible to do this in this framework? How?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
R
Robotex, 2011-06-27
@Robotex

And one more thing: what about mod_rewrite?

H
Horse, 2011-06-27
@Horse

You don't need any mod_rewrite. Where (void Handle(HttpRequest* request,HttpResponse* response);) in your HttpRequest, the host field indicates the name of the site to which the request is being made, and, accordingly, the URL. In other words,
if (request->Host() == "domain1.com.ua") {
response << "domain1.com.ua";
} else
{
response << "other domain1." <<request->Url();
}
But you must understand that this project has been abandoned for a long time (I know because his friend sawed) and the speed in it is not supernatural. no socket multiplexing. Try to better look towards c++ libraries for working with HTTP.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question