I have this issue, I want to be able to change the audio being used based on the browser. What I have is an object seen below, which has a "ext: { sound: '.mp3' }", at some point I will make some distinctions between browser then use something like "object.ext.sound = '.ogg'" to set the new sound type based off the browser being used. How do I reference that variable from within the object in for instance "StAd0"?
var object = {
    ext: {
        sound: '.mp3'
        },
    pref: {
        acc: 1
    },
    StAd0: {
        from: 25,
        to: 180,
        src: 'ar/55871'+ this.ext.sound,
        du: 5228
    },
    Image_33: {
        type: 15,
        from: 4,
        to: 48,
        rp: 0,
        rpa: 0,
        mdi: 'Image_33c',
        trin: 6,
        trout: 6,
        ef: {}
    },
    Image_33c: {
        b: [171, 259, 850, 360],
        ip: 'dr/7029_679_101.png',
        dn: 'Image_33',
        visible: 1,
        accstr: 'Image ',
        vb: [171, 259, 850, 360]
    }
}
The way I have things now it keeps saying that "this.ext.sound" has a value of "undefined". I was thinking it has to do with scope but quite honestly I am stumped, I feel like I've tried every combination of dot notation to try to get the property but I am just not referencing the property correctly.
Any help is greatly appreciated, thanks in advance!
 
     
     
     
    