Menu icon Foundation
Interchange and External Content No Workie?

So I am trying to use interchange to show different html content for the different screen sizes in place of the visibility classes and if you change the screen size it won't load the other content unless you refresh the page. So if you are on an ipad and you change orientation this element wont show because I went from medium to large.

Am I missing something here? Why doesn't it load the alternative content on screen size switch without having to refresh the page? This is a problem for tablets.

interchange

So I am trying to use interchange to show different html content for the different screen sizes in place of the visibility classes and if you change the screen size it won't load the other content unless you refresh the page. So if you are on an ipad and you change orientation this element wont show because I went from medium to large.

Am I missing something here? Why doesn't it load the alternative content on screen size switch without having to refresh the page? This is a problem for tablets.

Tom Dean almost 3 years ago

The reflow stuff is not in the 6 docs so I'm not sure if this would work? Any help?

$(document).foundation('interchange', 'reflow');

Ha ha, just tried it and nope doesn't work. Any help appreciated!

Tom Dean almost 3 years ago

I found this: http://foundation.zurb.com/forum/posts/36272-foundation-6--reflow

but it's a bit confusing...

 

Would I use this:

Foundation.reInit('interchange');

Tom Dean almost 3 years ago

Oops, I think this can be closed. I had css and js in the partial files. As soon as I took it out and just included it on the page it worked. So the partial html files only had html. I really thought I could load custom js and css in the partials. That would really help speed things up because I could do some really simple for mobile and really cool for large...