Discussion Forums  >  Plugins, Customizing, Source Code

Replies: 8    Views: 82

iulianh
Apple Fan
Profile
Posts: 27
Reg: Feb 24, 2014
Suceava
270
02/24/14 07:08 AM (10 years ago)

read infomations to app from mysql database

Hello, I'm interested to know if is possible to read information's from mysql database and display them in the app Can anyone help me with that? Thank you
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
02/24/14 07:56 AM (10 years ago)
Definitely possible. You'll need to create a script (php, etc) on your server where the database is held to read the data and convert it to Json.
 
iulianh
Apple Fan
Profile
Posts: 27
Reg: Feb 24, 2014
Suceava
270
like
02/24/14 08:00 AM (10 years ago)
And what plugin should I use to read the Json from my website? Thank you for your reply!
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
02/24/14 08:16 AM (10 years ago)
Any of them. All plugins use Json for their configuration. It depends on what data you're trying to access and how you want it to be displayed. Likely you'll want a menu plugin. You'll want to pay attention to how the plugin is using Json so you can format your data accordingly.
 
iulianh
Apple Fan
Profile
Posts: 27
Reg: Feb 24, 2014
Suceava
270
like
02/24/14 08:28 AM (10 years ago)
Can you please tell me where do I need to put in the plugin the address link to my website with json? Can you please give me more details! One example will be very appreciated! Thank you very much
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
02/24/14 08:41 AM (10 years ago)
Unfortunately I'm on my phone right now so I can't give an example. But you would use the dataURL property to point to your website. If you look at the readme for the menu simple plugin, you'll see an example of what the script output should look like for that plugin.
 
iulianh
Apple Fan
Profile
Posts: 27
Reg: Feb 24, 2014
Suceava
270
like
02/24/14 08:44 AM (10 years ago)
and where do I need to make this changes? In xcode? if yes then in what files from there?
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
02/24/14 08:49 AM (10 years ago)
Nope - on the control panel. There's a property called dataURL that takes a URL as the value. The source code in XCode is already setup to handle it. If you're using a plugin that doesn't have that property on the control panel then yes, you would need to do some code manipulation. I think all menu plugins have the property though.
 
iulianh
Apple Fan
Profile
Posts: 27
Reg: Feb 24, 2014
Suceava
270
like
02/24/14 08:51 AM (10 years ago)
thank you very much for your information! I will investigate this more!
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.