Community Questions & Answers
Event controller in different .js when event is declared by XML
Hi guys! I have this situation: *index.xml*: ~~~ <Alloy> <Window> <Require id="iconGroupAlfa" src="iconGroupToken" /> <Require id="iconGroupBeta" src="iconGroupToken" /> <Require...
xmlrpc
Below is an extremely simple xmlrpc client. This does not support multicalls or any other fancy functionality. This simply gives you the bare bones functionality. I'm posting this here not as a question but simply as a reference and as a ploy to coax the...
Trouble accessing elements of a XML doc.
Hi people: I need some help because I don't know how to manage this XML document. This is the response from one webservice, I need to show some of its elements into a window but... This is the structure of my...
Alloy: How to set font family inline to the xml
In tss it will be: ` font: { fontSize: "19dp", fontFamily:"monospace" }` How to put it in xml? `<Label font="fontFamily:'monospace'">Monospace</Label>` ?
Webservice, XML Response Request, onreadystatechange
###Hello there, ###since a few days i have a problem and i have no idea remaining. Please help! ###I want to send a xml request and become a xml response. ###Then i want to read some information out of the xml response. ### create xml ~~~ ...
HttpClient request Not work for iPhone
Hello Friend, From last coupele of days i stuck in an issue. For my app i need to call an API. I make Http request it works fine for Android and not for iPhone. Here is the code :- ~~~ var addrReq =...
Alloy conditional (if) statements in XML templates
How do I use if statements / conditionals in the Alloy XML templates? And if they don't exist, what are the best ways of substituting this?
Titanium.Network.HTTPClient: mixed upload (file and xml)
Hi, I know:withxhr I can POST and GET datas. In my project I have to upload a file and in the same request a XML (Mulitipart). How can I realize this? Best regards Rainer
Loop through a Json File ?!
Hey Guys, i have tried several things, but i just can't get it work... I wanna loop through my json data with a recursiv function. I've uploaded an example to my webserver. Help would be so much awesome. my mind is totally fucked by that stuff...
fail to load xml from webserver on local network
I am trying to load an xml file from the local network. The file is hosted on a windows web server. I can view the file in a browser on the network. Here is the code I am using: ~~~ var url = "192.168.0.199/application/cmn/current-sink.xml"; var...
How to parse XML on mobile web
Hello, I need to parse an .xml file. I tried it using following code. On Android/iPhone works just fine, but when I try it on a mobile web it doesn't work. I'm getting a parse error and Titanium.XML.Document is empty... How can I parse the .xml file to...
Alloy Collection from local XML file
Hi, I want to load a local XML file. The file contains a few models like ~~~ <models> <model> <name>A</name> </model> <model> <name>B</name> ...
RSS Feed - ATOM - NullPointerException
Can someone please look at the following code and tell me what is wrong? Every time I run it, I get a NullPointerException error when I try to display a data row. I get the data, see how many rows there are, but I can't display it. ~~~ var url =...
Parse and xml to an array
Hey people! I need some help. I must parse an online XML document and put the elements of each item in an array. I'm trying to do it but when i do `data.length();` it is 0. ~~~ function parsear() { var data = []; var xhr =...
Count the amount of child nodes in an XML node
I am trying to find the amount of child nodes in the node "page". Then loop through them and get the values to display some content on my app. I can't for the life of me figure it out though... ~~~ <?xml version="1.0"...
Parsing XML and display data with Alloy
my witch is to get data from xml file ( parse xml ) and display them as news feed with alloy on android like that [for example](http://insidefacebook.com/wp-content/uploads/2008/07/newsfeed.jpg) This what a i do till now...
sqLite or XML
We are building a content managed app that downloads a lot of data as XML for the apps pages from a server... Would it lead to a better performance, to read the XML and store it in a database and then query the database for the relevant data, or just read...
Alloy XML Views - Passing Through Parents' Arguments to Widget as an Attribute Argument
Is it possible to pass through arguments that were passed to a view from within the XML view to a widget? ~~~ <Widget id="test" src="SomeWidget" args="arguments" /> ~~~ Would be parsed by Alloy...
How to select value in input field with alloy?
Hello .. I'm trying to know how can i a get the value in my input field to be put into my post statement to be sent to my php file .. ~~~ Views : <Alloy> <Window class="container"> <Label...
Break in string from xml?
Hey, i am pulling some text stuff from xml (localization) everything works fine - except the breaks :/ In my XML strings there is (for example) <string name="hello_world_text">Hello \n World</string> If i write this stuff...
How to preferences.xml dynamic list?
There is some way to make a preferences XML where the user would be able to add/remove from a list of things? ie. On option on the preferences where the user can add/remove contacts. So when he open that option he will see a list of contacs he added...
How to open a file dialog within preferences.xml?
How can I male a preferences XML where the user will be presented with his default file browser to choose a file when clicking over an option in the preferences screen?
bug in xml on blackberry
i am coming from this sample [http://docs.appcelerator.com/titanium/3.0/#!/guide/Working_with_XML_Data] and it works well on ios but i found bugs on bb10 error message 'TypeError: Cannot read property 'documentElement' of undefined '
Best way to import / export a CSV or XML
Hi, I have a desktop application and use the titanium database to store and read some data. What is the best way to import or export csv and xml files from or to the titanium database? With best way i mean no hanging while importing or exporting the data...
Retrieving local xml data
Hi I want to retrieve local xml data this is the fomat of xml data ~~~ <?xml version="1.0" encoding="utf-8"?> <database> <category> Asistir a misa todos los Domingos y fiestas de guardar. 1 <item>He usado...
Create XML Document using Ti.XML.DOMImplementation [error]
Hi, I'm trying to create an XML Document in Titanium Appcelerator (mobile). In the API references there's ...
XML Document Builder
Hello there, I want to generate XML document from data. In API doc, they have given Titanium.XML.DocumentImplementation.createDocument method. But while using it in my Application, it gives error, Can anyone help me with any example?
How to call method using WCF Service ?
Hi all, I am trying to call WCF Service in my project. Just i want to call GetAddition Method and GetImage Method. Please someone help to me. Below is the code ~~~ var win = Titanium.UI.createWindow(); win.backgroundColor = '#ffffff'; var xhr =...
Need help with Alloy - Cannot get Require to work in XML and controller
Hi, I am trying to create a Banner View using Alloy, it work fine on the first tab window of my application, but somehow doesn't show on the other windows. Here's what my code looks like: promotionWindow.xml ~~~ <Alloy> <Window...
Alloy template namespaces for custom modules
What is the syntax for including custom module views in Alloy XML templates? I've tried ~~~ <View ns="com.foo.bar"/> ~~~ where `com.foo.bar` is the module ID as defined in tiapp.xml, but it doesnt find it. Do I need to import the...
XML Parsing returns text nodes only on iOS
There appears to be a difference in parsing XML between Android and iOS Take the XML fragment below: ~~~ var xmlTest = '<LOGON_RESPONSE ID="0">' + ' <RESULT>ACK</RESULT>' + ' ...
Data directory not writable - device only
Hello all, I have some code below that downloads an xml file, saves it to applicationDataDirectory and then parses and saves down the images listed in the xml. I then have a menu built by parsing the xml that should be saved. On the simulator this works...
xml parsing label <response></ response>
~~~ <response success="1" message="OK" userAccesskey="a28bbda6f0e544537abe5ee9811d33ad"> <module ID="1" name="Authentication"> <action ID="1"...
No code is executed after calling `.text` on a XML node
Hello, When trying to parse xml from an external source none of my code is executed after calling `.text` on a xml node. Code: ~~~ var farmers = this.responseXML.documentElement.getElementsByTagName("Farmer"); var data = []; ...
parser XML encoding='ISO-8859-1'
as I can parse an XML with the following code <? xml version = '1 .0 'encoding =' ISO-8859-1 '?>
Complete Alloy View XML Guide
While the office [Alloy XML Markup Guide](http://docs.appcelerator.com/titanium/latest/#!/guide/Alloy_XML_Markup-section-35621528_AlloyXMLMarkup-CollectionElement) is a good start, it is not complete enough for building more advanced interfaces. Is there...
XMLTools for rss feed
Use [XMLTools](https://github.com/dbankier/XMLTools-For-Appcelerator-Titanium) for parsing RSS. Everything is working fine, but [feed](http://habrahabr.ru/rss/best/) returns: ~~~ { channel = "\n\t"; version =...
Sort a TiDOMDocument
Is there any way to randomly sort a TiDOMDocument's elements or the underlying XML data? I've been stuck on this for days - while it's not difficult to convert the underlying data to an array and sort that way, it's not evident how to push that data back...
Fastest way to consume XML Web service
Hi all, I have an "SQL Anywhere" web service that returns data in XML format. So i want to parse this data and show it in a TableView. My code is working but when i pass a big number as parameter for the request, the TableView is too slow to...
Template in Alloy?
Hi! I have another problem...I would want to create an xml containing only a redefinition of LefNavButton and RightNavButton. That way, I do not have to reimplement the same component in all my views. For example : My classical view...
How to set child node attribute value of XML??
I have XML response. after change the value i want to save that attribute value. how it's possible???
Alloy: how to switch between windows in Alloy?
hi ! I have two window declared with alloy XML & tss, and would like to have window 1 push (like segue in iOS) to window 2 , this is what I have so far: ~~~ function switchToNextView (e){ var window = Ti.UI.createWindow({ url:...
Displaying data using a TableView
Hi, I am following the Titanium App Dev Cookbook and on chapter 2, there is a section called "Displaying data using a TableView" This is my code inside my `controllers/tab1.js` ~~~ //declare the http client object var xhr =...
Send XML Data to webservice
Hi guys, i have wrote a function in jquery and would like to use it with titanium. I studdied the httpclient api but havn't no luck. Can someone help me ? ~~~ var dataString =...
Storing and Removing Bookmarks
I'm still quite new to appcelerator and my javascript knowledge isn't that much either so please pardon my mistakes and misunderstandings if any. I'm making a RSS Feed Reader app for a website for example, BBC. I've been reading numerous questions and...
How do you dump the entire contents of a Ti.DomObject out
How do you dump the entire contents of a Ti.DomObject out to a file?
read information from SHOUTcast Radio Directory
hello to all i create a simple radio streaming whit titanium. I using shoutcast from shoutcast.com how using this metadata : http://wiki.winamp.com/wiki/SHOUTcast_XML_Metadata_Specification for specificatio why music it's in function now ?
Problem with display RSS data from blog rss feed
Ok I have few problems for RSS reading. I have managed to get the data from the blog. But it contains a lot of format text that I don't want to display but when i retrieve the data, it comes together with the text. The url i use is...
Language in chains
I am creating an app for androi and I leave the strings.xml declared i18n folder-> is, i18n-> in, use L ('label') but not caught, would know someone that may be devido thanks
How to parse this XML? Is there any third party js like simple-xml.jar is used for make StringToXML and XMLToString??
<Questions> <Question commentType="0" count="0" defination="testing" idQuestion="18" mandatory="true" sorted="false"> <QuestionType idQueType="2" type="2"...