Hi, I am new to Corona and I am stuck and require assistance. I have created a text box and I would like an image to appear when a member types something specific into the text box. I was working with functions and the if and then statements but I am stuck on exactly how to properly phrase it. I have included a same of my code. Any help you can provide would be greatly appreciated, thank you.
function txtFirstName: userInput (event)
if event.phase == “submitted” then
event.target.text = “jake”
local bg2 = display.newImageRect ( “images/jake.png”, 100,100 )
bg2.x = 730
bg2.y = 332
bg2: scale (.3, .3)
bg2.rotation = 6
end
end