[Lift] Re: Tomcat css access problem

2009-08-27 Thread Yousry Abdallah

Hi,

your suggestion didn't work for me because I'm using url-rewrite in my
application.

Something like
  http://...application/parameterA/
  http://...application/parameterA/parameterB/

Therefore the relative path wouldn't match.

The CSSHelper function fixes the absolute path.
This is important because I can deploy the same package in
development "/"  and production "/applicationFolder/" environment.

On 26 Aug., 23:12, Jefken De Vleesetenden Boterham
 wrote:
> Hi,
>
> Then I guess my next question is: how do you define where your css is located?
>
> I have a function that gives the location of my css in the following way:
> def css =  rel="stylesheet" type="text/css"/>
>
> You shouldn't need the S.hostAndPath+"/" part unless you're using
> fancy redirecting like I'm doing. I call that function from my main
> template. In fact, you shouldn't even need a function and could just
> use  rel="stylesheet" type="text/css"/>
>
> In your case, I'd think that the
> relativePathToFolderContainingCSS/cd.css would be
> "css/kungleNext.css", but I might be mistaken.
>
> - Philippe
>
>
>
> On Wed, Aug 26, 2009 at 1:23 PM, Yousry Abdallah wrote:
>
> > Hi,
> > you are absolutely right.
> > I use mvn jetty:run in my development environment to test the
> > application.
> > Than I build a package with mvn package and copy it to the tomcat
> > webapp directory.
>
> > Thank you,
> > Yousry
>
> > On 26 Aug., 12:46, Jefken De Vleesetenden Boterham
> >  wrote:
> >> Hi,
>
> >> I'm assuming you mean deploying under jetty and tomcat. I only know
> >> derby to be a database.
>
> >> How exactly do you deploy under jetty and tomcat?
>
> >> Personally, I use jetty for testing and deploy with mvn jetty:run,
> >> while I use tomcat on the test and production servers in which case I
> >> just drop the war file under web-apps.
>
> >> Thanks,
>
> >> Philippe
>
> >> On Wed, Aug 26, 2009 at 11:47 AM, Yousry Abdallah wrote:
>
> >> > Hi,
> >> >  I'm working with 1.1 snapshot (latest) and have the following problem
> >> > with a local css reference:
>
> >> > If I deploy my webapp under derby the resulting html output looks
> >> > fine:
>
> >> >   >> >   href="/KungleNext-0.1-SNAPSHOT/css/kungleNext.css" />
>
> >> > The same application deployed under tomcat produces this buggy
> >> > reference:
>
> >> >  >> >   href="/css/kungleNext.css" />
>
> >> > My snippet defines the ling as follows:
>
> >> > ...
> >> >  >> > media="screen" />
> >> > ..
>
> >> --http://pmonnaie.blogspot.com/
>
> --http://pmonnaie.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: 1.1-SNAPSHOT issue?

2009-08-27 Thread Jeppe Nejsum Madsen

David Pollak  writes:

> I've just pushed a new version live that will behave more gracefully if the
> xsd cannot be loaded.

I haven't looked at the new validation code, but if it fetches the DTD
directly from the URL, we might consider using a local copy for a number
of reasons:

1) It doesn't change, so having a local copy should be safe and fast

2) You don't run into the issues described in this thread 

3) You won't get spurious 503 errors from w3c's servers (See
http://www.w3.org/blog/systeam/2008/02/08/w3c_s_excessive_dtd_traffic). I'm
not sure how many requests are considered abuse, and since we actually
do need the Schema it's probably not really abuse either, but it doesn't
hurt to play nice :-)

/Jeppe



--~--~-~--~~~---~--~~
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: Multiple sites, same login

2009-08-27 Thread Marc Boschma

Maybe https://opensso.dev.java.net/ might be of interest? Might also  
be a bit of work...

Marc

On 26/08/2009, at 2:53 AM, Charles F. Munat wrote:

