Discussion Forums  >  Uncategorized

Replies: 4    Views: 436

birwin
Lost but trying
Profile
Posts: 93
Reg: Dec 29, 2010
location unknow...
3,080
01/02/11 03:32 PM (15 years ago)

v1.5 headerImage from remote URL?

Hello, I have been tinkering around with pre-release version 1.5. (just sent out to early adopters today) I built the demo app with no problems (iOS SDK 4.2). Fantastic Work!!! So many possibilities!! I have successfully copied the JSON config file BT_config_tabs.txt to my own server. Is there a way to pull the headerImage logo.png from a remote URL? I tried experimenting to change the following value from: headerImageNameSmallDevice:logo.png to headerImageURLSmallDevice:http://www.myserver.com/logo.png Anyways, probably something real simple that I missed. Once again, Awesome Job!! You should also be commended on your clear and thorough documentation as well. Best Regards, Brian-
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
01/02/11 05:53 PM (15 years ago)
OK, makes sense. If you want to use a remote image for the header instead of an image embedded in the Xcode project, do this: a) Enter a name in the headerImageNameSmallDevice, and, enter a URL to the image in the headerImageNameLargeDevice so it knows where to find it. Like this... headerImageNameSmallDevice:myLogo.png headerImageNameSmallDevice:http://myserver/logo.png Do the same thing for larger devices (iPad) the image should be different in the bigger layout headerImageNameLargeDevice:myLargerLogo.png headerImageNameLargeDevice:http://myserver/myLargerLogo.png The app will first check the Xcode project for an image named myLogo.png and it won't find it. So, it will then download it from the URL and save it for next time. Future loads will not require the download. I have omitted the double-quotes around the property values because the forum doesn't like them ;-) The trick is that you need BOTH the file name and the URL in the screens data.
 
birwin
Lost but trying
Profile
Posts: 93
Reg: Dec 29, 2010
location unknow...
3,080
like
01/02/11 06:22 PM (15 years ago)
Thanks for the tip! I got it to work by making a slight adjustment to your example. headerImageNameSmallDevice:mylogo.png headerImageURLSmallDevice:http://myserver/mylogo.png 2 instances of headerImageNameSmallDevice didn't seem to work for me, the image link broke (grey questionmark placeholder). I added URL in place of Name and it is working fine. Best Regards, Brian-
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
01/02/11 06:44 PM (15 years ago)
OK, but something doesn't make sense - I may need to fix an issue you're discovering. Please post the JSON data you have for the screen with the header image. Don't post all the menu items in the list, just the first portion of the JSON for the screen so I can see what you're using and fix the source for the next guy
 
birwin
Lost but trying
Profile
Posts: 93
Reg: Dec 29, 2010
location unknow...
3,080
like
01/02/11 07:06 PM (15 years ago)
Hello David, No problem at all. Here is a pastebin link to the JSON code for the homescreen: http://pastebin.com/raw.php?i=9kiBzV1a Let me know if you need anything else. Best Regards, Brian-
 

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.