Ok Guys,

Made some headway with this and appear to have it working quite nicely
now :-) Seems I didn't have an event handler defined for my missing
template event, Dan, this might be considered a bug? I had:

<property name="missingEvent"><value>page.missing</value></property>

In my coldspring configuration, however I didn't have an event named
page.missing in my model glue XML, no exception was thrown to this
effect, it simply threw exceptions telling me that the event I was
trying to hit didn't exist, like the ones in my post above, might be
worth creating a custom exception which is thrown when the event set
as the missing event handler is itself missing :-).. Just in case
there are more developers as inept as me out there ;-)

Either way, I set that missing event handler to page.index and it now
goes to the main index event when browsing to http://localhost/ which
is what I would expect :-)

Secondly, turns out you don't need to define the 'eventValue'
parameter name in the URL, so I dont need my links to look like:

http://localhost/index.cfm/event/page.index

simply.

http://localhost/index.cfm/page.index

will suffice :-)

With those changes the site now appears to be running nicely with SES
URL's and because I'm using event.linkTo() to generate my hrefs I can
flick back and fourth between SES and normal URL's simply by removing/
adding the coldspring bean definition for the url manager. sweet!

Cheers,

Rob

On Mar 31, 1:37 pm, Sir Rawlins <[email protected]>
wrote:
> Chris,
>
> Thanks for the info, I've seen a few different solutions/action packs
> for Unity I just thought I'd try and get the built in MG:G stuff going
> as that saves any additional work. I know there are people using the
> MG:G stuff successfully so I'm sure its just something wrong with my
> configuration.
>
> As for additional information, I'm running CF8 along with IIS7 in this
> particular instance.
>
> Thanks,
>
> Rob
>
> On Mar 31, 12:52 pm, Chris Peterson <[email protected]> wrote:
>
> > I am using coldcoursehttp://coldcourse.riaforge.org/, which really works
> > great for me.  You can add new Œcourses¹ from within CF (basically new URL
> > formats or specific cases), and I am using it with a single apache rewrite
> > rule, and Model-Glue: Unity.
>
> > Chris Peterson
>
> > On 3/31/09 7:40 AM, "Dan Wilson" <[email protected]> wrote:
>
> > > I'm not the most up to date on the SES url functionality in MG:G. Others 
> > > are
> > > using it, so I'm sure they'll chime in.I would be happy to look into a 
> > > bug if
> > > you narrowed it down.
>
> > > I would also be happy to learn more about how this functionality works so
> > > please, share what you learn with us.
>
> > > DW
>
> > > On Tue, Mar 31, 2009 at 4:55 AM, Sir Rawlins
> > > <[email protected]> wrote:
>
> > >> Morning Chaps,
>
> > >> Thought I'd play around with the SES URL's this morning in MG:G and
> > >> struggling to get them working correctly. Here is an example of my XML
> > >> configuration for the app:
>
> > >>         <!-- Create the model-glue configuration object -->
> > >>         <bean id="modelglue.modelGlueConfiguration"
> > >> class="ModelGlue.gesture.configuration.ModelGlueConfiguration">
>
> > >>                 <!-- Be sure to change these to false when you go to
> > >> production! -->
> > >>                 <property name="reload"><value>true</value></property>
> > >>                 <property name="debug"><value>true</value></property>
>
> > >>                 <!-- Name of the URL variable that states which 
> > >> event-handler
> > >> to run
> > >> -->
> > >>                 <property
> > >> name="eventValue"><value>thinkblue</value></property>
> > >>                 <!-- Default event-handler -->
> > >>                 <property
> > >> name="defaultEvent"><value>page.index</value></property>
> > >>                 <!-- Execute this event when the requested event is 
> > >> missing.
> > >> Won't
> > >> work if generationEnabled=true and in development mode! -->
> > >>                 <property
> > >> name="missingEvent"><value>page.missing</value></property>
> > >>                 <!-- Execute this event when an error occurs. -->
> > >>                 <property
> > >> name="defaultExceptionHandler"><value>page.error</value></
> > >> property>
>
> > >>                 <!-- Controls reloading -->
> > >>                 <property
> > >> name="reloadPassword"><value>true</value></property>
> > >>                 <property name="reloadKey"><value>init</value></property>
>
> > >>                 <!-- Where to find necessary files -->
> > >>                 <property
> > >> name="configurationPath"><value>config/ModelGlue.xml</
> > >> value></property>
> > >>                 <property 
> > >> name="applicationPath"><value></value></property>
> > >>                 <property
> > >> name="viewMappings"><value>/views</value></property>
> > >>                 <property
> > >> name="helperMappings"><value>/helpers</value></property>
>
> > >>                 <!-- Generate unknown events when in development mode?
> > >> (reload=false) -->
> > >>                 <property
> > >> name="generationEnabled"><value>false</value></property>
> > >>         </bean>
>
> > >>         <bean id="modelglue.UrlManager"
> > >> class="ModelGlue.gesture.eventrequest.url.SesUrlManager">
> > >>                 <property name="modelGlue">
> > >>                         <ref bean="modelglue.ModelGlue" />
> > >>                 </property>
> > >>         </bean>
>
> > >> However when browsing tohttp://localhost/Iget an error which says:
>
> > >> Model-Glue: There is no known event handler for "index.cfm".
>
> > >> And likewise if I try and access one of the my events like so:
>
> > >>http://localhost/index.cfm/thinkblue/page.some_page
>
> > >> I get the error message.
>
> > >> Model-Glue: There is no known event handler for "thinkblue".
>
> > >> After reading through Doug's blog entry on this I cant see that I'm
> > >> doing anything wrong? I'd appreciate any advice on this. When I don't
> > >> define the SesUrlMamager then the application runs just as I would
> > >> expect it too.
>
> > >> Rob
--~--~---------~--~----~------------~-------~--~----~
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

For more about Model-Glue, check http://www.model-glue.com .
-~----------~----~----~----~------~----~------~--~---

Reply via email to