>
> Now this is an interesting idea. I'll think about it...
>
> Thanks!
>
> Chas.
>
> David Pollak wrote:
>>
>>
>> On Mon, Aug 24, 2009 at 3:23 PM, Charles F. Munat > > wrote:
>>
>>
>>I'm building two Lift applications that access the same back end
>>database -- one is for the public site, and the other, which  
>> will use a
>>subdomain, is for administration of the public site.
>>
>>A third application will access a separate database, but will be  
>> related
>>to the previous two sites.
>>
>>Any suggestions as to how I might have one login that keeps the  
>> user
>>logged in across all these sites? Obviously, OpenID would work,  
>> and
>>there's complex stuff involving LDAP servers, etc., but I'd like  
>> to keep
>>it fairly simple.
>>
>>Ideas?
>>
>>
>> You could put a cookie at the top level for the domain that's an
>> encrypted mix of the user's primary key and the current time.  If the
>> user comes to another one of the sites, it could examine the cookie  
>> and
>> see if it should create a session for the user.
>>
>>
>>
>>
>>Thanks!
>>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
>>
>>>
>
> >


--~--~-~--~~~---~--~~
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: 1.1-SNAPSHOT issue?

2009-08-27 Thread E. Biggs

Ok here's the problem stripped down. The merge happens but the 
node isn't being removed from the body
Let me know if you'd like it in some other format.

templates-hidden/outer.html:


  
  
  
  

  



inner.html:


  
Inner
  


renders:





  


Inner






  
Inner
  




// 




On Aug 26, 9:58 pm, David Pollak 
wrote:
> On Wed, Aug 26, 2009 at 8:32 PM, E. Biggs  wrote:
>
> > Thanks David! My pages now render - although broken...  the cause
> > appears to be a failed head merge between my template's head and the
> > surrounding template's head.
>
> Can you post an example of the failing use case and I'll roll it into our
> tests and get it works?
>
>
>
>
>
>
>
> > On Aug 26, 7:51 pm, David Pollak 
> > wrote:
> > > I've just pushed a new version live that will behave more gracefully if
> > the
> > > xsd cannot be loaded.
>
> > > On Wed, Aug 26, 2009 at 7:39 PM, Justin Reardon <
> > justin.rear...@gmail.com>wrote:
>
> > > > Probably caused by this if you're in a dev environment:
> > > >http://groups.google.com/group/liftweb/t/90750187a6c29c2c
>
> > > > On Aug 26, 9:36 pm, "E. Biggs"  wrote:
> > > > > Hi there,
>
> > > > > I just did a mvn -U jetty:run
>
> > > > > and my site that I know was working fine before is now broken with
> > > > > this error displayed in the browser for any url:
>
> > > > > org.xml.sax.SAXParseException: schema_reference.4: Failed to read
> > > > > schema document 'http://www.w3.org/2002/08/xhtml/xhtml1-
> > > > > transitional.xsd', because 1) could not find the document; 2) the
> > > > > document could not be read; 3) the root element of the document is
> > not
> > > > > .
>
> > com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseE
> > > > xception
> > > > > (ErrorHandlerWrapper.java:236)
>
> > com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error
> > > > > (ErrorHandlerWrapper.java:172)
>
> > > > com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError
> > > > > (XMLErrorReporter.java:382)
>
> > > > com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError
> > > > > (XMLErrorReporter.java:316)
>
> > com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.reportSche
> > > > maError
> > > > > (XSDHandler.java:2245)
>
> > com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.getSchema
> > > > > (XSDHandler.java:1590)
>
> > com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.parseSchem
> > > > a
> > > > > (XSDHandler.java:438)
>
> > > > com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadSchema
> > > > > (XMLSchemaLoader.java:556)
>
> > > > com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadGrammar
> > > > > (XMLSchemaLoader.java:523)
>
> > com.sun.org.apache.xerces.internal.jaxp.validation.xs.SchemaFactoryImpl.new
> > > > Schema
> > > > > (SchemaFactoryImpl.java:206)
>
> > > > javax.xml.validation.SchemaFactory.newSchema(SchemaFactory.java:489)
>
> > > > javax.xml.validation.SchemaFactory.newSchema(SchemaFactory.java:521)
> > > > >         net.liftweb.http.GenericValidtor.schema(LiftRules.scala:1116)
> > > > >         net.liftweb.http.GenericValidtor.apply(LiftRules.scala:1119)
> > > > >         net.liftweb.http.GenericValidtor.apply(LiftRules.scala:1101)
>
> > > > net.liftweb.http.LiftSession$$anonfun$8.apply(LiftSession.scala:607)
>
> > > > net.liftweb.http.LiftSession$$anonfun$8.apply(LiftSession.scala:607)
> > > > >         scala.List.flatMap(List.scala:1132)
> > > > >         net.liftweb.http.LiftSession.net
> > $liftweb$http$LiftSession$$merge
> > > > > (LiftSession.scala:607)
>
> > net.liftweb.http.LiftSession$$anonfun$10$$anonfun$apply$30.apply
> > > > > (LiftSession.scala:717)
>
> > net.liftweb.http.LiftSession$$anonfun$10$$anonfun$apply$30.apply
> > > > > (LiftSession.scala:714)
> > > > >         net.liftweb.util.EmptyBox.or(Box.scala:374)
>
> > > > net.liftweb.http.LiftSession$$anonfun$10.apply(LiftSession.scala:711)
>
> > > > net.liftweb.http.LiftSession$$anonfun$10.apply(LiftSession.scala:704)
> > > > >         net.liftweb.util.EmptyBox.or(Box.scala:374)
>
> > > > net.liftweb.http.LiftSession.processRequest(LiftSession.scala:704)
> > > > > ---SNIP---
>
> > > > > Anybody else getting this? Or know what the problem could be?
>
> > > --
> > > 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 li

