Created
April 29, 2012 13:43
-
-
Save tufanbarisyildirim/2550506 to your computer and use it in GitHub Desktop.
titanium
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Titanium.UI.setBackgroundColor('#000'); | |
var win = Titanium.UI.createWindow({ | |
title:'Query7 RSS Feed', | |
backgroundColor:'#000' | |
}); | |
var data = []; | |
// create table view | |
var tableview = Titanium.UI.createTableView({ | |
data:data, | |
headerTitle: 'Query7 RSS', | |
backgroundColor:'#000' | |
}); | |
win.add(tableview); | |
var xhr = Titanium.Network.createHTTPClient(); | |
xhr.onload = function() | |
{ | |
try | |
{ | |
alert(this.responseText); | |
var parser=new DOMParser(); | |
var xmlDoc=parser.parseFromString(this.responseText,"text/html"); | |
alert(xmlDoc.documentGetElementById('content').innerText); | |
//var doc = this.responseXML.documentElement; | |
// var haber_metni = doc.getElementById('content').text; | |
// alert(haber_metni); | |
} | |
catch(E) | |
{ | |
alert(E); | |
} | |
}; | |
xhr.open('GET', 'http://www.tufyta.com/sunum-phpyi-birakmak-icin-50-sebep'); | |
xhr.send(); | |
win.open(); |
arkadaşa kod gönderirken burası geldi aklıma (: pastebin gibi kullandım. Titanium ile ornek rss readerdi ilk versiyonlarda, şimdi ne bilmiyorum tabi.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
kaptan bu ne?