Disabling javascript Date() function with CAPS. - Mozilla

This is a discussion on Disabling javascript Date() function with CAPS. - Mozilla ; I've been struggling with this for over 3 days. I'm trying to disable javascript function Date() or Date().getTime(). I tried the following lines in prefs. js , but none of them works: user_pref("capability.policy.default.Date.getTime", "noAccess"); user_pref("capability.policy.default.javascript.Date", "noAccess"); user_pref("capability.policy.default.javascript.getTime", "noAccess"); user_pref("capability.policy.default.Window.Date", "noAccess"); ...

+ Reply to Thread
Results 1 to 4 of 4

Thread: Disabling javascript Date() function with CAPS.

  1. Disabling javascript Date() function with CAPS.

    I've been struggling with this for over 3 days.
    I'm trying to disable javascript function Date() or Date().getTime().

    I tried the following lines in prefs.js, but none of them works:

    user_pref("capability.policy.default.Date.getTime", "noAccess");
    user_pref("capability.policy.default.javascript.Date", "noAccess");
    user_pref("capability.policy.default.javascript.getTime", "noAccess");
    user_pref("capability.policy.default.Window.Date", "noAccess");
    user_pref("capability.policy.default.Window.getTime", "noAccess");

    What am I missing?

  2. Re: Disabling javascript Date() function with CAPS.

    > I don't know, but I sure am curious why you would want to do that, and
    > what you are trying to prevent people from doing or using. * *At a system
    > level, which you would not be at, that would certainly destroy a databasesystem
    > or anything with logged timestamps.


    That's just an example, I could ask how to disable Date
    ().getTimezoneOffset() function.
    And that wouldn't destroy anything, since it's used by webpages, I
    guess FF uses system functions to get time, not the javascript ones,
    as it's pointless.

    Still need to know how to do it so snoopy sites won't spy for my local
    time. Anybody?

  3. Re: Disabling javascript Date() function with CAPS.

    > Geolocation in Firefoxhttp://www.mozilla.com/en-US/firefox/geolocation/

    David, I know what geolocation in FF is. But it still doesn't answer
    on my original question.

    I need to know how to diable javascript functions via CAPS.

  4. Re: Disabling javascript Date() function with CAPS.

    So nobody knows?

+ Reply to Thread