[Lift] Re: Ext.Direct

2009-08-27 Thread Timothy Perrett


I think Chas is working with Ext.JS However, because of licensing with
ExtJS we cannot "integrate" it into lift.

Cheers, Tim

On 27/08/2009 03:56, "Naftoli Gugenheim"  wrote:

> 
> Has anyone used lift with Ext.JS forms/Ext.Direct?
> 
> 
> P.S. It would be neat if it could interact with Lift's JSON support. I wonder
> what it would take.
> 
> 
> > 
> 



--~--~-~--~~~---~--~~
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: Bug in MappedEmail: emailPattern is wrong

2009-08-27 Thread Marc Boschma
Personally I use:

"^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-] 
+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01- 
\x09\x0b\x0c\x0e-\x7f])*")@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a- 
z0-9](?:[a-z0-9-]*[a-z0-9])?$"

Marc

On 27/08/2009, at 9:32 AM, David Pollak wrote:

> Thanks.
>
> Changed and pushed to GitHub.  Allow 2 hours for Maven availability.
>
> On Wed, Aug 26, 2009 at 4:15 PM, harryh  wrote:
>
> > What's the change to the RegEx?
>
> val emailPattern = Pattern.compile("^[a-z0-9._%-+]+@(?:[a-z0-9-]+\\.)+
> [a-z]{2,4}$")
>
> note the addition of the + to the allowed characters before the @
>
> -harryh
>
>
>
>
> -- 
> 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: Tomcat css access problem

2009-08-27 Thread Jefken De Vleesetenden Boterham

Hi,

I see...

I use url rewriting as well, but I didn't know about the CSSHelper
function! I just constructed my own link using the S.hostAndPath
function to dynamically create an absolute path.

I'll try out the CSSHelper function and see what I can find!


Thanks,

Philippe

On Thu, Aug 27, 2009 at 7:49 AM, Yousry Abdallah wrote:
>
> Hi,
>
> your suggestion didn't work for me because I'm using url-rewrite in my
> application.
>
> Something like
>  http://...application/parameterA/
>  http://...application/parameterA/parameterB/
>
> Therefore the relative path wouldn't match.
>
> The CSSHelper function fixes the absolute path.
> This is important because I can deploy the same package in
> development "/"  and production "/applicationFolder/" environment.
>
> On 26 Aug., 23:12, Jefken De Vleesetenden Boterham
>  wrote:
>> Hi,
>>
>> Then I guess my next question is: how do you define where your css is 
>> located?
>>
>> I have a function that gives the location of my css in the following way:
>> def css = > rel="stylesheet" type="text/css"/>
>>
>> You shouldn't need the S.hostAndPath+"/" part unless you're using
>> fancy redirecting like I'm doing. I call that function from my main
>> template. In fact, you shouldn't even need a function and could just
>> use > rel="stylesheet" type="text/css"/>
>>
>> In your case, I'd think that the
>> relativePathToFolderContainingCSS/cd.css would be
>> "css/kungleNext.css", but I might be mistaken.
>>
>> - Philippe
>>
>>
>>
>> On Wed, Aug 26, 2009 at 1:23 PM, Yousry Abdallah wrote:
>>
>> > Hi,
>> > you are absolutely right.
>> > I use mvn jetty:run in my development environment to test the
>> > application.
>> > Than I build a package with mvn package and copy it to the tomcat
>> > webapp directory.
>>
>> > Thank you,
>> > Yousry
>>
>> > On 26 Aug., 12:46, Jefken De Vleesetenden Boterham
>> >  wrote:
>> >> Hi,
>>
>> >> I'm assuming you mean deploying under jetty and tomcat. I only know
>> >> derby to be a database.
>>
>> >> How exactly do you deploy under jetty and tomcat?
>>
>> >> Personally, I use jetty for testing and deploy with mvn jetty:run,
>> >> while I use tomcat on the test and production servers in which case I
>> >> just drop the war file under web-apps.
>>
>> >> Thanks,
>>
>> >> Philippe
>>
>> >> On Wed, Aug 26, 2009 at 11:47 AM, Yousry Abdallah 
>> >> wrote:
>>
>> >> > Hi,
>> >> >  I'm working with 1.1 snapshot (latest) and have the following problem
>> >> > with a local css reference:
>>
>> >> > If I deploy my webapp under derby the resulting html output looks
>> >> > fine:
>>
>> >> >  > >> >   href="/KungleNext-0.1-SNAPSHOT/css/kungleNext.css" />
>>
>> >> > The same application deployed under tomcat produces this buggy
>> >> > reference:
>>
>> >> > > >> >   href="/css/kungleNext.css" />
>>
>> >> > My snippet defines the ling as follows:
>>
>> >> > ...
>> >> > > >> > media="screen" />
>> >> > ..
>>
>> >> --http://pmonnaie.blogspot.com/
>>
>> --http://pmonnaie.blogspot.com/
>
> >
>



-- 
http://pmonnaie.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: Bug in MappedEmail: emailPattern is wrong

2009-08-27 Thread Viktor Klang
On Thu, Aug 27, 2009 at 10:27 AM, Marc Boschma

> wrote:

> Personally I use:
>
>
> "^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$"
>

Impressive!

It still doesn't tell you if the email is real or not ;)


>
> Marc
>
> On 27/08/2009, at 9:32 AM, David Pollak wrote:
>
> Thanks.
>
> Changed and pushed to GitHub.  Allow 2 hours for Maven availability.
>
> On Wed, Aug 26, 2009 at 4:15 PM, harryh  wrote:
>
>>
>> > What's the change to the RegEx?
>>
>> val emailPattern = Pattern.compile("^[a-z0-9._%-+]+@(?:[a-z0-9-]+\\.)+
>> [a-z]{2,4}$")
>>
>> note the addition of the + to the allowed characters before the @
>>
>> -harryh
>>
>>
>
>
> --
> 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
>
>
>
>
>
> >
>


-- 
Viktor Klang

Blog: klangism.blogspot.com
Twttr: viktorklang

Lift Committer - liftweb.com
AKKA Committer - akkasource.org
Cassidy - github.com/viktorklang/Cassidy.git
SoftPub founder: http://groups.google.com/group/softpub

--~--~-~--~~~---~--~~
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] about QueryParams

2009-08-27 Thread XiaomingZheng

there are two kinds of QueryParams in Lift, one uses raw sql clauses
and the other not. My question is, when using the raw sql clauses, the
security must be checked by programmer self, and declare safety by
IHaveValidatedThisSQL, but when using the now raw methods, does Lift
framework checks safety for us?

--~--~-~--~~~---~--~~
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] error in http authetication and openid

