Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html>
- <head>
- <base target="_top">
- </head>
- <body>
- <div style="background:#f2f2f2;margin: 20px auto;width:996px;font-family:Verdana;line-height:1.5em;border:2px solid #eee;padding:20px;box-shadow:1px 2px 3px #eee;color:#333">
- <h1>Welcome Developer</h1>
- <h4>Instructions</h4>
- <p class="alert alert-success" style="border: 1px solid green">
- You have 2 hours to complete this test. Make a copy of this Script and Name it "Internal JS Quiz email@gmail.com".
- Use the 'Publish' option from the script editor menu to deploy the app. Once deployed the app can be tested from the same menu.
- </p>
- <p>
- In order to complete this test successfully, you need to create 2 input fields (Username and Password) and a button to submit the data.
- Then everytime a user enters username and password and clicks the button, the data has to be logged into a spreadsheet. A timestamp must also be logged and the user email address.
- </p>
- <p style="color:red;font-weight:bolder">Once you have finished part 2, share it with <a href="https://gmail.com" target="_blank">innovation.arvato@gmail.com</a> so we can review it. Thanks and good luck!</p>
- <p>
- <strong>Hint 1:</strong> <a href ="https://developers.google.com/apps-script/guides/html/reference/run#withSuccessHandler(Function)" target="_blank"> google.script.run.withSuccessHandler()</a> is your friend.<br>
- <strong>Hint 2:</strong> Session.getActiveUser().getEmail() returns the email of current user (.gs code).<br>
- <strong>Hint 3:</strong> HTMLService has native ways to talk to backend function in the .gs file.<br>
- <strong>Hint 4:</strong> The app should be deployed or updated when a new service is called within the app to enable access to that service.
- </p>
- </div>
- <hr>
- <h3>Start Here:</h3>
- <!--ENTER YOUR CODE BELOW THIS POINT-->
- <label>Username: </label>
- <input type="text" name="username"><br>
- <label>Password: </label>
- <input type="password" name="password"><br>
- <button id="main_button" onClick="google.script.run(test)">Alert</button>
- <label>Hello</label>
- <!--THIS IS THE END OF YOUR CODE-->
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement