|
From: Chris W. <ch...@cw...> - 2002-03-22 15:52:38
|
[cc'd back to openinteract-help list]
On Thu, 2002-03-21 at 14:15, tr...@ab... wrote:
> ...
> But I need to ask you a question or two, if you don't mind.
>
> OI seems really to have alot..
> I need OI or something like it ( eg Zope? ) I need to get my app off the
> ground fast ... like to be able to have sessin handling, user, app dev
> logging ....
>
> trying to find a infrastructure to build an open source chemical tracking
> system.
>
> anyway... can you explain something ?
> How do you seperate the logon for site management and login for application
> usage ....
If I understand what you're saying correctly, you don't. The users for
site management and the site users are drawn from the same pool.
Generally, you assign the users you want to admin the site to the 'site
admin' group -- most admin actions are already setup so that members of
this group have appropriate permission.
> when I go to the base url .. you are logged into OI...
> I don't want that to be the default ... I want my app to be the default and
> url/admin to take me to the OI interface.
It sounds like you want to modify the boxes displayed by URL. Or do you
want the full template to change based on URL?
> How to build by own web app on top of OI? This is the part giving me
> trouble...
> I have been looking at so many tools my head is spinning ...
> Can you clear it up for me.
Generally, your app is in one or more packages. For instance, I'm
developing a contact database -- people, phone numbers, addresses, email
addresses, etc -- in the package 'contact'. In that package I have a
file (conf/action.perl) that maps top-level URLs to code, something
like:
$action = {
person => {
class => 'OpenInteract::Handler::Person',
method => 'handler',
},
};
In that package I create a module 'OpenInteract::Handler::Person' which
inherits from either 'OpenInteract::Handler::GenericDispatcher' or
'OpenInteract::CommonHandler' (more high-level stuff). These packages
look at the URL and dispatch the request to the appropriate subroutine.
So:
http://mysite/Person/show/
Generally gets sent to OpenInteract::Handler::Person->show()
From there you have access to the OI environment (user, theme, session,
security, templating) from which you generate content.
It's probably easiest to look at an example. Take a look at the
'classified' package that's shipped with OI.
Good luck!
Chris
--
Chris Winters (ch...@cw...)
Building enterprise-capable snack solutions since 1988.
|