2009-08-27 Thread iboy

Hi all
i am new to scala and lift.
while trying to do a sample project i tried to use httpauthentication
code given in liftbook (7.14 authentication example) and i am getting
following errors

a) while using import auth._

 error: value auth not found
if i try using  _root_.net.liftweb.http.auth._
i get
  error: value auth is not a member of package net.liftweb.http
import _root_.net.liftweb.http.auth._


any help is appreciated

i am using  scala 2.7.3 final and maven 2.0.9

--~--~-~--~~~---~--~~
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: error in http authetication and openid

2009-08-27 Thread Timothy Perrett


Please check:

http://is.gd/2BwGf

Can you check your code looks like that and if your still getting the
problem?

Cheers, Tim

On 27/08/2009 11:34, "iboy"  wrote:

> 
> Hi all
> i am new to scala and lift.
> while trying to do a sample project i tried to use httpauthentication
> code given in liftbook (7.14 authentication example) and i am getting
> following errors
> 
> a) while using import auth._
> 
>  error: value auth not found
> if i try using  _root_.net.liftweb.http.auth._
> i get
>   error: value auth is not a member of package net.liftweb.http
> import _root_.net.liftweb.http.auth._
> 
> 
> any help is appreciated
> 
> i am using  scala 2.7.3 final and maven 2.0.9
> 
> > 
> 



