Guest User

Untitled

a guest
May 23rd, 2018
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.11 KB | None | 0 0
  1. titlenew_txt.text = _global.curtitletext;
  2. connew_txt.text = _global.curcontext;
  3. loader_mc._visible = false;
  4. titlenew_txt.onChanged = function() {
  5. _global.curtitletext = this.text;
  6. };
  7. connew_txt.onChanged = function() {
  8. _global.curcontext = this.text;
  9. };
  10. save_btn.onRelease = function() {
  11. if (connew_txt.text != "") {
  12. loader_mc._visible = true;
  13. var sendtextldr:LoadVars = new LoadVars();
  14. sendtextldr.ownerid = _root.ownerid;
  15. sendtextldr.userid = _root.viewerid;
  16. sendtextldr.title = titlenew_txt.text;
  17. sendtextldr.text = connew_txt.text;
  18. if (titlenew_txt.text == "") {
  19. sendtextldr.addtext = "1";
  20. } else {
  21. sendtextldr.addtext = "0";
  22. }
  23. sendtextldr.sendAndLoad("write.php",sendtextldr,"POST");
  24. sendtextldr.onLoad = function(success) {
  25. loader_mc._visible = false;
  26. if (success) {
  27. titlenew_txt.text = connew_txt.text=_global.curtitletext=_global.curcontext="";
  28. msg_mc.msgtext_mc.msg_txt.text="indlæg gemt";
  29. msg_mc.gotoAndPlay(2);
  30. }else{
  31. msg_mc.msgtext_mc.msg_txt.text="fejl";
  32. msg_mc.gotoAndPlay(2);
  33. }
  34. };
  35. }else{
  36. warn_mc.gotoAndPlay(2);
  37. }
  38. };
Add Comment
Please, Sign In to add comment