Hydrotronics

Mail

Aug 17th, 2016
177
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.59 KB | None | 0 0
  1. fs.makeDir('/CCMail')
  2. function input(prompt)
  3.                 print(prompt)
  4.                 entered = io.read()
  5.                 term.clear()
  6.                 term.setCursorPos(1,1)
  7.                 return textutils.urlEncode(entered)
  8. end
  9. from = input('Who are you?')
  10. file = fs.open('/CCMail/'..from, 'w')
  11. print(http.post('http://shoalnet.org:4567/', 'from='..from..'&to='..input('Who are you sending a message to?')..'&message='..input('What would you like to say?')).readAll())
  12. file.write(http.post('http://shoalnet.org:4567/', 'from='..from..'&to=checkmail&message=').readAll())
  13. file.close()
Advertisement
Add Comment
Please, Sign In to add comment