--~--~-~--~~~---~--~~
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: Bug in MappedEmail: emailPattern is wrong

2009-08-27 Thread Marc Boschma
Your right... I've been thinking about that and how the current mapper  
only does the regex check.. could always override the validate method...

Marc
On 27/08/2009, at 6:39 PM, Viktor Klang wrote:

>
>
> On Thu, Aug 27, 2009 at 10:27 AM, Marc Boschma  > wrote:
> Personally I use:
>
> "^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-] 
> +)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01- 
> \x09\x0b\x0c\x0e-\x7f])*")@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a- 
> z0-9](?:[a-z0-9-]*[a-z0-9])?$"
>
> Impressive!
>
> It still doesn't tell you if the email is real or not ;)
>
>
> Marc
>
> On 27/08/2009, at 9:32 AM, David Pollak wrote:
>
>> Thanks.
>>
>> Changed and pushed to GitHub.  Allow 2 hours for Maven availability.
>>
>> On Wed, Aug 26, 2009 at 4:15 PM, harryh  wrote:
>>
>> > What's the change to the RegEx?
>>
>> val emailPattern = Pattern.compile("^[a-z0-9._%-+]+@(?:[a-z0-9-]+\ 
>> \.)+
>> [a-z]{2,4}$")
>>
>> note the addition of the + to the allowed characters before the @
>>
>> -harryh
>>
>>
>>
>>
>> -- 
>> 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
>>
>>
>>
>
>
>
>
>
>
> -- 
> Viktor Klang
>
> Blog: klangism.blogspot.com
> Twttr: viktorklang
>
> Lift Committer - liftweb.com
> AKKA Committer - akkasource.org
> Cassidy - github.com/viktorklang/Cassidy.git
> SoftPub founder: http://groups.google.com/group/softpub
>
> >


--~--~-~--~~~---~--~~
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] Ajax in ToDo application hanging

2009-08-27 Thread Dorinel

I was implementing application from 
http://liftweb.net/docs/getting_started/mod_master.html
By the way,it's a great tutorial for lift much better than those which
were before and it explains a lot of things in comments clearly, thank
you for creating it.

