Tagged: LiftWeb RSS

  • Tyler 12:50 pm on July 6, 2009 Permalink
    Tags: , , LiftWeb   

    I wrote a friggin book:

    I wrote a friggin book

     
    • J 9:56 pm on July 6, 2009 Permalink

      very nice! beat me to it!

    • drew 8:38 pm on July 13, 2009 Permalink

      Dude, that’s pretty much the coolest thing I’ve ever seen. I’ve always wanted to write a book. Congrats!

  • Tyler 1:54 pm on March 20, 2009 Permalink
    Tags: , LiftWeb,   

    Exploring Lift: Scala-based Web Framework 

    Lift is an exciting new framework that leverages the Scala programming language to offer an innovative approach to creating web applications. Lift provides enormous flexibility and functionality while keeping your code simple.

    Exploring Lift is brought to you by Derek Chen-Becker, Marius Danciu, and Tyler Weir, three committers on the Lift project. The book not only covers the fundamentals of building a comprehensive Lift-based application, but contains multiple chapters on advanced functionality such as AJAX, Comet and custom URL rewriting. Extensive code samples are given throughout the book to demonstrate practical application, and a complete demo app is built from the ground up to reinforce the information presented.
    What you’ll learn:

    • How to get a basic Lift application up and running quickly using Maven’s archetypes
    • How to generate and process forms, including file uploads
    • How to use the SiteMap framework to provide a custom site menu and programmatic access control to your application’s pages
    • Database access using Lift’s Mapper framework as well as how to integrate the Java Persistence Architecture
    • How to use custom URL rewriting and request dispatch to easily provide user-friendly URLs and powerful servlet-like functionality
    • How to easily internationalized (I18N) your application
    • And much more!

    Who this book is for?

    Anyone interested in getting the most out of their web applications and who appreciates the power and flexibility of the Scala programming language. A basic understanding of Scala is assumed, so if you’re not familiar with it we would suggest reading David Pollak’s excellent book, Beginning Scala.

    Reviews

    Lift was created by David Pollak, an industry veteran who has repeatedly pushed the boundaries of what is possible with programming. Here is what people are saying about Lift:

    “Lift is the only new framework in the last four years to offer fresh and innovative approaches to web development. It’s not just some incremental improvements over the status quo, it redefines the state of the art. If you are a web developer, you should learn Lift. Even if you don’t wind up using it everyday, it will change the way you approach web applications.”

    —Michael Galpin, Developer, eBay

    “Lift is an expressive and elegant framework for writing web applications. Lift stresses the importance of security, maintainability, scalability and performance, while allowing for high levels of developer productivity.”

    —Lee Mighdoll, CTO, Digiting, Inc.

     
  • Tyler 3:39 pm on February 26, 2009 Permalink
    Tags: , LiftWeb,   

    Lift 1.0 has been released! 

    Read Dave’s announcement and check out the site.

    Lift is an expressive elegant web framework based on the Scala programming language and released under an an Apache 2.0 license. Lift provides developers the best way to build interactive, high performance web applications. Lift based applications are deployed as WAR files into J2EE containers such as Jetty, Tomcat, and WebLogic. Lift based applications are high performance and can make use of your existing Java libraries.

     
  • Tyler 7:46 pm on April 22, 2008 Permalink
    Tags: , LiftWeb,   

    Getting my nerd on. 

    I will be attending ScalaLiftOff on Saturday May 10th, 2008 from 9am to 5pm.

    What’s ScalaLiftOff?

    The Scala lift off is a great place for members of the Scala and lift communities to get together, learn about Scala, learn about lift and get to know each other face to face. There will be Scala tracks going all day long and lift tracks to suits everyone’s interests.

     
  • Tyler 7:42 pm on April 15, 2008 Permalink
    Tags: , LiftWeb   

    New Lift App 

    Working on another /lift/ app for fun.
    itwasbetter

     
  • Tyler 3:03 pm on March 11, 2008 Permalink
    Tags: gravatars, , LiftWeb,   

    Gravatars and Liftweb. 

    Liftweb and Gravatars together at last.

    Here’s the snippet:
    package net.liftweb.example.snippet

    import net.liftweb.example.model._
    import scala.xml.{NodeSeq, Text, Group, Node, Elem}
    import net.liftweb.http._
    import net.liftweb.http.S
    import net.liftweb.mapper._
    import net.liftweb.http.S._
    import net.liftweb.util.Helpers._
    import net.liftweb.util._
    import java.util.Locale
    import net.liftweb.sitemap._
    import net.liftweb.sitemap.Loc._
    import java.security._

    // gravatar_id - MD5 sum of your email address
    // size - image size
    // rating - rating of the image, let's start with "G" which is also the default

    class Gravatar {
    val theUser: User = User.currentUser.openOr(new User)

    private def getMD5(s: String): String = {
    val m = MessageDigest.getInstance("MD5")
    m.update(s.getBytes(),0,s.length())
    BigInt(1,m.digest()).toString(16)
    }

    def getGravatar(xhtml: NodeSeq): NodeSeq = {
    var src = "http://www.gravatar.com/avatar.php?gravatar_id=" + getMD5(S.attr("e").openOr(theUser.email))
    src = src + "&size=" + S.attr("s").openOr("42")
    src = src + "&rating=" + S.attr("r").openOr("G")

    <img src={src}/>
    }

    And here’s how to use it in your templates:

    <lift :Gravatar.getGravatar e="email address" s="80" r="G" />

     
  • Tyler 10:08 pm on January 29, 2008 Permalink
    Tags: blueprintCSS, , LiftWeb   

    Lift and BlueprintCSS 

    I mooshed BluePrintCSS into /lift/ as you can see here:
    lift + blueprintCSS

    It was ridiculously easy using this tutorial.

     
  • Tyler 2:05 pm on November 24, 2007 Permalink
    Tags: , LiftWeb, mysql,   

    Using MySql with Lift 

    I need to use MySQL with my Lift webapp and here’s how I did it. In Boot.scala I replaced the Derby DBVendor object with a MySQL object. Hope that helps.

    Add this to your pom.xml:

            <dependency>
              <groupid>mysql</groupid>
              <artifactid>mysql-connector-java</artifactid>
              <version>5.0.41</version>
            </dependency>
    

    object DBVendor extends ConnectionManager {
    def newConnection(name: ConnectionIdentifier): Can[Connection] = {
    try
    {
    Class.forName("com.mysql.jdbc.Driver")
    val dm = DriverManager.getConnection("jdbc:mysql://localhost:3306/database_name", "user", "password")
    Full(dm)
    }
    catch
    {
    case e : Exception => e.printStackTrace; Empty
    }
    }
    def releaseConnection(conn: Connection)
    {
    conn.close
    }
    }

    Next up is learning how to set up my domain objects properly.

     
c
compose new post
j
next post/next comment
k
previous post/previous comment
r
reply
e
edit
o
show/hide comments
t
go to top
l
go to login
h
show/hide help
shift + esc
cancel