نمونه برنامه پایتون
برنامه ای نوشتم که آدرس یک سایت رو بگیره و آی پی سایت رو نمایش بده. خیلی ساده (البته گرافیکی* #پایتون )#Code By Saeed Damghanian#Software Engineer from Semnanimport os, socketimport tkinter as tkfrom tkinter import fontdef response(a): b = socket.gethostbyname(a) c = "\n \n \nProgrammer: Saeed Damghanian\nWebsPyschool.blog.ir\nWant to Join our Telegram Channel? >> t.me/ghoghnous_iran" return b + cdef do(a): label['text'] = response(a)root = tk.Tk()root.title('Get Website Ip')canvas = tk.Canvas(root, height=500, width=600)canvas.pack()#background_image1 = tk.PhotoImage(file='bg.png')#background_label =tk.Label(root, image=background_image1)#background_label.place(relwidth=1, relheight=1)frame = tk.Frame(root, bg='#C02F11', bd=5)frame.place(relx=0.5, rely=0.1, relwidth=0.75, relheight=0.1, anchor='n')entry = tk.Entry(frame, font=('Modern', 15))entry.insert(0, 'Website URL')entry.place(relwidth=0.65, relheight=1)button = tk.Button(frame, text='Get IP', bd=0, bg='white', fg='#098f00', font=60, command=lambda:do(entry.get()))button.place(relx=0.7, relheight=1,...
تاریخ 09 اسفند 1399