change the default EJS to HTM in 2.0?

4 views
Skip to first unread message

Mark

unread,
Dec 19, 2009, 1:34:06 PM12/19/09
to JavaScriptMVC
Hi there,

Is it possible with v2.0 of Jmvc to change the default EJS to HTM??

I seem to remember in v1.0 it being available but had a bug

My editor acts better towards htm files..

Thanks in advance

Justin Meyer

unread,
Dec 19, 2009, 2:29:48 PM12/19/09
to javasc...@googlegroups.com
Yes it is

Sent from my iPhone

> --
>
> You received this message because you are subscribed to the Google
> Groups "JavaScriptMVC" group.
> To post to this group, send email to javasc...@googlegroups.com.
> To unsubscribe from this group, send email to javascriptmv...@googlegroups.com
> .
> For more options, visit this group at http://groups.google.com/group/javascriptmvc?hl=en
> .
>
>

Mark

unread,
Dec 19, 2009, 4:19:46 PM12/19/09
to JavaScriptMVC
How is it done exactly, I have checked the api documentation but i
can't seem to locate it...

I presume its a change in init.js ????

thanks in advance

On Dec 19, 8:29 pm, Justin Meyer <justinbme...@gmail.com> wrote:
> Yes it is
>
> Sent from my iPhone
>

Justin Meyer

unread,
Dec 19, 2009, 5:16:25 PM12/19/09
to javasc...@googlegroups.com
Search the group. I am not by my computer.

Sent from my iPhone

Mark

unread,
Dec 20, 2009, 1:41:26 AM12/20/09
to JavaScriptMVC
Hi Justin, well i found it by mistake... i saw some old code like
MVC.View.Config and then found a jquery version passing.in cache in
view.config so i changed it to ext... and i got it working..

But i didn't find any documentation on it... maybe i was looking
wrong and searching the group for things like "change ejs extension"
etc .. found nothing..

Anyway this is what i have.. in my init file but i have a few init
files...

include(function() { //runs after prior includes are loaded
$.View.config({ ext: '.htm' });
include.models('broker', 'calendar');
include.controllers('reservation', 'date_selectors', 'calendar');
include.views();
});


so i was wondering if i can place it in my myglobalsettings.js file
which currently has this,

include = { env: 'development' };


all my pages have a reference to this...

this way i could move it out of the init and place it in my global
file.

Any ideas on this?

thanks

On Dec 19, 11:16 pm, Justin Meyer <justinbme...@gmail.com> wrote:
> Search the group. I am not by my computer.
>
> Sent from my iPhone
>

Justin Meyer

unread,
Dec 20, 2009, 12:08:25 PM12/20/09
to javasc...@googlegroups.com
You can have some other global setting like:

ViewSettings = {
  cache: true
}

And then later:


$.View.config(ViewSettings );

Justin Meyer

Jupiter Consulting
\Development\Training\Support
847-924-6039
justin...@gmail.com

Mark

unread,
Dec 20, 2009, 12:18:51 PM12/20/09
to JavaScriptMVC
ahhh Ok .. cool... i will give it a go.. thank you

On Dec 20, 6:08 pm, Justin Meyer <justinbme...@gmail.com> wrote:
> You can have some other global setting like:
>
> ViewSettings = {
>   cache: true
>
> }
>
> And then later:
>
> $.View.config(ViewSettings );
>
> Justin Meyer
>
> Jupiter Consulting
> \Development\Training\Support847-924-6039

> justinbme...@gmail.com

> > javascriptmv...@googlegroups.com<javascriptmvc%2Bunsu...@googlegroups.com>


> > > >>> .
> > > >>> For more options, visit this group athttp://groups.google.com/
> > > >>> group/javascriptmvc?hl=en
> > > >>> .
>
> > > > --
>
> > > > You received this message because you are subscribed to the Google
> > > > Groups "JavaScriptMVC" group.
> > > > To post to this group, send email to javasc...@googlegroups.com.
> > > > To unsubscribe from this group, send email to

> > javascriptmv...@googlegroups.com<javascriptmvc%2Bunsu...@googlegroups.com>


> > > > .
> > > > For more options, visit this group athttp://
> > groups.google.com/group/javascriptmvc?hl=en
> > > > .
>
> > --
>
> > You received this message because you are subscribed to the Google Groups
> > "JavaScriptMVC" group.
> > To post to this group, send email to javasc...@googlegroups.com.
> > To unsubscribe from this group, send email to

> > javascriptmv...@googlegroups.com<javascriptmvc%2Bunsu...@googlegroups.com>

Reply all
Reply to author
Forward
0 new messages