[Lift] Re: How does one share application logic across multiple lift applications

2009-05-11 Thread Meredith Gregory
Jono,

i don't know anything about your app, so it's hard for me to understand what
your specific trade-offs are; but... have you thought about creating a
service with an actor-based api? Your lift apps could interop with the
service.

Best wishes,

--greg

On Mon, May 11, 2009 at 6:14 PM, Jonathan Ferguson wrote:

>
> We want to encapsulate our application logic as an external
> dependencies ( library ) , so it can be used by multiple lift
> applications.
> The sticking point is how one achieves this when the library needs to
> perform data access and persistence.
>
> The library could use structured types, to decouple itself from the
> Mapper classes, but this seems like an ugly
> hack, the structured types would need to provide access to all the
> Mappers fields, persistence and search operations.
>
> Next, we could use JPA, which would remove the mapper dependency from
> the application logic, but then we lose the
> ease of use of the Mappers and some of point of using Lift.
>
> Is there a way to use lift mappers in the external dependency ?
>
> What, if any are the best practices for building an API for multiple
> lift applications to consume ?
>
> Am I thinking about this wrong and should we be approaching it
> differently ?
>
> Thank you
>
> Jono
>
> >
>


-- 
L.G. Meredith
Managing Partner
Biosimilarity LLC
1219 NW 83rd St
Seattle, WA 98117

+1 206.650.3740

http://biosimilarity.blogspot.com

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Lift and interoperability

2009-05-11 Thread Meredith Gregory
Glen,

i've done some really hare-brained integrations -- like chaining the Lift
filter with the Jersey filter -- and a bunch of other stuff. Between Lift's
architecture and Scala's brilliant interop with Java, it's definitely my
weapon of choice for integration projects.

That said, i would really be interested to know what sort of integration
you're having difficulty with -- even if it's only a gedanken experiment
that seems to be problematic. Chances are, if you're running into a problem,
we're likely to run into it, or already have. Either way, it would be
beneficial for all to find a soln.

Best wishes,

--greg

On Mon, May 11, 2009 at 3:45 PM, Timothy Perrett wrote:

>
> Could agree more with Alex - I too have done some pretty sophisticated
> integrations with 3rd party systems and at every stage I found the
> life-cycle hooks into lift very rich and completely empowering.
>
> Cheers, Tim
>
> On May 11, 11:31 pm, Alex Boisvert  wrote:
> > Hi Glenn,
> >
> > I don't understand where you're coming from either...  I've integrated
> Lift
> > with a different persistence layer (home-grown), another authentication
> > system (Tempo RBAC), integrated it with existing Java libraries and
> Spring
> > MVC components without trouble.  So far, I haven't run into a situation
> > where Lift got in the way of integration.   The fact that Lift uses all
> the
> > standard servlet APIs made it easy to simply add it to an existing app
> and
> > even reuse session state / cookies from existing apps.
> >
> > I can see how Lift can be different from what you're used to, but I don't
> > see how Lift gets in the way of integrating with legacy apps.
> >
> > My 2 cents...
> >
> > alex
> >
> >
> >
> > On Mon, May 11, 2009 at 1:06 PM, glenn  wrote:
> >
> > > Just some observations from a struggling lift user...
> >
> > > Yes, I see it's utility in delivering dynamic html to the browser. But
> > > in today's world of rapidly evolving technologies for mashups and flex-
> > > like richness and gadgetization, interoperability is the key to
> > > adoption in the enterprise. It's not enough to say you can selectively
> > > rewrite your legacy apps in lift. Lift, out of the box, is still
> > > another technology for building monolithing web apps (war files). Not
> > > the best stategy.
> >
> > > I find the keepers of the code, in response to numerous postings on
> > > this site, suffer from NIH anxiety and easily dismiss interoperability
> > > with other frameworks, either because they believe they have a
> > > superior implementation, so why use someone else's, or, if you really
> > > feel you need it, roll your own.
> >
> > > My response to that is, it just doesn't work that way. The best
> > > technologies are not just agnostic on the issue of interoperability,
> > > they embrace pluggability, and let the developer community choose the
> > > winners and losers.
> >
> > > Lift suffers from not even having an out-of the-box declarative
> > > configuration capability. And, frankly no, I don't have the time or
> > > resources to write my own. Please, give me something other than just
> > > an  tag to work with.
> >
>


-- 
L.G. Meredith
Managing Partner
Biosimilarity LLC
1219 NW 83rd St
Seattle, WA 98117

+1 206.650.3740

http://biosimilarity.blogspot.com

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: immutable bindings

2009-05-11 Thread Oliver Lambert
I've created a git branch, cloned it on my machine and built lift - built in
9 minutes with no errors (1 more tick for maven). Will "go wild" soon.

On Tue, May 12, 2009 at 9:26 AM, David Pollak  wrote:

> Oliver,
>
> Please create a git branch and "go wild" on the branch... once you're
> comfortable with it, please roll the changes into the main branch.
>
> Thanks,
>
> David
>
>
>

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Strange Comet Behavior

2009-05-11 Thread Bryan.

Yes, the alerts were there just to illustrate that I am trying to push
some JavaScript objects over the wire.  In my project code I also have
additional methods that will be called on these objects (i.e. sorting,
pagination, etc...) that make it faster for the client end if I just
use these objects instead of traversing the HTML; it also makes it
easier for me to implement and is independent of any changes made to
the markup.

If the example I provided is some one-off implementation, then let me
know and I will start looking into some comet alternatives or try to
come up with some "hack".  Is there a way to currently check if the
page is ready for the partialUpdate?  If so, then I can just add some
guard to the cases in my partial function passed to lowPriority.

Thanks,
Bryan

On May 11, 6:31 pm, David Pollak 
wrote:
> On Mon, May 11, 2009 at 3:08 PM, Bryan.  wrote:
>
> > Hi David,
>
> > Is it possible that the partialUpdate is being called before the page
> > is ready?
>
> Yes.
>
> Doing alerts in partial updates is not optimal.  I'd suggest doing all the
> drawing via HTML.  You can do a partial update in a way that it will modify
> the HTML.
>
> When a CometActor is rendered on a new page, its render method is called if
> there have been partial updates to the component since the component was
> last rendered.
>
>
>
> >  It works fine if I put Thread.sleep(1000) after the case
> > Results.
>
> > Thanks,
> > Bryan
>
> > On May 11, 5:21 pm, David Pollak 
> > wrote:
> > > Try putting the "this.start" at the end of the Actor body... I think the
> > > start method is being called prematurely.
>
> > > On Mon, May 11, 2009 at 1:14 PM, Bryan.  wrote:
>
> > > > I posted this message through the Google Groups interface and was
> > > > forced to upload tohttp://groups.google.com/group/liftweb/files?hl=en.
> > > > Sorry about the confusion.
>
> > > > --Bryan
>
> > > > On May 11, 4:01 pm, David Pollak 
> > > > wrote:
> > > > > You didn't include the code... :-(
>
> > > > > On Mon, May 11, 2009 at 12:18 PM, Bryan  wrote:
>
> > > > > > This could be a result of my strange usage of comet actors, but I'm
> > > > > > getting incosistent comet behavior.  When run in windows + jetty I
> > > > > > have no problems.  In linux + jetty, subsequent requests fail.
> >  I'll
> > > > > > explain.
>
> > > > > > I have attached comet-test.tar.gz to the files page as an example.
> > > > > > When you enter in a search term and click on submit it should popup
> > up
> > > > > > 2 JS alert messages.  This seems to work everytime upon first
> > request
> > > > > > (when you restart jetty).  On all susequent tries of the Jetty
> > > > > > instance, the comet requests fail when you click back to the home
> > page
> > > > > > and search again.  I've tried clearing my browser cache, cookies,
> > and
> > > > > > even trying on a remote windows browser with no luck.  If I add
> > > > > > Thread.sleep(1000) to the comet actor's localSetup, then everything
> > > > > > appears to work OK.
>
> > > > > > Please see the sample code and let me know if I'm doing something
> > > > > > wrong.
>
> > > > > > Thanks,
> > > > > > Bryan
>
> > > > > --
> > > > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > > > Follow me:http://twitter.com/dpp
> > > > > Git some:http://github.com/dpp
>
> > > --
> > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > Follow me:http://twitter.com/dpp
> > > Git some:http://github.com/dpp
>
> --
> Lift, the simply functional web frameworkhttp://liftweb.net
> Beginning Scalahttp://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
-~--~~~~--~~--~--~---



[Lift] How does one share application logic across multiple lift applications

2009-05-11 Thread Jonathan Ferguson

We want to encapsulate our application logic as an external
dependencies ( library ) , so it can be used by multiple lift
applications.
The sticking point is how one achieves this when the library needs to
perform data access and persistence.

The library could use structured types, to decouple itself from the
Mapper classes, but this seems like an ugly
hack, the structured types would need to provide access to all the
Mappers fields, persistence and search operations.

Next, we could use JPA, which would remove the mapper dependency from
the application logic, but then we lose the
ease of use of the Mappers and some of point of using Lift.

Is there a way to use lift mappers in the external dependency ?

What, if any are the best practices for building an API for multiple
lift applications to consume ?

Am I thinking about this wrong and should we be approaching it
differently ?

Thank you

Jono

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Unable to run unconference application from lift samples

2009-05-11 Thread David Pollak
I've updated the code.  I order for it to work, you have to blow away your
RDBMS so that Lift will automatically put content in for you.

On Thu, May 7, 2009 at 12:08 PM, glenn  wrote:

