Discussion Forums  >  Config Data, JSON, App Refresh

Replies: 5    Views: 107

dlessa
I hate code!
Profile
Posts: 21
Reg: Jan 11, 2013
Montevideo
3,160
01/16/13 05:50 AM (11 years ago)

Config Data to generate dynamic menu items

I was trying to dynamically generate the file but saw BT-server.txt that is generated by a query. I wish I could generate the menu items dynamically with php (for example), this is really possible? Sorry for my "english" my native lenguage is spanish. Thanks..
 
Kahuna
Apple Fan
Profile
Posts: 137
Reg: Nov 18, 2011
Milan
4,670
like
01/16/13 06:04 AM (11 years ago)
I use dropbox for my menu items because I don't want to manually enter each row in the BT control panel. You could pull the menu items from your server that dynamically create the file and generates a JSON file which will be used by your app.
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
01/16/13 06:06 AM (11 years ago)
Yes you can. Many people use PHP and MySQL to power their applications. I'm working on that right now, in fact. Just make sure your SQL Database output is JSON encoded. I put a sample PHP Script in my dropbox. It's basic, but you can alter it for your needs. https://dl.dropbox.com/u/115208762/CheesySQL.txt Cheers! -- Smug
 
dlessa
I hate code!
Profile
Posts: 21
Reg: Jan 11, 2013
Montevideo
3,160
like
01/16/13 06:13 AM (11 years ago)
Thank you very much! I just wanted to know if it`s possible using php and msql, I'll try, thanks again!
 
dlessa
I hate code!
Profile
Posts: 21
Reg: Jan 11, 2013
Montevideo
3,160
like
01/16/13 06:32 AM (11 years ago)
Another problem I have: The application is going to find the old file: http://www.mydomain.com/BT-server/api/app/?command=getAppData&appGuid=XXXXXXX&apiKey=XXXXXXXX&apiSecret=XXXXXXX When i refresh the menu item once I load the custom menu from: http://www.mydomain.com/BT-server/myscript.php and when reload the menu item goes to: http://www.mydomain.com/BT-server/api/app/?command=getAppData&appGuid=XXXXXXX&apiKey=XXXXXXXX&apiSecret=XXXXXXX I need to change the Configuration Data URL somewhere else? thanks
 
dlessa
I hate code!
Profile
Posts: 21
Reg: Jan 11, 2013
Montevideo
3,160
like
01/16/13 06:45 AM (11 years ago)
I just found the error, y leave the old dataURL un script :S, sorry!
 

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.