But when I left the todo application for about 2-3 hours, the ajax
which allows editing of the ToDo items stopped working. When I click
on checkbox it doesn't resort all items, the same it doesn't resort
(or redraw) when I'm changing priority from dropdown menu. Also when I
click desc to edit it - I can edit it but the result is not saved and
it doesn't exit edit mode when I'm editing another item.
When I do some actions, like checking a checkbox it seems that on
server side I have new rows like these:
INFO - Service request (POST) /ajax_request/F17795011372L0I/ took 1
Milliseconds

Ajax starts working when I'm adding new todo item (because page
reloads) or I'm logging of and on.

I've replicated this bug by leaving todo application running for night
and it was the same ajax not working when I wake up.

Is this a known bug, or I have done something wrong when I typed ToDo
application from tutorial?

--~--~-~--~~~---~--~~
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] some questions on lift

2009-08-27 Thread surfman

I am totally new and interested in scala & lift. what I have is a
little Java knowledge. Aftering reading to-do application at the
website, I got the following questions:

1) where and how to setup database? the tutorial never mentions
database setup,

2) how does lift support database migration? the tutorial says to use
Schemifier, but what I am thinking is if I remove a column, merge db
columns, etc. how does lift handle? or, where may I find such
instructiion?

3) internationalization support. how does lift support this?

4) how does lift compare to Grails?  I have some experience on Grails.
Developer may build an app in a extremely fast way. but, lift looks
not as fast as Grails. The speed I mentioned is not app performance, I
am talking about speed to build an app.

Forgive me if above questions are dummies. but it is really helpful
for a real beginner like me. Thanks for any help on these questions.

--~--~-~--~~~---~--~~
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: about QueryParams

2009-08-27 Thread David Pollak
On Thu, Aug 27, 2009 at 2:12 AM, XiaomingZheng wrote:

>
> there are two kinds of QueryParams in Lift, one uses raw sql clauses
> and the other not. My question is, when using the raw sql clauses, the
> security must be checked by programmer self, and declare safety by
> IHaveValidatedThisSQL, but when using the now raw methods, does Lift
> framework checks safety for us?


These queries use prepared statements and uses setString/setInt/etc. to set
each of the parameters.  This means that SQL injection attacks are
impossible unless there is a bug in the underlying JDBC driver.

When you create your own String for a query and do some thing like:

"select * from foo where name = '"+name+"'", you've created a huge SQL
injection hole.  If someone entered their name as "fred' or id = 33 or name
= 'fred" then they could fish for record 33.  If the query is built using
By() (e.g., By(Foo.name, name)), then no matter what the name, you're not
going to get an SQL injection attack.


>
>
> >
>


-- 
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: some questions on lift

2009-08-27 Thread marius d.

Tim has a magic articles bag :)

On Aug 27, 4:20 pm, Timothy Perrett  wrote:
> Checkout my article here on how to localize with Lift:  http://is.gd/1NXGN
>
> Cheers, Tim
>
> On 27/08/2009 14:08, "surfman"  wrote:
>
> > 3) internationalization support. how does lift support this?
--~--~-~--~~~---~--~~
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: some questions on lift

2009-08-27 Thread Timothy Perrett

Checkout my article here on how to localize with Lift:  http://is.gd/1NXGN

Cheers, Tim

On 27/08/2009 14:08, "surfman"  wrote:

> 3) internationalization support. how does lift support this?



--~--~-~--~~~---~--~~
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: 1.1-SNAPSHOT issue?

2009-08-27 Thread David Pollak
Thanks.  Added a test.  Lift failed the test.  Fixed Lift.  Pushed the
source to GitHub.

On Thu, Aug 27, 2009 at 12:15 AM, E. Biggs  wrote:

>
> Ok here's the problem stripped down. The merge happens but the 
> node isn't being removed from the body
> Let me know if you'd like it in some other format.
>
> templates-hidden/outer.html:
>
> 
>  
>  
>  
>  
>
>  
> 
>
>
> inner.html:
>
> 
>  
>Inner
>  
> 
>
> renders:
>
> 
>  www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
> 
> 
>  
>
>
> Inner
>
>
>  script>
> 
> 
>
>  
>Inner
>  
>
>
>
>