>
> Thanks for the info. While awaiting these changes, could you advise on
> the minimum data needed to get this thing running so I can have a look
> at
> it.
>
> Glenn...
>
> On May 7, 12:01 pm, David Pollak 
> wrote:
> > The unconference app needs data seeded into the database... the content
> to
> > present on the home page.  I'll look into building an auto-populated
> > database entry to avoid this issue.
> >
> >
> >
> > On Thu, May 7, 2009 at 10:23 AM, glenn  wrote:
> >
> > > I can't run the unconference application from the lift samples. I keep
> > > getting a bunch of these in the jetty console:
> >
> > > INFO - Service request (GET) / took 2 Milliseconds
> > > INFO - Service request (GET) / took 3 Milliseconds
> > > INFO - Service request (GET) / took 3 Milliseconds
> > > INFO - Service request (GET) / took 2 Milliseconds
> > > INFO - Service request (GET) / took 5 Milliseconds
> > > INFO - Service request (GET) / took 3 Milliseconds
> > > INFO - Service request (GET) / took 3 Milliseconds
> > > INFO - Service request (GET) / took 3 Milliseconds.
> >
> > > To test, I just imported the source into Eclipse as a maven project.
> > > Since I don't use postgreSQL as my database server, I changed this to
> > > the embedded derby db in Boot.scala and everything compiles fine and
> > > creates the database when I do a mvn jetty:run. But the application
> > > simply won't load when I navigate tohttp://localhost:8080
> >
> > > Glenn Silverman
> >
> > --
> > Lift, the simply functional web frameworkhttp://liftweb.net
> > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > Follow me:http://twitter.com/dpp
> > Git some:http://github.com/dpp
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Re: Confusion about Lift-Core

2009-05-11 Thread Timothy Perrett


I have some time this week - mind if I have a go? Touch base with me offline
and we'll exchange IM's... Id like to understand what exactly you don't get
in order to best explain / diagram it.

Cheers, Tim


On 12/05/2009 00:47, "David Pollak"  wrote:

> On Mon, May 11, 2009 at 4:41 PM, Charles F. Munat  wrote:
>> 
>> Yeah. I'm hoping that David comes up with something to show how he views
>> Lift. Then again, I am reminded of the scene in Being John Malkovich
>> where Malkovich follows the tunnel into his own subconscious mind. Being
>> David Pollak? This could be scary...
> 
> Run away
> 
> And I don't think I'll have time to come up with something... I'm super-behind
> in all things work right now. :-(



--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Confusion about Lift-Core

2009-05-11 Thread David Pollak
On Mon, May 11, 2009 at 4:41 PM, Charles F. Munat  wrote:

>
> Yeah. I'm hoping that David comes up with something to show how he views
> Lift. Then again, I am reminded of the scene in Being John Malkovich
> where Malkovich follows the tunnel into his own subconscious mind. Being
> David Pollak? This could be scary...


Run away

And I don't think I'll have time to come up with something... I'm
super-behind in all things work right now. :-(


>
>
> Chas.
>
> Timothy Perrett wrote:
> > Chas - now I see your confusion. One can only imagine by "lift core"
> > the author of that image means net.liftweb.http...
> >
> > Cheers, Tim
> >
> > On May 11, 7:28 pm, "Charles F. Munat"  wrote:
> >> How would you draw the diagram? Don't be so sure that your learning
> >> style isn't mirrored by others...
> >>
> >> Chas.
> >>
> >>
> >>
> >> David Pollak wrote:
> >>> In this case, I don't think lift-core means the same as the lift-core
> >>> package.
> >>> I'm also not a fan of layer diagrams in general... I think that they
> >>> fail to show the interconnected nature of things... but that's just my
> >>> learning style.
> >>> On Sun, May 10, 2009 at 11:03 AM, Charles F. Munat  >>> > wrote:
> >>> No complaints here. I'm just confused by the diagram in the Lift
> book.
> >>> I'm very literal about these things, and this diagram doesn't make
> much
> >>> sense to me. (Probably, the problem is in my addled brain, not the
> >>> diagram.) I'm trying to figure out if it can be improved and, if
> so,
> >>> how.
> >>> Chas.
> >>> David Pollak wrote:
> >>>  > A long time ago, I insisted that Lift was everything that we had
> >>> in all
> >>>  > the Lift packages.  When DavidB split Lift into different
> >>> packages, he
> >>>  > called the "whole thing that includes all Lift packages" Lift
> >>> Core.  It
> >>>  > would probably be better named "Lift Bloat" (this is a joke),
> but
> >>> it is
> >>>  > what it is.
> >>>  > On Sat, May 9, 2009 at 11:49 PM, Charles F. Munat <
> c...@munat.com
> >>> 
> >>>  > >> wrote:
> >>>  > What exactly is Lift-Core. When I read Chapter 7 of the Lift
> >>> book, it
> >>>  > says that Lift-Core is
> >>>  > "The engine of the framework responsible for the
> request/response
> >>>  > lifecycle, the rendering pipeline, invoking the user's
> >>> functions, etc.
> >>>  > We don't directly cover the core in this book because
> >>> essentially all of
> >>>  > the functionality that we do cover sits on top of the core."
> >>>  > But when I look in the source code under lift-core, there's
> >>> nothing
> >>>  > there except a pom.xml file that appears to pull a bunch of
> >>>  > dependencies, namely, lift-util, lift-webkit, lift-mapper,
> >>> lift-machine,
> >>>  > lift-record, lift-textile, lift-facebook, lift-amqp,
> >>> lift-xmpp, and
> >>>  > lift-widgets.
> >>>  > So does "lift-core" comprise these widgets? Or is the
> lift-core
> >>>  > something else? (The diagram in the book shows the Mapper,
> >>> for example,
> >>>  > as being separate from the Core.)
> >>>  > Thanks for any help.
> >>>  > Chas.
> >>>  > --
> >>>  > Lift, the simply functional web frameworkhttp://liftweb.net
> >>>  > Beginning Scalahttp://www.apress.com/book/view/1430219890
> >>>  > Follow me:http://twitter.com/dpp
> >>>  > Git some:http://github.com/dpp
> >>> --
> >>> Lift, the simply functional web frameworkhttp://liftweb.net
> >>> Beginning Scalahttp://www.apress.com/book/view/1430219890
> >>> Follow me:http://twitter.com/dpp
> >>> Git some:http://github.com/dpp
> > >
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Re: Confusion about Lift-Core

2009-05-11 Thread Charles F. Munat

Yeah. I'm hoping that David comes up with something to show how he views 
Lift. Then again, I am reminded of the scene in Being John Malkovich 
where Malkovich follows the tunnel into his own subconscious mind. Being 
David Pollak? This could be scary...

Chas.

Timothy Perrett wrote:
> Chas - now I see your confusion. One can only imagine by "lift core"
> the author of that image means net.liftweb.http...
> 
> Cheers, Tim
> 
> On May 11, 7:28 pm, "Charles F. Munat"  wrote:
>> How would you draw the diagram? Don't be so sure that your learning
>> style isn't mirrored by others...
>>
>> Chas.
>>
>>
>>
>> David Pollak wrote:
>>> In this case, I don't think lift-core means the same as the lift-core
>>> package.
>>> I'm also not a fan of layer diagrams in general... I think that they
>>> fail to show the interconnected nature of things... but that's just my
>>> learning style.
>>> On Sun, May 10, 2009 at 11:03 AM, Charles F. Munat >> > wrote:
>>> No complaints here. I'm just confused by the diagram in the Lift book.
>>> I'm very literal about these things, and this diagram doesn't make much
>>> sense to me. (Probably, the problem is in my addled brain, not the
>>> diagram.) I'm trying to figure out if it can be improved and, if so,
>>> how.
>>> Chas.
>>> David Pollak wrote:
>>>  > A long time ago, I insisted that Lift was everything that we had
>>> in all
>>>  > the Lift packages.  When DavidB split Lift into different
>>> packages, he
>>>  > called the "whole thing that includes all Lift packages" Lift
>>> Core.  It
>>>  > would probably be better named "Lift Bloat" (this is a joke), but
>>> it is
>>>  > what it is.
>>>  > On Sat, May 9, 2009 at 11:49 PM, Charles F. Munat >> 
>>>  > >> wrote:
>>>  > What exactly is Lift-Core. When I read Chapter 7 of the Lift
>>> book, it
>>>  > says that Lift-Core is
>>>  > "The engine of the framework responsible for the request/response
>>>  > lifecycle, the rendering pipeline, invoking the user's
>>> functions, etc.
>>>  > We don't directly cover the core in this book because
>>> essentially all of
>>>  > the functionality that we do cover sits on top of the core."
>>>  > But when I look in the source code under lift-core, there's
>>> nothing
>>>  > there except a pom.xml file that appears to pull a bunch of
>>>  > dependencies, namely, lift-util, lift-webkit, lift-mapper,
>>> lift-machine,
>>>  > lift-record, lift-textile, lift-facebook, lift-amqp,
>>> lift-xmpp, and
>>>  > lift-widgets.
>>>  > So does "lift-core" comprise these widgets? Or is the lift-core
>>>  > something else? (The diagram in the book shows the Mapper,
>>> for example,
>>>  > as being separate from the Core.)
>>>  > Thanks for any help.
>>>  > Chas.
>>>  > --
>>>  > Lift, the simply functional web frameworkhttp://liftweb.net
>>>  > Beginning Scalahttp://www.apress.com/book/view/1430219890
>>>  > Follow me:http://twitter.com/dpp
>>>  > Git some:http://github.com/dpp
>>> --
>>> Lift, the simply functional web frameworkhttp://liftweb.net
>>> Beginning Scalahttp://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
-~--~~~~--~~--~--~---



[Lift] Re: immutable bindings

2009-05-11 Thread David Pollak
Oliver,

Please create a git branch and "go wild" on the branch... once you're
comfortable with it, please roll the changes into the main branch.

Thanks,

David

On Thu, May 7, 2009 at 6:06 PM, Oliver Lambert  wrote:

> I've attached a new version of the code. The two major changes are the
> Binder and FormReturn code.
> Things that are of note
>
> 1) xhtml has been slightly modified (see David's comments below and my
> reply). The advantage is pragmatic - it looks shorter and cleaner to me.
>
> 2) Bind has been slightly modified (see SBind). Mixins are the default,
> which I reckon helps separate the view from the controllers.
>
> 3) SBind supports Binder objects. Binder objects hide Lifts binding a
> little, but have some advantages. Once an instance is created it is
> immutable. Binder objects come with some default conversions and
> validations, that just always make sense. I'm not trying to compete with
> mapper objects, which can still be used, just offer an alternative way of
> dealing with the front end layer. SBind, is meant to extend Bind, all its
> functionality still "should" be available.
>
> 4) FormReturn - just me trying to be a little more functional in my
> approach.
>
> On Fri, May 8, 2009 at 5:49 AM, David Pollak <
> feeder.of.the.be...@gmail.com> wrote:
>
>> I like this a lot.
>>
>> I think this has a place in Lift... although I still prefer to bind to
>>  to  But that's a
>> small thing.
>>
>
> I'll be willing to do this, but I'm going to resist a little. The reason I
> chose  is it's a completely valid input tag,
> and the name attribute is going to get replaced by lifts binding process -
> you can't be tempted to put in your own value and then be confused when it
> gets blown away.
>
>
>>
>> I'd like to see this rolled into the Record stuff so that input records
>> could be defined this way.
>>
>
> Me too.
>
>
>>
>>
>> On Wed, Apr 29, 2009 at 9:02 PM, Oliver Lambert wrote:
>>
>>> Hi all,
>>> A couple of weeks ago, I promised David I would provide an example of the
>>> immutable binding, I am using.
>>>
>>> I've, included it as a small Lift web application, that hopefully works
>>> without any dependencies on my local repository.
>>>
>>> I've tried to make it as self explanatory as possible.  If your
>>> interested, run the application to get an idea of how it works.
>>> Your suggestions/opinions are welcome.
>>>
>>> cheers
>>> Oliver
>>>
>>>
>>>
>>
>>
>> --
>> 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
>>
>>
>>
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Re: multi-column MappedField

