Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Content handlers
#1
I am currently developing a multi-form app using templates. In my master template, I've got the following:

<div class="vertical-menu">
  <a href="/dashboard/">Dashboard</a>
  <a href="/profile/">Profile</a>
  <a href="/leaves/">Leaves</a>
</div>

In my ServerController under the initialization section:

initialization
  TIWServerController.SetServerControllerClass;
  THandlers.Add('', '/dashboard/', TContentForm.Create(TDashboardForm));
  THandlers.Add('', '/profile/', TContentForm.Create(TProfileForm));
  THandlers.Add('', '/leaves/', TContentForm.Create(TLeavesForm));

1. Would this be a better approach compared to explicitly creating the form? 
2. When the TContentForm.Create(<formclass>) is called, does it release the previously-opened form?
3. Is the TContentForm.Create(<formclass>) instantiated in the context of the UserSession?

Hope this makes sense.
Reply


Messages In This Thread
Content handlers - by dbrain23 - 06-13-2020, 11:55 PM
RE: Content handlers - by Alexandre Machado - 06-20-2020, 03:06 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)