Fix in app.js for multiple layout support and ensure that serialize is update

Two little fix:
 * Check that the layout is not changed from last call 

    See JSFiddle provided by @mrgamer on bug #165
 * If the layout is not update ensure to pass also the serialize options