2009-05-11 Thread David Pollak
Please look at the MappedPassword class for an example of a multi-column
field.

After writing that class and living with the repercussions, I'm not sure it
was the best idea in the world... :-)

Can you serialize the array and put it in a blob?



On Mon, May 11, 2009 at 3:53 PM, mgm  wrote:

>
> I have a legacy table that has a group of 108 columns that are really
> an int[6][6][3] (apologies for for the Java!).
>
> I've started writing a MappedField[Array[Int], O] subclass to
> represent this, but I'm wondering if the framework really supports a
> multi-coulmn mapped field?
>
> What should the targetSQLType be, for example?
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] multi-column MappedField

2009-05-11 Thread mgm

I have a legacy table that has a group of 108 columns that are really
an int[6][6][3] (apologies for for the Java!).

I've started writing a MappedField[Array[Int], O] subclass to
represent this, but I'm wondering if the framework really supports a
multi-coulmn mapped field?

What should the targetSQLType be, for example?

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Confusion about Lift-Core

2009-05-11 Thread Timothy Perrett

Chas - now I see your confusion. One can only imagine by "lift core"
the author of that image means net.liftweb.http...

Cheers, Tim

On May 11, 7:28 pm, "Charles F. Munat"  wrote:
> How would you draw the diagram? Don't be so sure that your learning
> style isn't mirrored by others...
>
> Chas.
>
>
>
> David Pollak wrote:
> > In this case, I don't think lift-core means the same as the lift-core
> > package.
>
> > I'm also not a fan of layer diagrams in general... I think that they
> > fail to show the interconnected nature of things... but that's just my
> > learning style.
>
> > On Sun, May 10, 2009 at 11:03 AM, Charles F. Munat  > > wrote:
>
> >     No complaints here. I'm just confused by the diagram in the Lift book.
> >     I'm very literal about these things, and this diagram doesn't make much
> >     sense to me. (Probably, the problem is in my addled brain, not the
> >     diagram.) I'm trying to figure out if it can be improved and, if so,
> >     how.
>
> >     Chas.
>
> >     David Pollak wrote:
> >      > A long time ago, I insisted that Lift was everything that we had
> >     in all
> >      > the Lift packages.  When DavidB split Lift into different
> >     packages, he
> >      > called the "whole thing that includes all Lift packages" Lift
> >     Core.  It
> >      > would probably be better named "Lift Bloat" (this is a joke), but
> >     it is
> >      > what it is.
>
> >      > On Sat, May 9, 2009 at 11:49 PM, Charles F. Munat  >     
> >      > >> wrote:
>
> >      >     What exactly is Lift-Core. When I read Chapter 7 of the Lift
> >     book, it
> >      >     says that Lift-Core is
>
> >      >     "The engine of the framework responsible for the request/response
> >      >     lifecycle, the rendering pipeline, invoking the user's
> >     functions, etc.
> >      >     We don't directly cover the core in this book because
> >     essentially all of
> >      >     the functionality that we do cover sits on top of the core."
>
> >      >     But when I look in the source code under lift-core, there's
> >     nothing
> >      >     there except a pom.xml file that appears to pull a bunch of
> >      >     dependencies, namely, lift-util, lift-webkit, lift-mapper,
> >     lift-machine,
> >      >     lift-record, lift-textile, lift-facebook, lift-amqp,
> >     lift-xmpp, and
> >      >     lift-widgets.
>
> >      >     So does "lift-core" comprise these widgets? Or is the lift-core
> >      >     something else? (The diagram in the book shows the Mapper,
> >     for example,
> >      >     as being separate from the Core.)
>
> >      >     Thanks for any help.
>
> >      >     Chas.
>
> >      > --
> >      > Lift, the simply functional web frameworkhttp://liftweb.net
> >      > Beginning Scalahttp://www.apress.com/book/view/1430219890
> >      > Follow me:http://twitter.com/dpp
> >      > Git some:http://github.com/dpp
>
> > --
> > Lift, the simply functional web frameworkhttp://liftweb.net
> > Beginning Scalahttp://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
-~--~~~~--~~--~--~---



[Lift] Re: Lift and interoperability

2009-05-11 Thread Timothy Perrett

Could agree more with Alex - I too have done some pretty sophisticated
integrations with 3rd party systems and at every stage I found the
life-cycle hooks into lift very rich and completely empowering.

Cheers, Tim

On May 11, 11:31 pm, Alex Boisvert  wrote:
> Hi Glenn,
>
> I don't understand where you're coming from either...  I've integrated Lift
> with a different persistence layer (home-grown), another authentication
> system (Tempo RBAC), integrated it with existing Java libraries and Spring
> MVC components without trouble.  So far, I haven't run into a situation
> where Lift got in the way of integration.   The fact that Lift uses all the
> standard servlet APIs made it easy to simply add it to an existing app and
> even reuse session state / cookies from existing apps.
>
> I can see how Lift can be different from what you're used to, but I don't
> see how Lift gets in the way of integrating with legacy apps.
>
> My 2 cents...
>
> alex
>
>
>
> On Mon, May 11, 2009 at 1:06 PM, glenn  wrote:
>
> > Just some observations from a struggling lift user...
>
> > Yes, I see it's utility in delivering dynamic html to the browser. But
> > in today's world of rapidly evolving technologies for mashups and flex-
> > like richness and gadgetization, interoperability is the key to
> > adoption in the enterprise. It's not enough to say you can selectively
> > rewrite your legacy apps in lift. Lift, out of the box, is still
> > another technology for building monolithing web apps (war files). Not
> > the best stategy.
>
> > I find the keepers of the code, in response to numerous postings on
> > this site, suffer from NIH anxiety and easily dismiss interoperability
> > with other frameworks, either because they believe they have a
> > superior implementation, so why use someone else's, or, if you really
> > feel you need it, roll your own.
>
> > My response to that is, it just doesn't work that way. The best
> > technologies are not just agnostic on the issue of interoperability,
> > they embrace pluggability, and let the developer community choose the
> > winners and losers.
>
> > Lift suffers from not even having an out-of the-box declarative
> > configuration capability. And, frankly no, I don't have the time or
> > resources to write my own. Please, give me something other than just
> > an  tag to work with.
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Strange Comet Behavior

2009-05-11 Thread David Pollak
On Mon, May 11, 2009 at 3:08 PM, Bryan.  wrote:

>
> Hi David,
>
> Is it possible that the partialUpdate is being called before the page
> is ready?


Yes.

Doing alerts in partial updates is not optimal.  I'd suggest doing all the
drawing via HTML.  You can do a partial update in a way that it will modify
the HTML.

When a CometActor is rendered on a new page, its render method is called if
there have been partial updates to the component since the component was
last rendered.


>  It works fine if I put Thread.sleep(1000) after the case
> Results.
>
> Thanks,
> Bryan
>
> On May 11, 5:21 pm, David Pollak 
> wrote:
> > Try putting the "this.start" at the end of the Actor body... I think the
> > start method is being called prematurely.
> >
> >
> >
> > On Mon, May 11, 2009 at 1:14 PM, Bryan.  wrote:
> >
> > > I posted this message through the Google Groups interface and was
> > > forced to upload tohttp://groups.google.com/group/liftweb/files?hl=en.
> > > Sorry about the confusion.
> >
> > > --Bryan
> >
> > > On May 11, 4:01 pm, David Pollak 
> > > wrote:
> > > > You didn't include the code... :-(
> >
> > > > On Mon, May 11, 2009 at 12:18 PM, Bryan  wrote:
> >
> > > > > This could be a result of my strange usage of comet actors, but I'm
> > > > > getting incosistent comet behavior.  When run in windows + jetty I
> > > > > have no problems.  In linux + jetty, subsequent requests fail.
>  I'll
> > > > > explain.
> >
> > > > > I have attached comet-test.tar.gz to the files page as an example.
> > > > > When you enter in a search term and click on submit it should popup
> up
> > > > > 2 JS alert messages.  This seems to work everytime upon first
> request
> > > > > (when you restart jetty).  On all susequent tries of the Jetty
> > > > > instance, the comet requests fail when you click back to the home
> page
> > > > > and search again.  I've tried clearing my browser cache, cookies,
> and
> > > > > even trying on a remote windows browser with no luck.  If I add
> > > > > Thread.sleep(1000) to the comet actor's localSetup, then everything
> > > > > appears to work OK.
> >
> > > > > Please see the sample code and let me know if I'm doing something
> > > > > wrong.
> >
> > > > > Thanks,
> > > > > Bryan
> >
> > > > --
> > > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > > Follow me:http://twitter.com/dpp
> > > > Git some:http://github.com/dpp
> >
> > --
> > Lift, the simply functional web frameworkhttp://liftweb.net
> > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > Follow me:http://twitter.com/dpp
> > Git some:http://github.com/dpp
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Re: Lift and interoperability

2009-05-11 Thread Alex Boisvert
Hi Glenn,

