-
1. Re: Problems loading JSON into Edge Animate
QuadrantProductions Oct 24, 2014 6:50 AM (in response to QuadrantProductions)It has something to do with this I suspect.
-
2. Re: Problems loading JSON into Edge Animate
resdesign Oct 24, 2014 6:51 AM (in response to QuadrantProductions)Try to use html tag between the quotes <br> for lines, etc.. You can use any tag with class names, id names, <style> etc... within the text.
-
3. Re: Problems loading JSON into Edge Animate
QuadrantProductions Oct 24, 2014 7:00 AM (in response to resdesign)resdesign like this?
The testing site is meet-dr-pierre-miller
It's just not working. I'm noticing odd hiccups between the frames. I have JSON files loading in on Timeline events which are supposed to replace the thumbs and corresponding data. If I pull out the long text blocks it works. The last one, loads flawlessly though… could it have something to do with caching the JSON?
-
4. Re: Problems loading JSON into Edge Animate
QuadrantProductions Oct 24, 2014 7:02 AM (in response to QuadrantProductions)"biography" : "Long Bio here. Behind the scenes, and supported by a fabulous team of professionals, Pat is responsible to for the day to day operations of the practice."<br> "Pat received her certification in 1968. She joined the practice in 1992 after a long career in the dental industry including assisting, office management and as a corporate trainer and consultant to dental offices across Canada. A past president of the Ontario Dental Assistants Association"<br>
"(ODAA) Pat was awarded the honor of a life time membership for her contribution to the growth and development of the ODAA and it’s members. Pat is an avid traveler and enjoys live theatre, reading and music."
OR like this
"biography" : "Long Bio here. Behind the scenes, and supported by a fabulous team of professionals, Pat is responsible to for the day to day operations of the practice.<br> Pat received her certification in 1968. She joined the practice in 1992 after a long career in the dental industry including assisting, office management and as a corporate trainer and consultant to dental offices across Canada. A past president of the Ontario Dental Assistants Association. (ODAA) Pat was awarded the honor of a life time membership for her contribution to the growth and development of the ODAA and it’s members. Pat is an avid traveler and enjoys live theatre, reading and music."
Neither work.
-
5. Re: Problems loading JSON into Edge Animate
resdesign Oct 24, 2014 7:08 AM (in response to QuadrantProductions)1s - do not allow line breaks.
Try this:
"biography" : "Long Bio here. Behind the scenes, and supported by a fabulous team of professionals, Pat is responsible to for the day to day operations of the practice.<br>Pat received her certification in 1968. She joined the practice in 1992 after a long career in the dental industry including assisting, office management and as a corporate trainer and consultant to dental offices across Canada. A past president of the Ontario Dental Assistants Association. (ODAA) Pat was awarded the honor of a life time membership for her contribution to the growth and development of the ODAA and it’s members. Pat is an avid traveler and enjoys live theatre, reading and music."
-
6. Re: Problems loading JSON into Edge Animate
resdesign Oct 24, 2014 7:10 AM (in response to QuadrantProductions)What I mean, after adding your html tags for <p> or <br>, delete all the breaks between line until you have only one long line in DW for example. then copy that text in the json file.
-
7. Re: Problems loading JSON into Edge Animate
resdesign Oct 24, 2014 7:13 AM (in response to QuadrantProductions)Possible. Try to clear your cache.
-
8. Re: Problems loading JSON into Edge Animate
QuadrantProductions Oct 24, 2014 7:21 AM (in response to resdesign)AAAAhhhhh! Thankyou.
I'm thinking about putting in some ajax to dump the cache problem. Already though removing the line breaks is making it smoother. Now I need a method to hide / show depending on whether there is a null reference.
I'm thinking something like
if some textfield has null in it
hide the parent clip.
That will be phase 2.
-
9. Re: Problems loading JSON into Edge Animate
resdesign Oct 24, 2014 8:06 AM (in response to QuadrantProductions)Oh, great!
Basically your text needs to look like it would look in Animate and you can see that line break gives an error.
sym.$('text').html("this is text
this is text");
gives an error
sym.$('text').html("this is text"
+" this is text");
is correct.
sym.$('text').html("this is text this is text");
is correct.
-
10. Re: Problems loading JSON into Edge Animate
QuadrantProductions Oct 24, 2014 8:19 AM (in response to resdesign)So for example if you had a text field element that was named "the name". How would you tell animate if the value of the loaded json object was "null" hid the parent clip which is inside another symbol.
Something like
// if my element mySymbolInstanceName has the text "null" in it.
if (sym.getSymbol("mySymbolInstanceName").html("null") { //this is wrong syntax… not sure why
// hide the parent symbol
sym.getParentSymbol().css({"opacity":"0"});
}
else {
// do something entirely different
}
I'm sure my syntax is WAY off.
-
11. Re: Problems loading JSON into Edge Animate
QuadrantProductions Oct 24, 2014 8:26 AM (in response to QuadrantProductions)// if my element mySymbolInstanceName's
if (sym.getSymbol("teamgroup1")sym.$("teamThumb1").data("null") { // or is it more along this line?
// hide the parent symbol
sym.getParentSymbol().css({"opacity":"0"});
}
else {
// do something entirely different
}
-
12. Re: Problems loading JSON into Edge Animate
QuadrantProductions Oct 24, 2014 8:31 AM (in response to resdesign)The functionality I'm trying to change is demonstrated here.
Show when you go to the Assissting tab that the last two thumbnail symbols don't have data. They should be hidden
Also the hygiene tab has 3 which should be hidden. I tried to manually hide them but it broke the entire thing.
-
13. Re: Problems loading JSON into Edge Animate
resdesign Oct 24, 2014 9:35 AM (in response to resdesign)Here is how I handled it on a text on the stage and a button:
test if string is empty.zip - Box
var myText = sym.$('Text');
var nextBtn = sym.$('nextBtn');
myText.html('');
var test = ['here is text','','more text','still more text',''];
i=0;
myText.html(test[i]);
nextBtn.click(function(){
i++;
if (test[i]== null || test[i]==''){
// Hide an element
sym.$("Rectangle").css({'opacity':0.00});
//myText.html(test[i]);
}else{
sym.$("Rectangle").css({'opacity':1.00});
myText.html(test[i]);
}
});



