Changeset 8640
- Timestamp:
- 07/17/2014 06:09:35 PM (12 years ago)
- File:
-
- 1 edited
-
trunk/src/bp-xprofile/admin/js/admin.js (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-xprofile/admin/js/admin.js
r8639 r8640 3 3 /* global XProfileAdmin */ 4 4 5 /** 6 * Add option for the forWhat type. 7 * 8 * @param {string} forWhat Value of the field to show options for 9 */ 5 10 function add_option(forWhat) { 6 var holder = document.getElementById(forWhat + '_more'),7 theId = document.getElementById(forWhat + '_option_number').value,8 newDiv = document.createElement('p'),9 newOption = document.createElement('input'),10 span = document.createElement( 'span' ),11 txt = document.createTextNode( '\u00A0\u039E\u00A0' ),12 isDefault = document.createElement( 'input' ),13 span1 = document.createElement( 'span' ),14 txt1 = document.createTextNode( ' Default Value ' ),11 var holder = document.getElementById(forWhat + '_more'), 12 theId = document.getElementById(forWhat + '_option_number').value, 13 newDiv = document.createElement('p'), 14 newOption = document.createElement('input'), 15 span = document.createElement( 'span' ), 16 txt = document.createTextNode( '\u00A0\u039E\u00A0' ), 17 isDefault = document.createElement( 'input' ), 18 span1 = document.createElement( 'span' ), 19 txt1 = document.createTextNode( ' Default Value ' ), 15 20 16 21 toDelete = document.createElement( 'a' ), 17 22 toDeleteText = document.createTextNode( '[x]' ); 18 19 23 20 24 newDiv.setAttribute('id', forWhat + '_div' + theId); … … 38 42 39 43 span1.appendChild( txt1 ); 40 41 44 42 45 toDelete.setAttribute( 'href', 'javascript:hide("' + forWhat + '_div' + theId + '")' ); … … 133 136 } ); 134 137 135 // 138 // Set up the sort order change actions 136 139 jQuery( '[id^="sort_order_"]' ).change(function() { 137 140 if ( jQuery( this ).val() !== 'custom' ) {
Note: See TracChangeset
for help on using the changeset viewer.