I don't understand where you're coming from either...  I've integrated Lift
with a different persistence layer (home-grown), another authentication
system (Tempo RBAC), integrated it with existing Java libraries and Spring
MVC components without trouble.  So far, I haven't run into a situation
where Lift got in the way of integration.   The fact that Lift uses all the
standard servlet APIs made it easy to simply add it to an existing app and
even reuse session state / cookies from existing apps.

I can see how Lift can be different from what you're used to, but I don't
see how Lift gets in the way of integrating with legacy apps.

My 2 cents...

alex

On Mon, May 11, 2009 at 1:06 PM, glenn  wrote:

>
> Just some observations from a struggling lift user...
>
> Yes, I see it's utility in delivering dynamic html to the browser. But
> in today's world of rapidly evolving technologies for mashups and flex-
> like richness and gadgetization, interoperability is the key to
> adoption in the enterprise. It's not enough to say you can selectively
> rewrite your legacy apps in lift. Lift, out of the box, is still
> another technology for building monolithing web apps (war files). Not
> the best stategy.
>
> I find the keepers of the code, in response to numerous postings on
> this site, suffer from NIH anxiety and easily dismiss interoperability
> with other frameworks, either because they believe they have a
> superior implementation, so why use someone else's, or, if you really
> feel you need it, roll your own.
>
> My response to that is, it just doesn't work that way. The best
> technologies are not just agnostic on the issue of interoperability,
> they embrace pluggability, and let the developer community choose the
> winners and losers.
>
> Lift suffers from not even having an out-of the-box declarative
> configuration capability. And, frankly no, I don't have the time or
> resources to write my own. Please, give me something other than just
> an  tag to work with.
>
>
> >
>

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Strange Comet Behavior

2009-05-11 Thread Bryan.

Hi David,

Is it possible that the partialUpdate is being called before the page
is ready?  It works fine if I put Thread.sleep(1000) after the case
Results.

Thanks,
Bryan

On May 11, 5:21 pm, David Pollak 
wrote:
> Try putting the "this.start" at the end of the Actor body... I think the
> start method is being called prematurely.
>
>
>
> On Mon, May 11, 2009 at 1:14 PM, Bryan.  wrote:
>
> > I posted this message through the Google Groups interface and was
> > forced to upload tohttp://groups.google.com/group/liftweb/files?hl=en.
> > Sorry about the confusion.
>
> > --Bryan
>
> > On May 11, 4:01 pm, David Pollak 
> > wrote:
> > > You didn't include the code... :-(
>
> > > On Mon, May 11, 2009 at 12:18 PM, Bryan  wrote:
>
> > > > This could be a result of my strange usage of comet actors, but I'm
> > > > getting incosistent comet behavior.  When run in windows + jetty I
> > > > have no problems.  In linux + jetty, subsequent requests fail.  I'll
> > > > explain.
>
> > > > I have attached comet-test.tar.gz to the files page as an example.
> > > > When you enter in a search term and click on submit it should popup up
> > > > 2 JS alert messages.  This seems to work everytime upon first request
> > > > (when you restart jetty).  On all susequent tries of the Jetty
> > > > instance, the comet requests fail when you click back to the home page
> > > > and search again.  I've tried clearing my browser cache, cookies, and
> > > > even trying on a remote windows browser with no luck.  If I add
> > > > Thread.sleep(1000) to the comet actor's localSetup, then everything
> > > > appears to work OK.
>
> > > > Please see the sample code and let me know if I'm doing something
> > > > wrong.
>
> > > > Thanks,
> > > > Bryan
>
> > > --
> > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > Follow me:http://twitter.com/dpp
> > > Git some:http://github.com/dpp
>
> --
> Lift, the simply functional web frameworkhttp://liftweb.net
> Beginning Scalahttp://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
-~--~~~~--~~--~--~---



[Lift] Re: Lift and interoperability

2009-05-11 Thread Erik Engbrecht
Glenn,
  Just out of curiosity, what's your frame of reference, e.g. the
technologies that you are accustomed to that are so much more
"interoperable"?  Based on some recent experience teaching Django to
ASP.NETdevelopers, it seems to me your experience may be leading you
to look for
things that just don't explicitly exist in a more loosely coupled framework
using more fluid abstractions.

-Erik

On Mon, May 11, 2009 at 4:06 PM, glenn  wrote:

>
> Just some observations from a struggling lift user...
>
> Yes, I see it's utility in delivering dynamic html to the browser. But
> in today's world of rapidly evolving technologies for mashups and flex-
> like richness and gadgetization, interoperability is the key to
> adoption in the enterprise. It's not enough to say you can selectively
> rewrite your legacy apps in lift. Lift, out of the box, is still
> another technology for building monolithing web apps (war files). Not
> the best stategy.
>
> I find the keepers of the code, in response to numerous postings on
> this site, suffer from NIH anxiety and easily dismiss interoperability
> with other frameworks, either because they believe they have a
> superior implementation, so why use someone else's, or, if you really
> feel you need it, roll your own.
>
> My response to that is, it just doesn't work that way. The best
> technologies are not just agnostic on the issue of interoperability,
> they embrace pluggability, and let the developer community choose the
> winners and losers.
>
> Lift suffers from not even having an out-of the-box declarative
> configuration capability. And, frankly no, I don't have the time or
> resources to write my own. Please, give me something other than just
> an  tag to work with.
>
>
> >
>


-- 
http://erikengbrecht.blogspot.com/

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Strange Comet Behavior

2009-05-11 Thread David Pollak
Try putting the "this.start" at the end of the Actor body... I think the
start method is being called prematurely.


On Mon, May 11, 2009 at 1:14 PM, Bryan.  wrote:

>
> I posted this message through the Google Groups interface and was
> forced to upload to http://groups.google.com/group/liftweb/files?hl=en.
> Sorry about the confusion.
>
> --Bryan
>
> On May 11, 4:01 pm, David Pollak 
> wrote:
> > You didn't include the code... :-(
> >
> >
> >
> > On Mon, May 11, 2009 at 12:18 PM, Bryan  wrote:
> >
> > > This could be a result of my strange usage of comet actors, but I'm
> > > getting incosistent comet behavior.  When run in windows + jetty I
> > > have no problems.  In linux + jetty, subsequent requests fail.  I'll
> > > explain.
> >
> > > I have attached comet-test.tar.gz to the files page as an example.
> > > When you enter in a search term and click on submit it should popup up
> > > 2 JS alert messages.  This seems to work everytime upon first request
> > > (when you restart jetty).  On all susequent tries of the Jetty
> > > instance, the comet requests fail when you click back to the home page
> > > and search again.  I've tried clearing my browser cache, cookies, and
> > > even trying on a remote windows browser with no luck.  If I add
> > > Thread.sleep(1000) to the comet actor's localSetup, then everything
> > > appears to work OK.
> >
> > > Please see the sample code and let me know if I'm doing something
> > > wrong.
> >
> > > Thanks,
> > > Bryan
> >
> > --
> > Lift, the simply functional web frameworkhttp://liftweb.net
> > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > Follow me:http://twitter.com/dpp
> > Git some:http://github.com/dpp
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Re: Lift picking up momentum

2009-05-11 Thread KWright

Oh man, sure we've all been there! My condolences...
Did you think to post it on DailyWTF?

On May 7, 8:17 am, Viktor Klang  wrote:
> On Thu, May 7, 2009 at 12:23 AM, David Pollak 
> > wrote:
> > Very cool.  Made my morning which was ruined by debugging JavaScript
> > written by people who should find a new line of work.
>
> My sympathies. :/
>
>
>
>
>
>
>
> > On Wed, May 6, 2009 at 8:17 AM, Timothy Perrett 
> > wrote:
>
> >> This really is very good - I'd be interested to see how the group
> >> membership grows when that article drops!
>
> >> Cheers, Tim
>
> >> Sent from my iPhone
>
> >> On 6 May 2009, at 14:12, TylerWeir  wrote:
>
> >> > Just an FYI:http://www.scala-lang.org/node/1702
>
> >> > "Lift a Web Framework, is receiving more attention, growing a
> >> > commercial user base and gaining momentum. In the May/June 2009
> >> > Edition of the IEEE Internet Computing journal Steve Vinoski publishes
> >> > an article "Scala and Lift - Functional Recipes for the Web" in his
> >> > column "The Functional Web""
>
> > --
> > Lift, the simply functional web frameworkhttp://liftweb.net
> > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > Follow me:http://twitter.com/dpp
> > Git some:http://github.com/dpp
>
> --
> Viktor Klang
> Senior Systems Analyst

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Lift and interoperability

2009-05-11 Thread David Pollak
On Mon, May 11, 2009 at 1:06 PM, glenn  wrote:

>
> Just some observations from a struggling lift user...
>
> Yes, I see it's utility in delivering dynamic html to the browser. But
> in today's world of rapidly evolving technologies for mashups and flex-
> like richness and gadgetization, interoperability is the key to
> adoption in the enterprise. It's not enough to say you can selectively
> rewrite your legacy apps in lift. Lift, out of the box, is still
> another technology for building monolithing web apps (war files). Not
> the best stategy.
>

In terms of Lift being the sole resident of a WAR file, that's not the
case.  Lift is implemented as a Servlet Filter and can be co-resident in a
WAR file with other J(2)EE technology.  There is nothing inherent in Lift
that prevents this.  Please learn more about the technology before ranting
against it.


>
>
> I find the keepers of the code, in response to numerous postings on
> this site, suffer from NIH anxiety and easily dismiss interoperability
> with other frameworks, either because they believe they have a
> superior implementation, so why use someone else's, or, if you really
> feel you need it, roll your own.


Please be specific.  You suggested integrating with Sling.  Please tell me
what Sling offers that Lift does not?  Are you willing to do the work?

We've got a punch-list for our 1.1 release.  We've got so many resources and
we've pretty much got our work cut out for us.  In general, our development
is driven by a combination of our individual needs in our day jobs and
common requests on this list.  We've integrated Lift with a lot of things
over the years: PayPal, OpenID, Facebook, YUI, jQuery, JPA, etc.  We're
currently working on integrating Lift is the JTA, OSGi, etc.

