Discussion Forums  >  Config Data, JSON, App Refresh

Replies: 3    Views: 196

Deletion
Aspiring developer
Profile
Posts: 25
Reg: May 13, 2013
London
6,250
07/23/13 05:59 AM (10 years ago)

Editing Config Data

I tried to edit the JSON code in my configuration data on my self hosted buzztouch control panel. I can make the changes to the code and reload my app in the simulator and the changes take place. Once I leave the configuration data page and come back the changes are reverted back to what they were and as soon as I update the app it goes back to the original behaviour. Is there a way to save changes I make to the JSON data?
 
LA
Aspiring developer
Profile
Posts: 3278
Reg: Aug 16, 2012
Jerseyville, IL
42,880
like
07/23/13 07:47 AM (10 years ago)
Hi @Deletion, Copy your config from your control panel and paste it in your buzztouch project in the config file that you downloaded. Do a clean and refresh. See if that helps. If this is Android, then delete your App in the emulator and then run. LA
 
GoNorthWest
buzztouch Evangelist
Profile
Posts: 8197
Reg: Jun 24, 2011
Oro Valley, AZ
1,000,000
like
07/23/13 10:13 AM (10 years ago)
The problem is the dataURL, which is where the app gets the config file from (which is on your server). If you leave that as is, and make manual changes to the config file, the next time the app loads, it'll go to the dataURL and grab the latest config file, which will overwrite your changes! So, the only way to make this work is to host the modified config file somewhere like DropBox, and change the dataURL path to point to the new file. That way it'll always check that file, and the changes that go with it. Mark
 
Deletion
Aspiring developer
Profile
Posts: 25
Reg: May 13, 2013
London
6,250
like
07/23/13 10:18 AM (10 years ago)
I read your guide earlier about changing the data url and having the config file in another place. I will have to do that I think then. thanks
 

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.