Is there a way to test this in a dev environment using localhost???
The db portion works fine, the url is what I cannot test locally.

I have read the forums and see comeone else did this with a wiki by
using routes, but i do not fully understand.

Scenario:  user is email link of "http://mycommunity.mydomain.com.
They click on link.  The web2Py app requires login via a central
mechanism common to all communities.   It then opens a database
specific to the community.  There is only one copy of all controllers
and views, etc.

On Jul 22, 6:47 pm, mdipierro <mdipie...@cs.depaul.edu> wrote:
> Thanks
>
> you can do this. register a domain like mydomain.com and access it as
>
> http://mycommunty.mydomain.com
>
> in the model file you can do:
>
>    community = request.env.host_name.split('.')[0]
>    db=DAL('sqlite://storage.%s.sqlite' % community)
>
> and that should be all you need.
>
> On Jul 22, 1:58 pm, "david.waldrop" <david.wald...@gmail.com> wrote:
>
>
>
> > All, I just discovered this amazing framework and am immediately
> > switching to it (from adobe) for a current project I am working on.
> > It is quite different from the way I have built solutions in the
> > past.  Here is the basic structure of how I need to approach the
> > problem:
>
> > 1) I want a user to log in and create a community based topic.
>
> > 2) This community topic should have a separate URL and database.  I
> > desire this for scaleability and privacy.  I asume the url will be
> > either the community topic name (or a GUID of some type, and am OK
> > with this)  suffixed to my domain.
>
> > 3) The organizer can freely share the url with others in their
> > neighborhood.
>
> > 4) All users will be required to register and login in.
>
> > 5) Users can participate in multiple community topics.  I think this
> > means there is a central database storing community topics and
> > participating users, thereby allowing the user to see a list of
> > community topics in which they are participating when they log in.
> > When they select a community topic (ideally represented by a URL to
> > aid in easily sharing) the app must somehow switch the underlying
> > database.
>
> > I am getting the hang of implementing the functionality within a
> > community, but have no real idea how to fulfill the above
> > requirements.  Any thoughts or suggestions would be greatly
> > appreciated.  Again,WOW, I cannot believe I have been unaware of
> > web2py!!!!!

Reply via email to