But part of managing a successful project is knowing when to say "No."  If
we implemented every idea that everybody who's been part of the Lift
community for a month suggested (putting aside the resource constraints),
we'd have a disgusting Frankenmonster of a heap of junk.  Instead, Lift is
reasonably conherent and fairly lightweight given the breadth of
functionality that it offers.  I'm not the only person that thinks so... the
IEEE journal is saying pretty nice things about Lift as well... see
http://steve.vinoski.net/pdf/IC-Scala_and_Lift.pdf

So, if there's a superior implementation of something out there, please let
us know along with a compelling argument that the technology is superior.
But please understand that compelling includes a deep discussion of what
Lift currently offers.


>
>
> My response to that is, it just doesn't work that way. The best
> technologies are not just agnostic on the issue of interoperability,
> they embrace pluggability, and let the developer community choose the
> winners and losers.


Please let me know where Lift is not "pluggable".  Please be concrete.
We've worked hard to put intercept points at just about every layer of the
Lift response and rendering pipeline so that people can interoperate with
other systems.  If we're missing something, please let us know what you want
to interoperate with, how, and why.


>
>
> Lift suffers from not even having an out-of the-box declarative
> configuration capability.


This is just wrong.  Most Lift configuration is based on Scala's
PartialFunctions which gives you declarative syntax without the constraints
or syntactic ugliness of XML or attributes.  Learn it before you complain.


> And, frankly no, I don't have the time or
> resources to write my own. Please, give me something other than just
> an  tag to work with.


Reading this, I'm not really sure that the Lift as a technology or the Lift
community is the right place for you.  Lift as a framework is different.
This is intentional and based on my 13 years of writing web frameworks.  The
Lift community offers a lot of hand-holding and a welcoming environment to
newbies to help them come up to speed with Lift.  We've been improving
documentation.  We in fact do interoperate with a lot of technologies, both
on the J2EE stack and across the Internet.  We do ask that before people
complain about what they've done, they have some grounding in Lift
technology and the way Lift does things.

David


>
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Lift and interoperability

2009-05-11 Thread glenn

Just some observations from a struggling lift user...

Yes, I see it's utility in delivering dynamic html to the browser. But
in today's world of rapidly evolving technologies for mashups and flex-
like richness and gadgetization, interoperability is the key to
adoption in the enterprise. It's not enough to say you can selectively
rewrite your legacy apps in lift. Lift, out of the box, is still
another technology for building monolithing web apps (war files). Not
the best stategy.

I find the keepers of the code, in response to numerous postings on
this site, suffer from NIH anxiety and easily dismiss interoperability
with other frameworks, either because they believe they have a
superior implementation, so why use someone else's, or, if you really
feel you need it, roll your own.

My response to that is, it just doesn't work that way. The best
technologies are not just agnostic on the issue of interoperability,
they embrace pluggability, and let the developer community choose the
winners and losers.

Lift suffers from not even having an out-of the-box declarative
configuration capability. And, frankly no, I don't have the time or
resources to write my own. Please, give me something other than just
an  tag to work with.


--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Strange Comet Behavior

2009-05-11 Thread Bryan.

I posted this message through the Google Groups interface and was
forced to upload to http://groups.google.com/group/liftweb/files?hl=en.
Sorry about the confusion.

--Bryan

On May 11, 4:01 pm, David Pollak 
wrote:
> You didn't include the code... :-(
>
>
>
> On Mon, May 11, 2009 at 12:18 PM, Bryan  wrote:
>
> > This could be a result of my strange usage of comet actors, but I'm
> > getting incosistent comet behavior.  When run in windows + jetty I
> > have no problems.  In linux + jetty, subsequent requests fail.  I'll
> > explain.
>
> > I have attached comet-test.tar.gz to the files page as an example.
> > When you enter in a search term and click on submit it should popup up
> > 2 JS alert messages.  This seems to work everytime upon first request
> > (when you restart jetty).  On all susequent tries of the Jetty
> > instance, the comet requests fail when you click back to the home page
> > and search again.  I've tried clearing my browser cache, cookies, and
> > even trying on a remote windows browser with no luck.  If I add
> > Thread.sleep(1000) to the comet actor's localSetup, then everything
> > appears to work OK.
>
> > Please see the sample code and let me know if I'm doing something
> > wrong.
>
> > Thanks,
> > Bryan
>
> --
> Lift, the simply functional web frameworkhttp://liftweb.net
> Beginning Scalahttp://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
-~--~~~~--~~--~--~---



[Lift] Re: Strange Comet Behavior

2009-05-11 Thread David Pollak
You didn't include the code... :-(

On Mon, May 11, 2009 at 12:18 PM, Bryan  wrote:

>
> This could be a result of my strange usage of comet actors, but I'm
> getting incosistent comet behavior.  When run in windows + jetty I
> have no problems.  In linux + jetty, subsequent requests fail.  I'll
> explain.
>
> I have attached comet-test.tar.gz to the files page as an example.
> When you enter in a search term and click on submit it should popup up
> 2 JS alert messages.  This seems to work everytime upon first request
> (when you restart jetty).  On all susequent tries of the Jetty
> instance, the comet requests fail when you click back to the home page
> and search again.  I've tried clearing my browser cache, cookies, and
> even trying on a remote windows browser with no luck.  If I add
> Thread.sleep(1000) to the comet actor's localSetup, then everything
> appears to work OK.
>
> Please see the sample code and let me know if I'm doing something
> wrong.
>
> Thanks,
> Bryan
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Re: How forms work (the life cycle of request)

2009-05-11 Thread erik.karls...@iki.fi

> Give me a week or some and I think I'll have something that you'll like...
> basically, you can register a function that's called when stuff is added to
> the function table... and there'll be a "why" associated with the adding.
> When you're running in test mode, you can intercept the functions and then
> at some time in the future replay them and verify that they do the right
> thing(tm).

Whoa, this sounds good! Will definitely try it when there is something
available.

- Erik

>
>
>
> > br,
> > - Erik
>
> > > Thanks,
>
> > > David
>
> > > > I would like to understand this so that I could create tests for it.
>
> > > > br,
> > > > - Erik
>
> > > --
> > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > Follow me:http://twitter.com/dpp
> > > Git some:http://github.com/dpp
>
> --
> Lift, the simply functional web frameworkhttp://liftweb.net
> Beginning Scalahttp://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
-~--~~~~--~~--~--~---



[Lift] Strange Comet Behavior

2009-05-11 Thread Bryan

This could be a result of my strange usage of comet actors, but I'm
getting incosistent comet behavior.  When run in windows + jetty I
have no problems.  In linux + jetty, subsequent requests fail.  I'll
explain.

I have attached comet-test.tar.gz to the files page as an example.
When you enter in a search term and click on submit it should popup up
2 JS alert messages.  This seems to work everytime upon first request
(when you restart jetty).  On all susequent tries of the Jetty
instance, the comet requests fail when you click back to the home page
and search again.  I've tried clearing my browser cache, cookies, and
even trying on a remote windows browser with no luck.  If I add
Thread.sleep(1000) to the comet actor's localSetup, then everything
appears to work OK.

Please see the sample code and let me know if I'm doing something
wrong.

Thanks,
Bryan

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Confusion about Lift-Core

2009-05-11 Thread Charles F. Munat

How would you draw the diagram? Don't be so sure that your learning 
style isn't mirrored by others...

Chas.

David Pollak wrote:
> In this case, I don't think lift-core means the same as the lift-core 
> package.
> 
> I'm also not a fan of layer diagrams in general... I think that they 
> fail to show the interconnected nature of things... but that's just my 
> learning style.
> 
> On Sun, May 10, 2009 at 11:03 AM, Charles F. Munat  > wrote:
> 
> No complaints here. I'm just confused by the diagram in the Lift book.
> I'm very literal about these things, and this diagram doesn't make much
> sense to me. (Probably, the problem is in my addled brain, not the
> diagram.) I'm trying to figure out if it can be improved and, if so,
> how.
> 
> 
> 
> Chas.
> 
> David Pollak wrote:
>  > A long time ago, I insisted that Lift was everything that we had
> in all
>  > the Lift packages.  When DavidB split Lift into different
> packages, he
>  > called the "whole thing that includes all Lift packages" Lift
> Core.  It
>  > would probably be better named "Lift Bloat" (this is a joke), but
> it is
>  > what it is.
>  >
>  > On Sat, May 9, 2009 at 11:49 PM, Charles F. Munat  
>  > >> wrote:
>  >
>  >
>  > What exactly is Lift-Core. When I read Chapter 7 of the Lift
> book, it
>  > says that Lift-Core is
>  >
>  > "The engine of the framework responsible for the request/response
>  > lifecycle, the rendering pipeline, invoking the user's
> functions, etc.
>  > We don't directly cover the core in this book because
> essentially all of
>  > the functionality that we do cover sits on top of the core."
>  >
>  > But when I look in the source code under lift-core, there's
> nothing
>  > there except a pom.xml file that appears to pull a bunch of
>  > dependencies, namely, lift-util, lift-webkit, lift-mapper,
> lift-machine,
>  > lift-record, lift-textile, lift-facebook, lift-amqp,
> lift-xmpp, and
>  > lift-widgets.
>  >
>  > So does "lift-core" comprise these widgets? Or is the lift-core
>  > something else? (The diagram in the book shows the Mapper,
> for example,
>  > as being separate from the Core.)
>  >
>  > Thanks for any help.
>  >
>  > Chas.
>  >
>  >
>  >
>  >
>  >
>  > --
>  > 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
>  >
>  > >
> 
> 
> 
> 
> 
> -- 
> 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
-~--~~~~--~~--~--~---



[Lift] Re: How forms work (the life cycle of request)

2009-05-11 Thread David Pollak
On Mon, May 11, 2009 at 10:28 AM, erik.karls...@iki.fi <
erik.b.karls...@gmail.com> wrote:

