# -*- coding: utf-8 -*- # baglanti alma uygulaması... from PyQt4 import QtGui, QtCore import urllib2 import re class pencere(QtGui.QMainWindow): def __init__(self): QtGui.QMainWindow.__init__(self) self.setWindowTitle(u"Bağlantı Alıcı...") self.resize(600, 445) self.adres = QtGui.QLineEdit(self) self.adres.resize(250, 30) self.adres.show() / self.button = QtGui.QPushButton(self) self.button.setText(u"Al...") self.button.move(260, 2) self.button.show() self.liste = QtGui.QListWidget(self) self.liste.move(2, 30) self.liste.resize(590, 389) self.liste.show() self.connect(self.button, QtCore.SIGNAL("clicked(bool)"), self.al) def al(self): adres = str(self.adres.text()) if adres[0:7] != "http://": adres = "http://" + adres html = urllib2.urlopen(adres).read() baglantilar = re.findall("", html) for i in baglantilar: if "?" in i: i = i + " (get)" self.liste.addItem(i) app = QtGui.QApplication([]) p = pencere() p.show() app.exec_()