I'd do this at the webserver level, using mod_rewrite or the iis equivalent
http://www.techiecorner.com/97/redirect-to-maintenance-page-during-upgrade-using-htaccess/

On 30 October 2010 00:17, Dan Wilson <[email protected]> wrote:

> This can be done in lots of ways. If you reduce the problem to a more
> simpler form, the solution is easier.
>
> Rephrased Problem:  how can I redirect a site visitor to a single
> specific event, regardless of what event they asked for.
>
>
> Here's one solution.
>
> <event-handler name="ModelGlue.onRequestStart">
>  <broadcasts>
>    <message name="CheckMaintenanceMode">
>  </broadcasts>
>  <results>
>    <result name="MaintenanceModeEvent" do="MaintenanceMode">
>  </results>
> </event-handler>
>
>
> Then, you'll need a controller to listen for this CheckMaintenanceMode
> message.
>
> Inside of the controller message for CheckMaintenanceMode, simply do
> whatever check you need to in order to determine whether you are in
> maintenance mode or not...  then for cases where you are in
> maintenance  mode, simply:
> <cfset addResult("MaintenanceModeEvent") />
>
>
> How you determine when you are in maintenance mode is completely up to
> you. Your controlller could ask a Service method that called a
> webservice, checked for the existence of a file, generated a random
> number, or verified the current moon phase from an event gateway
> request....  that part isn't Model Glue specific.
>
>
>
>
>
>
>
> On Fri, Oct 29, 2010 at 4:15 PM, Thomas Leisi <[email protected]> wrote:
> > What about renaming your modelglue index.cfm and using the
> Application.cfc onMissingTemplate function to redirect to your maintenance
> page?
> > I didn't try this with modelglue, but this way every request should be
> redirected...
> >
> >
> >
> > Am 29.10.2010 um 21:18 schrieb jet <[email protected]>:
> >
> >> Wondering what are some good ways of setting up a maintenance page.  I
> >> don't know a good way other than stopping the coldfusion service and
> >> serving up a static index page.
> >>
> >> --
> >> Model-Glue Sites:
> >> Home Page: http://www.model-glue.com
> >> Documentation: http://docs.model-glue.com
> >> Bug Tracker: http://bugs.model-glue.com
> >> Blog: http://www.model-glue.com/blog
> >>
> >> You received this message because you are subscribed to the Google
> >> Groups "model-glue" group.
> >> To post to this group, send email to [email protected]
> >> To unsubscribe from this group, send email to
> >> [email protected]<model-glue%[email protected]>
> >> For more options, visit this group at
> >> http://groups.google.com/group/model-glue?hl=en
> >
> > --
> > Model-Glue Sites:
> > Home Page: http://www.model-glue.com
> > Documentation: http://docs.model-glue.com
> > Bug Tracker: http://bugs.model-glue.com
> > Blog: http://www.model-glue.com/blog
> >
> > You received this message because you are subscribed to the Google
> > Groups "model-glue" group.
> > To post to this group, send email to [email protected]
> > To unsubscribe from this group, send email to
> > [email protected]<model-glue%[email protected]>
> > For more options, visit this group at
> > http://groups.google.com/group/model-glue?hl=en
>
>
>
> --
> William Osler - "We are here to add what we can to life, not to get
> what we can from life."
>
> --
> Model-Glue Sites:
> Home Page: http://www.model-glue.com
> Documentation: http://docs.model-glue.com
> Bug Tracker: http://bugs.model-glue.com
> Blog: http://www.model-glue.com/blog
>
> You received this message because you are subscribed to the Google
> Groups "model-glue" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]<model-glue%[email protected]>
> For more options, visit this group at
> http://groups.google.com/group/model-glue?hl=en
>

-- 
Model-Glue Sites:
Home Page: http://www.model-glue.com
Documentation: http://docs.model-glue.com
Bug Tracker: http://bugs.model-glue.com
Blog: http://www.model-glue.com/blog

You received this message because you are subscribed to the Google
Groups "model-glue" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/model-glue?hl=en

Reply via email to