>
> Hi,
> > Scala supports true closures which means that variables in scope
> (including
> > "this") are bound to the function.
> >
> > Lift associates the function passed to SHtml.text(defaultValue,
> > passedFunction) with a GUID and returns places that GUID in the name
> > attribute of the generated  HTML element.  When the form is
> > submitted, Lift looks up the GUID in the function table and calls the
> > function with the passed parameter.
> >
> > So, the "by whom" answer is the "runParams" method in LiftSession.  This
> is
> > done early in the request cycle.
> >
> > Does this help?
> >
>
> Thanks, this clarified how it works.  Do you have any recommendation
> how these functions (those that are then called in runParams) would be
> actually tested. My initial idea was to extract the functions from the
> session (after calling snippet's function) and then call them in right
> order to verify the result. This could be probably used but some how
> sound a bit too complicated for a unit test.


Give me a week or some and I think I'll have something that you'll like...
basically, you can register a function that's called when stuff is added to
the function table... and there'll be a "why" associated with the adding.
When you're running in test mode, you can intercept the functions and then
at some time in the future replay them and verify that they do the right
thing(tm).


>
>
> br,
> - Erik
>
> > Thanks,
> >
> > David
> >
> > > I would like to understand this so that I could create tests for it.
> >
> > > br,
> > > - Erik
> >
> > --
> > Lift, the simply functional web frameworkhttp://liftweb.net
> > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > Follow me:http://twitter.com/dpp
> > Git some:http://github.com/dpp
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Re: How forms work (the life cycle of request)

2009-05-11 Thread erik.karls...@iki.fi

Hi,
> Scala supports true closures which means that variables in scope (including
> "this") are bound to the function.
>
> Lift associates the function passed to SHtml.text(defaultValue,
> passedFunction) with a GUID and returns places that GUID in the name
> attribute of the generated  HTML element.  When the form is
> submitted, Lift looks up the GUID in the function table and calls the
> function with the passed parameter.
>
> So, the "by whom" answer is the "runParams" method in LiftSession.  This is
> done early in the request cycle.
>
> Does this help?
>

Thanks, this clarified how it works.  Do you have any recommendation
how these functions (those that are then called in runParams) would be
actually tested. My initial idea was to extract the functions from the
session (after calling snippet's function) and then call them in right
order to verify the result. This could be probably used but some how
sound a bit too complicated for a unit test.

br,
- Erik

> Thanks,
>
> David
>
> > I would like to understand this so that I could create tests for it.
>
> > br,
> > - Erik
>
> --
> Lift, the simply functional web frameworkhttp://liftweb.net
> Beginning Scalahttp://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
-~--~~~~--~~--~--~---



[Lift] Re: Write access to the id field of ProtoUser (for testing)

2009-05-11 Thread erik.karls...@iki.fi

That work> A hah!  I had forgotten that I'd done this.  Try the
following:
>
> myUser.runSafe {
>   myUser.id(55L)
>
> }
>

Now it works and thanks for the explanation!!

br,
- Erik


> Mapper supports read and write access control on a field by field bases.
>  You can put in complex logic (e.g., a taxpayer ID field can only be read by
> the person who owns the record) into the code and the logic will be enforced
> unless you are running in a "safe" code block.  This makes code reviews a
> lot easier... you check the logic for the access control and you check for
> places that the code is in "safe mode" (should be almost nowhere... and
> should be marked with big comments) and that's the code review rather than
> every point in the code where the field in question is being accessed.  
> Seehttp://blog.lostlake.org/index.php?/archives/19-Keeping-the-meaning-w...
>
> Thanks,
>
> David
>
>
>
>
>
> > Should I run my test in different run.mode? test?
>
> > br,
> > - Erik
>
> > > Please give that a try.
>
> > > Thanks,
>
> > > David
>
> > > > Thanks beforehand,
>
> > > > - Erik
>
> > > --
> > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > Follow me:http://twitter.com/dpp
> > > Git some:http://github.com/dpp
>
> --
> Lift, the simply functional web frameworkhttp://liftweb.net
> Beginning Scalahttp://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
-~--~~~~--~~--~--~---



[Lift] Re: Alternating row colors

2009-05-11 Thread David Pollak
On Mon, May 11, 2009 at 8:19 AM, Magnus Alvestad
wrote:

>
> To elaborate, I added a $(document).ready function to handle this.
>
> However!
>
> Some other pages have ajax functionality. When they update html in the
> page, this html (and the page) will not be 'reprocessed' by JQuery.
> Can I handle this in a generic manner?


Sure... when you update with Ajax, you're always sending JavaScript, e.g.,
SetHtml(id, new stuff)... so you could do something like:

SetHtml(id, new stuff) & Raw(""" $('.striped
tr:nth-child(odd)').css('background-color','#DD');""")



>
>
> -Magnus
>
> On May 11, 5:09 pm, Magnus Alvestad  wrote:
> > Ah! Based on Viktors suggestions and some more info at:
> >
> > http://15daysofjquery.com/examples/zebra/
> >
> > I was able to write this in a couple of lines of JQuery!
> >
> > -Magnus
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Re: Alternating row colors

2009-05-11 Thread Magnus Alvestad

To elaborate, I added a $(document).ready function to handle this.

However!

Some other pages have ajax functionality. When they update html in the
page, this html (and the page) will not be 'reprocessed' by JQuery.
Can I handle this in a generic manner?

-Magnus

On May 11, 5:09 pm, Magnus Alvestad  wrote:
> Ah! Based on Viktors suggestions and some more info at:
>
> http://15daysofjquery.com/examples/zebra/
>
> I was able to write this in a couple of lines of JQuery!
>
> -Magnus

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Alternating row colors

2009-05-11 Thread Magnus Alvestad

Ah! Based on Viktors suggestions and some more info at:

http://15daysofjquery.com/examples/zebra/

I was able to write this in a couple of lines of JQuery!

-Magnus

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Alternating row colors

2009-05-11 Thread Timothy Perrett


Always there with a nice solution Viktor! Kudos!

On 11/05/2009 15:07, "Viktor Klang"  wrote:

> This is the jQuery approach: (written from head, so may not compile)
> 
> CSS= .striped tr { background-color : #FF }
> MARKUP=  class="striped">hohohahahihi<
> /tr>
> JS= $('.striped tr:nth-child(odd)').css('background-color','#DD');
> 
> Ref: http://dev.opera.com/articles/view/zebra-striping-tables-with-css3/
> 
> Cheers,
> Viktor



--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Alternating row colors

2009-05-11 Thread Magnus Alvestad

Thank you for your answers. I'll try to include some more detail
because I was not able to apply your suggestions to my code.

My template has a section like this:


  

  

  


while my snippet looks more or less like this:

class T {

  val questions = "One" :: "Two" :: "Three" :: Nil

  private def doList()(html:NodeSeq): NodeSeq = {
questions.flatMap(q => bind ("question", html,
  "text" -> Text(q))
  }

  def list(html:NodeSeq) = {
bind("question", html, "list" -> doList() )
  }
}

-Magnus

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Alternating row colors

2009-05-11 Thread marius d.

Really neat, Viktor !

On May 11, 5:07 pm, Viktor Klang  wrote:
> This is the jQuery approach: (written from head, so may not compile)
>
> CSS= .striped tr { background-color : #FF }
> MARKUP=  class="striped">hohohahahihi
> JS= $('.striped tr:nth-child(odd)').css('background-color','#DD');
>
> Ref:http://dev.opera.com/articles/view/zebra-striping-tables-with-css3/
>
> Cheers,
> Viktor
>
>
>
> On Mon, May 11, 2009 at 3:54 PM, marius d.  wrote:
>
> > Assume that in your snippet you have a List[String] that you want to
> > render as table rows such as:
>
> > val list = "one" :: "two" :: "three" :: Nil
>
> > def render(xhtml: NodeSeq): NodeSeq = {
> >  {
> >  list.zipWithIndex((e, idx) => {e} %
> >     if (idx % 2 == 0)
> >         Null // Null is a MetaData here
> >     else
> >         ("class" -> "my_gray_out")
> >  )
> >  }
> > }
>
> > note that i did not test the code ... so it may not compile ... but I
> > hope you got the idea.
>
> > Br's,
> > marius
>
> > On May 11, 3:52 pm, Magnus Alvestad  wrote:
> > > I'm still learning lift (and scala). For my sample application I want
> > > to display a table with alternating row colors. I want to put the
> > > style in my CSS file and add a classname to every TR in my table to
> > > indicate odd and even rows. However, I don't know how to take a value
> > > from the snippet binding and assigning it to an attribute in my
> > > template file. Can anyone point me in the right direction?
>
> > > -Magnus
>
> --
> Viktor Klang
> Senior Systems Analyst
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Confusion about Lift-Core

2009-05-11 Thread David Bernard
See
http://groups.google.com/group/liftweb/browse_thread/thread/957d5c8942b70a19/6fc14f442224626a

the name "lift-core" was keep for backward compatibility and to avoid
existing user to replace "lift-core" by lift-full or the exact list of
need-jar in pom.xml.

/davidB

On Mon, May 11, 2009 at 16:10, David Pollak
wrote:

> In this case, I don't think lift-core means the same as the lift-core
> package.
> I'm also not a fan of layer diagrams in general... I think that they fail
> to show the interconnected nature of things... but that's just my learning
> style.
>
>
> On Sun, May 10, 2009 at 11:03 AM, Charles F. Munat  wrote:
>
>> No complaints here. I'm just confused by the diagram in the Lift book.
>> I'm very literal about these things, and this diagram doesn't make much
>> sense to me. (Probably, the problem is in my addled brain, not the
>> diagram.) I'm trying to figure out if it can be improved and, if so, how.
>>
>>
>>
>> Chas.
>>
>> David Pollak wrote:
>> > A long time ago, I insisted that Lift was everything that we had in all
>> > the Lift packages.  When DavidB split Lift into different packages, he
>> > called the "whole thing that includes all Lift packages" Lift Core.  It
>> > would probably be better named "Lift Bloat" (this is a joke), but it is
>> > what it is.
>> >
>> > On Sat, May 9, 2009 at 11:49 PM, Charles F. Munat > > > wrote:
>> >
>> >
>> > What exactly is Lift-Core. When I read Chapter 7 of the Lift book,
>> it
>> > says that Lift-Core is
>> >
>> > "The engine of the framework responsible for the request/response
>> > lifecycle, the rendering pipeline, invoking the user's functions,
>> etc.
>> > We don't directly cover the core in this book because essentially
>> all of
>> > the functionality that we do cover sits on top of the core."
>> >
>> > But when I look in the source code under lift-core, there's nothing
>> > there except a pom.xml file that appears to pull a bunch of
>> > dependencies, namely, lift-util, lift-webkit, lift-mapper,
>> lift-machine,
>> > lift-record, lift-textile, lift-facebook, lift-amqp, lift-xmpp, and
>> > lift-widgets.
>> >
>> > So does "lift-core" comprise these widgets? Or is the lift-core
>> > something else? (The diagram in the book shows the Mapper, for
>> example,
>> > as being separate from the Core.)
>> >
>> > Thanks for any help.
>> >
>> > Chas.
>> >
>> >
>> >
>> >
>> >
>> > --
>> > 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
>> >
>> > >
>>
>>
>>
>
>
> --
> 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
-~--~~~~--~~--~--~---



[Lift] Re: Alternating row colors

2009-05-11 Thread Alex Boisvert
Here's another approach that I used in a small project recently...

I wrote a small stateful utility class,

class OddOrEven {
  private var isEven = true
  def getAndToggle: String = {
val s = toString
isEven = (!isEven)
s
  }
  override def toString = if (isEven) "even" else "odd"
}

and I use it as such,

val oddOrEven = new OddOrEven
for (row <- rows) yield {
  
 ... 
  
}

But I generally prefer to put that presentation stuff in the CSS/Javascript
directly instead of in the code.

alex

On Mon, May 11, 2009 at 6:54 AM, marius d.  wrote:

>
> Assume that in your snippet you have a List[String] that you want to
> render as table rows such as:
>
>
> val list = "one" :: "two" :: "three" :: Nil
>
> def render(xhtml: NodeSeq): NodeSeq = {
>  {
>  list.zipWithIndex((e, idx) => {e} %
> if (idx % 2 == 0)
> Null // Null is a MetaData here
> else
> ("class" -> "my_gray_out")
>  )
>  }
> }
>
> note that i did not test the code ... so it may not compile ... but I
> hope you got the idea.
>
> Br's,
> marius
>
> On May 11, 3:52 pm, Magnus Alvestad  wrote:
> > I'm still learning lift (and scala). For my sample application I want
> > to display a table with alternating row colors. I want to put the
> > style in my CSS file and add a classname to every TR in my table to
> > indicate odd and even rows. However, I don't know how to take a value
> > from the snippet binding and assigning it to an attribute in my
> > template file. Can anyone point me in the right direction?
> >
> > -Magnus
> >
>

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Confusion about Lift-Core

2009-05-11 Thread David Pollak
In this case, I don't think lift-core means the same as the lift-core
package.
I'm also not a fan of layer diagrams in general... I think that they fail to
show the interconnected nature of things... but that's just my learning
style.

On Sun, May 10, 2009 at 11:03 AM, Charles F. Munat  wrote:

> No complaints here. I'm just confused by the diagram in the Lift book.
> I'm very literal about these things, and this diagram doesn't make much
> sense to me. (Probably, the problem is in my addled brain, not the
> diagram.) I'm trying to figure out if it can be improved and, if so, how.
>
>
>
> Chas.
>
> David Pollak wrote:
> > A long time ago, I insisted that Lift was everything that we had in all
> > the Lift packages.  When DavidB split Lift into different packages, he
> > called the "whole thing that includes all Lift packages" Lift Core.  It
> > would probably be better named "Lift Bloat" (this is a joke), but it is
> > what it is.
> >
> > On Sat, May 9, 2009 at 11:49 PM, Charles F. Munat  > > wrote:
> >
> >
> > What exactly is Lift-Core. When I read Chapter 7 of the Lift book, it
> > says that Lift-Core is
> >
> > "The engine of the framework responsible for the request/response
> > lifecycle, the rendering pipeline, invoking the user's functions,
> etc.
> > We don't directly cover the core in this book because essentially all
> of
> > the functionality that we do cover sits on top of the core."
> >
> > But when I look in the source code under lift-core, there's nothing
> > there except a pom.xml file that appears to pull a bunch of
> > dependencies, namely, lift-util, lift-webkit, lift-mapper,
> lift-machine,
> > lift-record, lift-textile, lift-facebook, lift-amqp, lift-xmpp, and
> > lift-widgets.
> >
> > So does "lift-core" comprise these widgets? Or is the lift-core
> > something else? (The diagram in the book shows the Mapper, for
> example,
> > as being separate from the Core.)
> >
> > Thanks for any help.
> >
> > Chas.
> >
> >
> >
> >
> >
> > --
> > 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
> >
> > >
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Re: Alternating row colors

2009-05-11 Thread Viktor Klang
This is the jQuery approach: (written from head, so may not compile)

CSS= .striped tr { background-color : #FF }
MARKUP= hohohahahihi
JS= $('.striped tr:nth-child(odd)').css('background-color','#DD');

Ref: http://dev.opera.com/articles/view/zebra-striping-tables-with-css3/

Cheers,
Viktor

On Mon, May 11, 2009 at 3:54 PM, marius d.  wrote:

>
> Assume that in your snippet you have a List[String] that you want to
> render as table rows such as:
>
>
> val list = "one" :: "two" :: "three" :: Nil
>
> def render(xhtml: NodeSeq): NodeSeq = {
>  {
>  list.zipWithIndex((e, idx) => {e} %
> if (idx % 2 == 0)
> Null // Null is a MetaData here
> else
> ("class" -> "my_gray_out")
>  )
>  }
> }
>
> note that i did not test the code ... so it may not compile ... but I
> hope you got the idea.
>
> Br's,
> marius
>
> On May 11, 3:52 pm, Magnus Alvestad  wrote:
> > I'm still learning lift (and scala). For my sample application I want
> > to display a table with alternating row colors. I want to put the
> > style in my CSS file and add a classname to every TR in my table to
> > indicate odd and even rows. However, I don't know how to take a value
> > from the snippet binding and assigning it to an attribute in my
> > template file. Can anyone point me in the right direction?
> >
> > -Magnus
> >
>


-- 
Viktor Klang
Senior Systems Analyst

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Alternating row colors

2009-05-11 Thread marius d.

Assume that in your snippet you have a List[String] that you want to
render as table rows such as:


val list = "one" :: "two" :: "three" :: Nil

def render(xhtml: NodeSeq): NodeSeq = {
 {
  list.zipWithIndex((e, idx) => {e} %
 if (idx % 2 == 0)
 Null // Null is a MetaData here
 else
 ("class" -> "my_gray_out")
  )
  }
}

note that i did not test the code ... so it may not compile ... but I
hope you got the idea.

Br's,
marius

On May 11, 3:52 pm, Magnus Alvestad  wrote:
> I'm still learning lift (and scala). For my sample application I want
> to display a table with alternating row colors. I want to put the
> style in my CSS file and add a classname to every TR in my table to
> indicate odd and even rows. However, I don't know how to take a value
> from the snippet binding and assigning it to an attribute in my
> template file. Can anyone point me in the right direction?
>
> -Magnus
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Write access to the id field of ProtoUser (for testing)

2009-05-11 Thread David Pollak
On Mon, May 11, 2009 at 4:10 AM, erik.karls...@iki.fi <
erik.b.karls...@gmail.com> wrote:

>
> Hi,
>
> > New users are moderated to avoid spam... on weekends, it may take up to a
> > day for postings to appear on list.
> Ok, sorry for the spam then ;)
>
> > You should be able to do:
> >
> > myUserInstance.id(55L)
> >
> > That should set it to 55.
>
> I try to do this in my unit test:
>
> val u2 = User.create
> u2.id(20)
>
> I gent an exception:
> "Do not have permission to set this field"
>
> It is thrown by the code:
>
> #   def set(value: FieldType): FieldType = {
> # if (safe_? || writePermission_?) i_set_!(value)
> # else throw new Exception("Do not have permissions to set this
> field")
> #   }
>
> in MappedField
>
> I check and it seams that the writePermission returns false


A hah!  I had forgotten that I'd done this.  Try the following:

myUser.runSafe {
  myUser.id(55L)
}

Mapper supports read and write access control on a field by field bases.
 You can put in complex logic (e.g., a taxpayer ID field can only be read by
the person who owns the record) into the code and the logic will be enforced
unless you are running in a "safe" code block.  This makes code reviews a
lot easier... you check the logic for the access control and you check for
places that the code is in "safe mode" (should be almost nowhere... and
should be marked with big comments) and that's the code review rather than
every point in the code where the field in question is being accessed.  See
http://blog.lostlake.org/index.php?/archives/19-Keeping-the-meaning-with-the-bytes.html

Thanks,

David

>
>
> Should I run my test in different run.mode? test?
>
> br,
> - Erik
>
> >
> > Please give that a try.
> >
> > Thanks,
> >
> > David
> >
> >
> >
> > > Thanks beforehand,
> >
> > > - Erik
> >
> > --
> > Lift, the simply functional web frameworkhttp://liftweb.net
> > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > Follow me:http://twitter.com/dpp
> > Git some:http://github.com/dpp
>
> >
>


-- 
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
-~--~~~~--~~--~--~---



[Lift] Alternating row colors

2009-05-11 Thread Magnus Alvestad

I'm still learning lift (and scala). For my sample application I want
to display a table with alternating row colors. I want to put the
style in my CSS file and add a classname to every TR in my table to
indicate odd and even rows. However, I don't know how to take a value
from the snippet binding and assigning it to an attribute in my
template file. Can anyone point me in the right direction?

-Magnus

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Write access to the id field of ProtoUser (for testing)

2009-05-11 Thread erik.karls...@iki.fi

Hi,

> New users are moderated to avoid spam... on weekends, it may take up to a
> day for postings to appear on list.
Ok, sorry for the spam then ;)

> You should be able to do:
>
> myUserInstance.id(55L)
>
> That should set it to 55.

I try to do this in my unit test:

val u2 = User.create
u2.id(20)

I gent an exception:
"Do not have permission to set this field"

It is thrown by the code:

#   def set(value: FieldType): FieldType = {
# if (safe_? || writePermission_?) i_set_!(value)
# else throw new Exception("Do not have permissions to set this
field")
#   }

in MappedField

I check and it seams that the writePermission returns false

Should I run my test in different run.mode? test?

br,
- Erik

>
> Please give that a try.
>
> Thanks,
>
> David
>
>
>
> > Thanks beforehand,
>
> > - Erik
>
> --
> Lift, the simply functional web frameworkhttp://liftweb.net
> Beginning Scalahttp://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
-~--~~~~--~~--~--~---



[Lift] Re: LoanWrapper

2009-05-11 Thread Charles F. Munat

Just exploring in Lift. (Reading the Lift book, Chapter 7.)

Chas.

Timothy Perrett wrote:
> Out of interest - what is your use case? What are you trying to do
> that you think LoanWrapper might be appropriate for? Or are you just
> exploring lift? :-)
> 
> Cheers, Tim
> 
> On May 10, 9:03 pm, "Charles F. Munat"  wrote:
>> It will after I review some stuff about types and look through some more
>> source code. Thanks!
>>
>> Chas.
> 
> > 

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: LoanWrapper

2009-05-11 Thread Timothy Perrett

Out of interest - what is your use case? What are you trying to do
that you think LoanWrapper might be appropriate for? Or are you just
exploring lift? :-)

Cheers, Tim

On May 10, 9:03 pm, "Charles F. Munat"  wrote:
> It will after I review some stuff about types and look through some more
> source code. Thanks!
>
> Chas.

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[Lift] Re: Tail merge?

2009-05-11 Thread Viktor Klang
On Sun, May 10, 2009 at 10:39 PM, marius d.  wrote:

>
>
>
> On May 10, 10:08 pm, Viktor Klang  wrote:
> > What I've been noodling about for some time is to have dependency
> management
> > as a part of the framework. That could be easily obtained by having
> widgets
> > etc register their dependencies in a SessionVar[List[Dependency]] and
> then
> > simply add a DispatchPF to serve those dependencies as one package with
> the
> > separate GET.
>
> So what would this solve? ... I mean there is the ResourceServer used
> currently by widgets so that widget's dependencies to be served ...
> perhaps I'm missing something?


Nevermind; I'll see if I can make a PoC using ResourceServer.


>
>
> >
> > The downsides I've come up with are:
> >
> > * Adds a reasonable amount of complexity
> > * The order of the dependencies is hard to get right
> > * Premature optimization
> > * Moves away from idea to have JS libraries served by third party hosts
> > * Kind of defeats the purpose of caching JS
> >
> > Just my 2 cents,
> > Viktor
> >
> > On Sun, May 10, 2009 at 8:35 PM, Timothy Perrett  >wrote:
> >
> >
> >
> >
> >
> > > Yeah google analytics is a good use case. I think talking about
> > > smashing static files is off topic, but there is some value in having
> > > a tail merge for when you want to put stuff in just before the body
> > > tag. My only thinking right now is that why do we need a specific
> > > snippet to do this? Right now,  and  > > param> would work perfectly for this right?
> >
> > > Cheers, Tim
> >
> > > On May 10, 3:21 pm, "Bryan."  wrote:
> > > > A nice use for this "tail merge" would be for the Google Analytics
> > > > tracking code, especially the ecommerce tracking code.
> >
> > > > Here's something to keep an eye on as well:
> http://blog.digg.com/?p=621
> > > > -- still very new and in development.
> >
> > > > --Bryan
> >
> > > > On May 10, 9:57 am, David Pollak 
> > > > wrote:
> >
> > > > > On Sun, May 10, 2009 at 6:55 AM, marius d. <
> marius.dan...@gmail.com>
> > > wrote:
> >
> > > > > > People can choose to "smash" multiple js/css files into a single
> one,
> > > > > > in fact it is a common practice. However for scripts that can be
> > > > > > deferred putting them at the bottom of the page can improve
> > > rendering.
> >
> > > > > Okay.. so we're not actually putting the scripts on the page, we're
> > > just
> > > > > putting them right about the  tag?
> >
> > > > > > Br's,
> > > > > > Marius
> >
> > > > > > On May 10, 4:42 pm, David Pollak 
> > > > > > wrote:
> > > > > > > On Fri, May 8, 2009 at 5:26 PM, Timothy Perrett
> > >  > > > > > >wrote:
> >
> > > > > > > > Sounds like this could be a neat addition. Looking forward to
> see
> > > what
> > > > > > you
> > > > > > > > come up with :-)
> >
> > > > > > > I'm not 100% keen on it.  Loading a ton of stuff into the HTML
> page
> > > > > > (rather
> > > > > > > than having stuff cached by the browser) makes for larger page
> > > sizes.
> > > > > >  I'd
> > > > > > > much rather see a tool that would analyze the scripts and css
> that
> > > was
> > > > > > > included across lots of pages and recommending to the developer
> to
> > > make
> > > > > > 10
> > > > > > > CSS files or 20 script files into 1.  But that's just me.
> >
> > > > > > > > Cheers, Tim
> >
> > > > > > > > On 08/05/2009 20:19, "marius d." 
> > > wrote:
> >
> > > > > > > > > A  built in snippet might me a good addition. I
> > > could
> > > > > > > > > probably allocate some time to noodle on it.
> >
> > > > > > > > > Br's,
> > > > > > > > > Marius
> >
> > > > > > > > > On May 8, 5:05 pm, KWright 
> > > wrote:
> > > > > > > > >> It's becoming an established best practice that scripts
> should
> > > be
> > > > > > put
> > > > > > > > >> at the END of a page, where possible, in order to speed up
> > > download
> > > > > > > > >> times
> >
> > > > > > > > >> Good article here:
> > >http://developer.yahoo.com/performance/rules.html
> >
> > > > > > > > >> It would be nice if Lift could help encourage and support
> this
> > > by
> > > > > > > > >> allowing a  (or ?) element that could be
> > > merged in
> > > > > > > > >> the same fashion as the head element, perhaps also
> removing
> > > > > > > > >> duplicates, etc.
> >
> > > > > > > > >> This element would then disappear and expose only its
> content
> > > when
> > > > > > the
> > > > > > > > >> page is ultimately sent to the browser.
> >
> > > > > > > --
> > > > > > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > > > > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > > > > > Follow me:http://twitter.com/dpp
> > > > > > > Git some:http://github.com/dpp
> >
> > > > > --
> > > > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > > > Follow me:http://twitter.com/dpp
> > > > > Git some:http://github.com/dpp
> >
> > --
> > Viktor Klang
> > Senior Systems Analyst
> >
>


-- 
Viktor Klang
Senior Systems Analyst


[Lift] Re: Tail merge?

2009-05-11 Thread marius d.



On May 10, 9:35 pm, Timothy Perrett  wrote:
> Yeah google analytics is a good use case. I think talking about
> smashing static files is off topic, but there is some value in having
> a tail merge for when you want to put stuff in just before the body
> tag. My only thinking right now is that why do we need a specific
> snippet to do this? Right now,  and  param> would work perfectly for this right?


Well it would work but but you have to explicitly put the bind in
there and for dynamic (potentially 3-rd party) views (such as widgets)
it get more awkward because a generic widget would have to know about
the application specific bind name. Of course the bind name could be
parameterized but this seems unsound to me here. Whereas 
seems to me a trivial thing to use essentially from any view, snippet
etc.

>
> Cheers, Tim
>
> On May 10, 3:21 pm, "Bryan."  wrote:
>
> > A nice use for this "tail merge" would be for the Google Analytics
> > tracking code, especially the ecommerce tracking code.
>
> > Here's something to keep an eye on as well:  http://blog.digg.com/?p=621
> > -- still very new and in development.
>
> > --Bryan
>
> > On May 10, 9:57 am, David Pollak 
> > wrote:
>
> > > On Sun, May 10, 2009 at 6:55 AM, marius d.  
> > > wrote:
>
> > > > People can choose to "smash" multiple js/css files into a single one,
> > > > in fact it is a common practice. However for scripts that can be
> > > > deferred putting them at the bottom of the page can improve rendering.
>
> > > Okay.. so we're not actually putting the scripts on the page, we're just
> > > putting them right about the  tag?
>
> > > > Br's,
> > > > Marius
>
> > > > On May 10, 4:42 pm, David Pollak 
> > > > wrote:
> > > > > On Fri, May 8, 2009 at 5:26 PM, Timothy Perrett 
> > > > >  > > > >wrote:
>
> > > > > > Sounds like this could be a neat addition. Looking forward to see 
> > > > > > what
> > > > you
> > > > > > come up with :-)
>
> > > > > I'm not 100% keen on it.  Loading a ton of stuff into the HTML page
> > > > (rather
> > > > > than having stuff cached by the browser) makes for larger page sizes.
> > > >  I'd
> > > > > much rather see a tool that would analyze the scripts and css that was
> > > > > included across lots of pages and recommending to the developer to 
> > > > > make
> > > > 10
> > > > > CSS files or 20 script files into 1.  But that's just me.
>
> > > > > > Cheers, Tim
>
> > > > > > On 08/05/2009 20:19, "marius d."  wrote:
>
> > > > > > > A  built in snippet might me a good addition. I could
> > > > > > > probably allocate some time to noodle on it.
>
> > > > > > > Br's,
> > > > > > > Marius
>
> > > > > > > On May 8, 5:05 pm, KWright  wrote:
> > > > > > >> It's becoming an established best practice that scripts should be
> > > > put
> > > > > > >> at the END of a page, where possible, in order to speed up 
> > > > > > >> download
> > > > > > >> times
>
> > > > > > >> Good article 
> > > > > > >> here:http://developer.yahoo.com/performance/rules.html
>
> > > > > > >> It would be nice if Lift could help encourage and support this by
> > > > > > >> allowing a  (or ?) element that could be merged 
> > > > > > >> in
> > > > > > >> the same fashion as the head element, perhaps also removing
> > > > > > >> duplicates, etc.
>
> > > > > > >> This element would then disappear and expose only its content 
> > > > > > >> when
> > > > the
> > > > > > >> page is ultimately sent to the browser.
>
> > > > > --
> > > > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > > > Follow me:http://twitter.com/dpp
> > > > > Git some:http://github.com/dpp
>
> > > --
> > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > Beginning Scalahttp://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
-~--~~~~--~~--~--~---