Author: Ayush Mishra

Scala LiftWeb: Upload File using AJAX

Liftweb provides AJAX functionality for all html elements except file upload using Scala . But there is a way to upload file using AJAX by binding form as AJAX form . 1) add below lines in your html . <div class="lift:FileSnippet.uploadFile"> Upload File : <input name="upload" type="file"></input> <input type="submit" name="submit" value="Upload"/> </div> 2) class FileSnippet { def uploadFile(form: NodeSeq): NodeSeq = { def handleFile():JsCmd = Continue Reading

Play With Liftweb’s AJAX Generators using Scala

AJAX is an approach for building dynamic web content on the client side . In Liftweb , we can implement this approach either by AJAX or by Comet . Comet is like AJAX , except in opposite direction . AJAX model increases the richness of the User Experience for a single client at a time, Comet can do the same for multiple users. First thing Continue Reading

Scala Liftweb : Use Forgot Password Inbuilt Functionality to send Email with Unique Token

If you are implementing Forgot password functionality in your web application using Liftweb and you have such a scenario where you have to send redirect URL with unique token in Email , Liftweb with Scala provides a wonderful functionality to handle this . 1) Write a function to send URL with unique token in Email . def sendLoginToken(user: User): Unit = { import net.liftweb.util.Mailer._ val Continue Reading

Play with Lift’s Autocomplete Widget using Scala-One of the Best Feature of LiftWeb Framework

The AutoComplete widget provides a flexible and accessible way to offer suggestions or some kind of filtering information as a user type text information in an input field . If you have used Google , you might see that Google starts providing autocomplete suggestion with entries depending on user’s current input . Lift provides a very easy way to implement Autocomplete using Scala . Here Continue Reading

Re Render HTML Template using Scala and Lift

In this section , I will explain how to re-render HTML Template without loading the browser . You can refresh HTML template without loading browser via AJAX using Scala and Ltft . Lift provides SHtml.memoize which memoize the NodeSeq used in apply() and then call applyAgain() in an Ajax call . You can re render a particular template part of HTML page or complete page Continue Reading

Providing a “Sign-in with Facebook” functionality using Scala

Recently we have integrated “Sign in with Facebook ” functionality in one of our social project that we are building with Lift 2.4 . This post summarizes the work done step by step. 1) Create a Facebook App (if you do not have one already) Follow the link https://developers.facebook.com/apps and create an app. Enter all the details including Site URL . The Site URL could Continue Reading

Knoldus Pune Careers - Hiring Freshers

Get a head start on your career at Knoldus. Join us!