File tree Expand file tree Collapse file tree 1 file changed +5
-17
lines changed Expand file tree Collapse file tree 1 file changed +5
-17
lines changed Original file line number Diff line number Diff line change 1- jQuery ( function ( ) {
2- // Update "123" to your form ID and "4" to your File Upload field ID.
3- if ( typeof window [ 'GPFUP_123_4' ] === 'undefined' ) {
4- return ;
5- }
6-
7- // Update "123" to your form ID and "4" to your File Upload field ID.
8- var store = window . GPFUP_123_4 . $store ;
9-
10- store . subscribe ( function ( mutation , state ) {
11- if ( mutation . type !== 'SET_FILES' ) {
12- return ;
13- }
14- // Update "5" to your Single Product field ID - or - update `#input_123_5_1` to your desired input's HTML ID.
15- jQuery ( '#input_123_5_1' ) . val ( state . files . length ) . change ( ) ;
16- } ) ;
17- } ) ;
1+ /**
2+ * We're no longer using the experimental folder for experimental snippets. 🚧
3+ * You can now find the snippet here:
4+ * https://github.com/gravitywiz/snippet-library/blob/master/gp-file-upload-pro/gpfup-count-files.js
5+ */
You can’t perform that action at this time.
0 commit comments