Advertisement
Guest User

Untitled

a guest
Jun 16th, 2017
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
IDL 0.48 KB | None | 0 0
  1. proc tastebin::http_complite { T HISTORY LANG token } {
  2.     variable options
  3.    
  4.     if { [http::status $token] ne "ok" } {
  5.         $T configure -state normal
  6.         $T delete 0.0 end
  7.         $T insert 0.0 "Error"
  8.         return [http::cleanup $token]
  9.     }
  10.    
  11.     set data [http::data $token]
  12.    
  13.     $T configure -state normal
  14.     $T delete 0.0 end
  15.     $T insert 0.0 $data
  16.    
  17.     http::cleanup $token
  18.    
  19.     set HISTORY "[get_time]\t$LANG - ${data}:\n\n$HISTORY\
  20.         \n...\n[string repeat _ 20]\n\n"
  21.    
  22.     add_history $HISTORY
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement