Discussion Forums  >  Config Data, JSON, App Refresh

Replies: 15    Views: 140

Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
07/02/12 10:35 AM (13 years ago)

Duplicate your App Tutorial (Works for BTv1.5 & BTv2.0)

Duplicate your App Tutorial (Works for BTv1.5 & BTv2.0) Works with self-hosted & non-self-hosted apps. DUPLICATE? As a former President said, "Depends on what you mean by duplicate". This is but one method: Create Buzztouch app. Download source code. Louie's pizza Leave app online (Don't remove reportToCloud URL or Config file data URL) Duplicate source code. Artie's pizza Duplicate source code. Artie's pizza (perhaps in Italian) Use different resources for each app. To avoid having to modify the Config file to show different URLs you could place URL in a html doc and use the HTML doc screen. Just place different HTML docs using the same file name in the appropriate source code files, just be sure to use same name for embedded html doc. In app #1 embedded doc name would be Sam.html In app #2 embedded doc name would be Sam.html Customize the embedded html doc for each app. One could replace the links in the Config file. (Not recommended simply because it could be a lot of work.) (HTML Docs would be easier.) For Online HTML docs here's my suggestion. Create HTML Doc screen using embedded HTML Doc. Name of doc is unimportant, but each app will havean HTML doc using the same name. Let's call it "Bob. html" Place Bob.html doc in BT_Assets folder. Place Bob.html doc version #2 in app #2. You customize Bob.html for each app place links pointing to online html doc. Possibly using redirect if you wish. You also need to: Replace app icon Rename the (Android: package name) (iOS Bundleid ?) Rename the app (in the source code) For Android Use Android Tools. Be sure that screen nicknames either hide or are generic Test before you publish, you don't want Artie's pizza made with Louie's special sauce. (Example: Tooters' menu proudly claimed their chicken wings were made with Hooter's special sauce. True story, printer didn't fix menu oversight by Tooters) Publish three apps. 1. Louie's Pizza 2. Artie's Pizza 3. Pizza di Artie App structure is identical but content is different. Any changes in the control panel will display in both. There are many ways to play with this. Third party online Config file. Online vs. Offline Config file. Fred Second method as outlined by Stobe in another post) http://www.buzztouch.com/forum/thread.php?tid=8C3465F132548F86B6D2F7C "Having two apps identical in structure, but differing in content is fairly easy. What I do is: -Create the first app in BT's control panel and download the source. -Create all the content for the first app (html docs, header images, buttons, media, etc). -Add content to xCode (this would work for android as well, I suppose). -Compile - Done with first app. -Create the second (blank) app in BT's control panel. -Before downloading the source, delete the dataURL and report-to URL from the core properties. -Download second app's source. -Copy all the BT_items JSON from the first app's BT_Config.txt -Paste it into the second app's BT_Config.txt in xCode. -Create new content for the second app, and name everything the same as the first app's content. -Add content to xCode -Compile - Done with second app. Hopefully I didn't miss any steps. They all work in my head :) . . . -Stobe"
 
MadRod
Aspiring developer
Profile
Posts: 1853
Reg: Apr 12, 2012
Lisbon
27,930
like
07/02/12 01:51 PM (13 years ago)
Hey Fred thanks for this great post.
 
Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
like
07/02/12 02:48 PM (13 years ago)
Thanks Fred
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/21/12 06:28 PM (13 years ago)
@Fred I need to duplicate my app so that I can have URL based .pdf's for the iPhone version and embedded for iPad version. I think the only way to do that is by NOT ""To avoid having to modify the Config file to show different URLs" as you said above. How would I do that? Thanks Basically I need 2 control panels.
 
Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
like
07/21/12 06:42 PM (13 years ago)
For two control panels you create two apps. Are you asking how to duplicate the first app in the control panel? To have url in one and embedded in another you need two different config files. How many instances of the pdf/url do you have? Fred
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/21/12 07:14 PM (13 years ago)
Sorry....let me clarify. 2-3 PDF's for every model vehicle Ford makes in 2012-2013. I created my iPad app and embedded my PDF's. Once the iPad was complete (almost everything is universal except for the PDF's and embedded images) I copied my BT_Config file. Next I created another app and named it iPhone. I then downloaded the source code and opened it in Xcode. I pasted the BT_Config file and ran the code on my iPhone and it worked perfectly. The only problem is that I need to make separate changes to the iPhone version and can't do that with just one control panel. My question is how do I take the API/key from the new control panel and incorporate it into the copied BT_Config.txt file? Thanks
 
Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
like
07/21/12 08:09 PM (13 years ago)
For what gain? Screen items are not in the database so copying the key has no purpose. Fred
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/21/12 08:19 PM (13 years ago)
I can't change anything in the copied App I created with the BT_Config.txt file....the iPhone version.
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/21/12 08:20 PM (13 years ago)
are you saying I have to rebuild the entire app??? Oh my GOD THAT IS SO MANY HOURS!!! Say it so.
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/21/12 08:25 PM (13 years ago)
What good is it to copy an app using the BT_Config.txt file if you can't change the copied app?? I built an iPad app. I need the exact same app but with url based PDF's and (as you pointed out) I need separate control panels to accomplish that. This can't be beyond the scope of Buzztouch....or is it? Thank you.
 
MadRod
Aspiring developer
Profile
Posts: 1853
Reg: Apr 12, 2012
Lisbon
27,930
like
07/21/12 08:39 PM (13 years ago)
What I'd do was copy the entire sql database and import it to the new control panel. This would copy all your apps, not just a specific one, but uou can then delete them in the new control panel.
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/21/12 08:45 PM (13 years ago)
that seems genius....can you give me just a few more steps? THANK YOU
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/21/12 08:50 PM (13 years ago)
PS: in BTv1.5 you can't delete your apps ONLY if you self host it. ***only Thank you @Fred typo
 
Fred@mySkylla com
Android Fan
Profile
Posts: 5259
Reg: Oct 03, 2011
location unknow...
62,560
like
07/21/12 09:08 PM (13 years ago)
You can't self-host BTv1.5
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/21/12 09:14 PM (13 years ago)
Now @fred tell me how you would "copy the entire sql database and import it to the new control panel" and not have duplicates of ALL your apps?
 
MadRod
Aspiring developer
Profile
Posts: 1853
Reg: Apr 12, 2012
Lisbon
27,930
like
07/21/12 09:37 PM (13 years ago)
Where I host my server, I just use a wizard to duplicate any SQL database O have and give a name for that new db. Add that db as the control panel db and all appears in the control panel. Just have to import the jpeg icon for the apps. Then I delete the apps I don't need duplicated. Of course you can only do this once, unless you want more than two control panels, otherwise you'll just be overwriting the db. Don't know if you can set the control panel to allow you to choose walhat db to use, that would be a good feature for self hosted.
 

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.