Applications


How to change user agent using Firefox

A video demonstrating how to change the user agent of your Firefox browser.


Gravity Forms: How to Restrict a DatePicker Date Range and Datepicker 1 becomes minDate for datepicker 2

Create an html block in your form and add the following code:

<script type="text/javascript">
gform.addFilter( 'gform_datepicker_options_pre_init', function( optionsObj, formId, fieldId ) {
    if ( formId == 10 && (fieldId == 30 || fieldId == 32) ) {
        var ranges = [
            { start: new Date('10/01/2021'), end: new Date('10/11/2021') }
        ];
        optionsObj.beforeShowDay = function(date) {
            for ( var i=0; i<ranges.length; i++ ) {
                if ( date >= ranges[i].start && date <= ranges[i].end ) return [true, ''];
            }
            return [false, ''];
        };
        optionsObj.minDate = ranges[0].start;
        optionsObj.maxDate = ranges[ranges.length -1].end;
    }
    if ( formId == 10 && fieldId == 30 ) {
        optionsObj.onClose = function (dateText, inst) {
            jQuery('#input_10_32').datepicker('option', 'minDate', dateText).datepicker('setDate', dateText);
        };
    }
    return optionsObj;
});
</script>

Be sure to change the dates, the form ID and field ID for the two fields.


A note on the Chrome Plugin “Fast Delete Messages” for deleting all Facebook Messenger Messages without deleting the conversations

Recently, we used the “Fast Delete Messages” on Chromium browser to delete all messages of a Facebook Messenger account without deleting the chats themselves.

To our surprise, we noticed two observations:

  1. The plugin worked extremely fast!
    We thought it would take a few minutes (as it would delete messages one by one), but it finished in less than a few seconds in reality.
  2. After the plugin finished, the list of conversations was empty!
    Initially, we thought a bug was in the plugin, and it had deleted all conversations.
    Following some research, it appeared that the conversations were not deleted, but Messenger hid them!
    We verified that the conversations were hidden as whenever anyone would send a message in a conversation or group chat, the conversation would appear, and it would work normally.