Folks,

There's nothing that Lift does magically with <lift:surround/> or
<lift:embed/>  They just replace XML nodes.

If you want to structure your apps to not have surround or embed, that's
fine.  If you want to surround or embed at different points in your files,
totally cool.  Do it however you want.  It makes no difference to Lift.
Lift's templating is just an XML substitution system.  Substitute or don't
at your pleasure.  Do what works best for you.  It makes no difference to
Lift.

Thanks,

David

On Sun, May 31, 2009 at 11:31 AM, Yoryos <valo...@gmail.com> wrote:

>
> No! I didn't missed that part. Like Xavi said the benefit is a valid
> html page. It would be much more intresting having something like
>
> <html xmlns="http://www.w3.org/1999/xhtml"; xmlns:lift="http://
> liftweb.net/">
> <head><!-- I don't not if it's valid to just not even have a head tag
> when we don't want to --></head>
> <body lift:layout="default" lift:name="content">
>   <h2>Welcome to your project!</h2>
>  <p><lift:helloWorld.howdy /></p>
> </body>
> </html>
>
> witch has less boilerplate (than my first example) and is very easy
> IMHO to understand and read.
>
> I'm very new to lift and I just think that telling something that
> would look easier to me, would also look easier to any newby. At the
> other hand, being newby also means that I don't have a good overview
> of the framework and it's design. It is better thought to say
> something event if it is wrong before you get used to it, because then
> you'll just get used to it!!
>
> Yoryos
>
> On May 31, 1:53 am, "Charles F. Munat" <c...@munat.com> wrote:
> > Yoryos,
> >
> > You probably missed the part where you can add a head element inside the
> > surround tags and it will replace the default element:
> >
> > <lift:surround with="default2" at="content">
> >    <head>
> >      <title>A better title than the one in default.html</title>
> >    </head>
> >    <h2>Welcome to your project!</h2>
> >    <p><lift:helloWorld.howdy /></p>
> > </lift:surround>
> >
> > I don't see that duplicating the html and body tags unnecessarily makes
> > it any better. Just adds clutter, IMO. The fewer tags I have to deal
> > with, the easier it is to read.
> >
> > Chas.
> >
> > valotas wrote:
> > > Hi all!
> > > Just a proposal: wouldn't be better to have the views look like more
> > > an html page. I mean for the basic project created, instead of having
> > > an index.html look like
> >
> > > <lift:surround with="default2" at="content">
> > >   <h2>Welcome to your project!</h2>
> > >   <p><lift:helloWorld.howdy /></p>
> > > </lift:surround>
> >
> > > have something like:
> >
> > > <html>
> > > <lift:surround with="default2" at="content">
> > > <head>
> > >   <title>A better title than the one in default.html</title>
> > > </head>
> > > <body>
> > >   <h2>Welcome to your project!</h2>
> > >   <p><lift:helloWorld.howdy /></p>
> > > </body>
> > > </lift:surround>
> > > </html>
> >
> > > Yes we have more boilerplate code but with that way it would be much
> > > more easier the edditing of the page.
> >
> > > Yoryos
>
> >
>


-- 
Lift, the simply functional web framework http://liftweb.net
Beginning Scala http://www.apress.com/book/view/1430219890
Follow me: http://twitter.com/dpp
Git some: http://github.com/dpp

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

Reply via email to