Handle Cancel Click on File Input

Ever Tried capturing cancel event on Browse file input type in HTML, tbh there is no direct way to do so :(

But there is a workaround adding a bit of javascript. We can play with onfocus event of the BODY element.

Handle Cancel Click on File Input

Handle Cancel Click on File Input

Example ->



See it working here


Chandigarh SFD

We (me and Kritika) got a chance to represent Mozilla on software freedom day at Panjab University, Chandigarh. Chandigarh is city beautiful and there have been several events before but still struggling to form a well shaped community there.

So we planned to introduce Mozilla to students in most interactive way. We split our session into 4 major parts.

  1. Mozilla and its Mission – Kritika
  2. Contributions – how and why – Trishul [slide]
  3. Moz VR – Kritika
  4. Web compatibility – Trishul [slide]


So I must acknowledge that it was quite hectic and random for me. I drove from Delhi to Chandigarh and reached there by 11 and I have to deliver talk at 2:00 PM. But the enthusiasm in the attendees charged me up like anything.

We delivered the content along with few Ice breakers Like (Free Applaud, Rule of Seven) and it worked liked charm, attendees got loosened up and the mode of session changed from talk to conversation. The attendees could actually relate to us and were super excited to know about Virtual reality and web compat, some of the attendees actually filed few bugs on the spot on webcompat.com \o/

By end of the session we were flocked by the queries how to get started with Mozilla and be a volunteer for Mozilla. So we are planning to setup a Mozilla Club soon in the Panjab University and can mark the initiation of Mozilla Chapter in Panjab university.

So yeah after wrapping up the event we searched for best chicken in the town and had some “Sundar Khana” :P cc-Tanish. And then somehow wanderlust struck me (as usual) and next day I left for Kasauli.


All Hands 2016 London

It all started with a talk which I attended just to kill sometime, and now 3 years after that here I am packing my bags to attend All Hands with the team I have been working with virtuallly, in the other corner of the world.
Mozilla, 3 years back was just Firefox – The Browser for me, but gradually it turned out to be a mission of which I am a part. I can proudly say I owe my knowledge, my career, my vision to Mozilla. When I started to get involved with mozilla I not only started contribution to open source but to my life as well. Its a journey from no one to someone.
I started my contributions with SUMO, L10n, but app development was something that always tempted me. I started as an app developer for Firefox OS, then became app-reviewer, i also coded for markeplace and eventualy became code mentor for the same. While I attended All hands – dec -2016, I got the to know about discontinuation of Firefox OS for smartphones. I was literally in state of shock.
But then I realized that it is not the end. I shifted my contributions to addons and a new found project Web Compat. Now these two projects has much to keep me occupied. And working with the team is really like grooming yourself.
Hoping that this Allhands will surely help to take my journey with Mozilla to a new level.


Makerfest 2016

One of the best opportunity to represent Mozilla at a place filled with innovative makers from all over India.

3 days Event

3000+ Attendees

Age 10 years to 60 years

It was a three day event where various makers have their booth setup to showcase their innovation. We too setup a booth to spread Mozilla mission and online privacy. We team of eight, from various part of India, never met before were jelled up as we have been together for long. With the booth setup we were ready for the event.

Day 1 –


The event started with few people visiting random stalls. Then came the groups of school students – super curious, super excited. While visiting various stalls they were amazed to learn many new things. On our stall they spent the most time as they learnt things about internet- their basic need . we explained them about open source, online privacy, how they are being tracked, best measures to ensure their online privacy, etc.

To our surprise we even got privacy tips from the attendees. And we dedicated a complete section on “Ahmedabad on Privacy”. In addition to that we even got suggestions for Firefox browser.


When the day ended we were satisfied but exhausted. But yes Ahmedabad has got a lot to feed and entertain us.

Day 2 –

Once we were done with booth setup, we got a huge crowd from regional colleges, everybody was bowled over by LIGHTBEAM and the tracking protection. We actually show them the tracking done on two different bank sites and tweeted about them, and to our very surprise , the banks tweeted us back with promise to take care of their trackers.









The attendees loved to know about PASSPHRASES and few of them changed their passwords to passphrases right on the spot (reason we almost decoded their passwords by social engineering :P )

And yes they loved the privacy window.


We also got various invitations to start a club in different colleges as there is no Mozilla community in Gujarat.

Again the day ended but again there was something to repeat “Sabarmati River Front”

Day 3-

The final day, now we engaged 6 of us on booth and kept 2 in buffer who can visit all the booths and learn something.


There were various booths and doing amazing stuff.

  • A kid of 6 years coding for aurdino – making drones and robots (Yes 6  years – Saarang from Kerela)
  • Automated chess (Where the coins actually move on board as the computer plays)- http://chessautomated.com/
  • A neural gadget which actually track your hand movements and replicat it on computer (basically IRON MAN) – http://spockglove.com/
  • A fun and practical way of learning and teaching physics – http://brillico.org/
  • A universal remote controlled by your mobile – http://zmote.io/landing.html
  • A women group doing awesome stuff with 3d printers (Jwellery, show pieces, future plan to make bio cells YES bio cells )- http://ladytechguild.com/
  • Booth for learning quilling
  • Many variations of 3D printers.

The list goes on.

p1 p2   p5














With this I will end the story here and Kudos to the Mozilla team –

Kumaresan Subash (Saat smundar Par)

Prathamesh Chawan (Nice Teets)

Aman Sehgal (Segway segway)

Ankit Mehta (Give away every swag – moving to Australia)

Sanjay Gouri (The chamatkari purush – enough said :P )

Mehul Patel (The rockstar – only for specific gender )

Ashish Mishra (the designer)

Kamlesh Vilpura (the surprise package)

Thanks to Ashish who instantaneously drew all the posters which actually helped us a lot to deliver the content in best way possible.

A special thanks to Kamalesh who actually captured all the moments in his phone.

And yes the backend person – Santosh Vishwanathan,

Love to see more pics ? Click here


enum Vs tinyInt

Long story short ENUM is evil :P

Premature optimization is the root of all evil. Very well put by Chris Komlenic.

Sometimes we over optimize the database schema, as in in terms of data structures. generally we have a dilemma of using Tinyint or enum, while storing values in columns such as ‘status’, ‘isActive’, ‘isTrue’, etc. Its very difficult to assume that the status can be only given values.

If we declare the column as enum it is hell lot problematic to chnage / add and more enum value to that column when the data in table pile up. In that case its just a huge pain, we are helpless and actually we have to block table operations for a while. Which can actually cost your business. But if it were a tiny int, it would be just a new value in the SQL query.

Also while changing the datatype of enum its really pain. The enum is based on indexing and its indexing starts from 1 instead of 0. [WTF]

To clear my point following is content extract from few other blogs

  1. With an ENUM we’re actually storing pieces of data in a place that was only intended to hold crucial information about the model. In short, an ENUM column violates the rules of normalization.
  2. You  create an ENUM column and say “no way NEVER will this list change or need added to”. But humans are really poor at estimating the entire scope of something, and even worse at predicting the future. problem is that changing the member list for an ENUM column restructures the entire table with ALTER TABLE, which can be very expensive on resources and time
  3. ENUM has limited portability to other DBMS.
  4. There’s a reason ENUM is a string data type. Not only should you be using a numeric data type to store numbers
  5. ENUM takes 1 byte (if under 255 values) or 2 bytes (up to maximum of 65,535 – ENUM does take up some metadata for the string value associated with it though
  6. TinyInt takes 1 byte (maximum of 255 values)






[Reference – http://komlenic.com]


Marketplace day Jaipur – Planning



  • Marketplace Day is a full day or over night event completely focused on code-contribution for Firefox Marketplace. 

  • Marketplace Day Jaipur is an event being organized under a series of pilot events to come up with a concrete format of Marketplace Day events. 

While  Mozilla India  task force meetup 2015, we introduced Market Place  Taskforce. The primary agenda of this taskforce is to promote  marketplace and add more and more contributors for the same. In this  flow we will be organizing marketplace days in various regions of  India, so to start with we are moving to MCR which comprises of  enthusiastic contributors.


The MCR has been proving its potential right from its birth and this event will surely give them another level to their contributions. The marketplace contributions are still in a nascent stage and this event will surely boost up the contributions and help the contributors to kick  start contributions to marketplace instantly.


* Anyone who is interested to join The Awesome Firefox Marketplace Community.
* We will cover lot of things which are pre-requisite for code-base contribution to open source projects. So if you are looking for getting started with code-base contribution, this is the best chance :)
Want to know more check this.

MCR SIGs – Special Interest Groups

By now every one of us has a decent idea what exactly SIGs are (in case you want to know more click here) .  So today we are finalizing the proposed SIGs as follows:

  • L10n SIG
  • Webmaker SIG
  • App Dev SIG
  • SuMo SIG
  • CodeBase SIG
  • WoMoz SIG
  • Engagement SIG (umbrella covering all mentors of SIG)

Various SIGs have been proposed, and very common SIG requested was of community building. So instead of creating a new SIG we propose Engagement SIG  which comprises of mentors of all other SIG.

So these are the SIGs which will help, track, promote the contributions in their respective areas. Each SIG will have one or more mentors who will be having following responsibilities and privileges.


  • Engaging more and more contributors
  • Assisting them in case of any issues.
  • Pass them all necessary information and aware mentees about all opportunities
  • Track the progress of their mentees and eventually help them to get proper recognition.
  • Documenting the progress.
  • Awarding the deserving mentee with proper recognition monthly.


  • Eligible for a cool SIG Mentor T-Shirt (the first thing came in my mind :P)
  • Special recognition as mentor on various channels.
  • Member of the Engagement SIG
  • Can request swags/budget and  respective rep will avail them (subject to several conditions).
  • And yes few more surprises !!!

By the end of this week we will be having our very first SIG mentors. To be one of them fill the form here.

PS : The only eligibility required to be a SIG mentor is one should be a mozillian contributor (in any vertical).

In case of any further query feel free to ping

Trishul [trishul.goel@gmail.com]

Ram [vaishnav.rd@gmail.com]


MozIgnite @ Bhatkal

This was one of my first workshops in the south India region as an organizer-cum-speaker and also one of the most memorable one too.

The department of computer Science and Information Science AITM, Bhatkal under its FOCI banner conducted the event Mozignite’15 on 4th and 5th of April 2015. It was first the event by Mozilla in the Mangaluru region. We (Trishul Goel, Abraar Sayeed, Sandesh Gade) traveled all the way from Bangalore to Bhatkal, to meet an extremely enthusiastic crowd.

The event initiated with welcoming Director, HOD, Vice principal and chief guest( yey thats ME :) ) . Then I explained the attendees what we are going to do in these 2 days and why  they need to attend this. Then Abraar explained them about open-source and Mozilla mission. Followed by Me explaining what is web and how one can get involved in web making using the webmaker tools. The attendees were readily participating in the session. And after the lunch break we moved to the labs, to get some hands on action.

In the labs we explained the different web maker tools (Thimble, Popcorn, X-Ray Goggles, AppMaker). And students actually started to remix the makes then and there.Just a snapshot of students efforts is here .

So we wrapped the day one with lot of energy for next day. Day 2 was for Appmaker. We started the session directly in the labs. And Students were damn excited about AppMaker. As they were actually going to make a web app. And they were literally overjoyed one they actually created and installed an APP. After lunch w explained various contribution verticals to them where they can actually start contributing to Mozilla (AoA, SUMO, L10n, Codebase etc.)

After this they management gave us vote of thanks and an unforgettable memento. And hence the workshop concluded with lots of hope and dreams.


DSC04290DSC04606 DSC04523 DSC04415 DSC04402 DSC04378 DSC04314


























Loved Photos? view all here.