Changeset 3469 for trunk/wp-admin/inline-uploading.php
- Timestamp:
- 01/21/2006 05:41:52 AM (20 years ago)
- File:
-
- 1 edited
-
trunk/wp-admin/inline-uploading.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/inline-uploading.php
r3456 r3469 259 259 $icon = get_attachment_icon($ID); 260 260 $toggle_icon = "<a id=\"I{$ID}\" onclick=\"toggleOtherIcon({$ID});return false;\" href=\"javascript:void()\">$__using_title</a>"; 261 $script .= "aa[{$ID}] = '<a id=\"p{$ID}\" rel=\"attachment\" href=\"$href\" onclick=\"doPopup({$ID});return false;\" title=\"{$title}\"> {$title}</a>';262 ab[{$ID}] = '<a id=\"p{$ID}\" href=\"{$filename}\" onclick=\"doPopup({$ID});return false;\" title=\"{$title}\"> {$title}</a>';261 $script .= "aa[{$ID}] = '<a id=\"p{$ID}\" rel=\"attachment\" href=\"$href\" onclick=\"doPopup({$ID});return false;\" title=\"{$title}\">'; 262 ab[{$ID}] = '<a id=\"p{$ID}\" href=\"{$filename}\" onclick=\"doPopup({$ID});return false;\" title=\"{$title}\">'; 263 263 title[{$ID}] = '{$title}'; 264 264 filename[{$ID}] = '{$filename}'; … … 348 348 } 349 349 function toggleOtherLink(n) { 350 od=document.getElementById('div'+n);351 350 ol=document.getElementById('L'+n); 352 oi=document.getElementById('p'+n);353 ih=oi.innerHTML;354 351 if ( ol.innerHTML == htmldecode(linkedtofile) ) { 355 od.innerHTML = aa[n];356 352 ol.innerHTML = linkedtopage; 357 353 } else { 358 od.innerHTML = ab[n];359 354 ol.innerHTML = linkedtofile; 360 355 } 361 oi=document.getElementById('p'+n); 362 oi.innerHTML = ih; 356 updateOtherIcon(n); 363 357 } 364 358 function toggleImage(n) { … … 373 367 function toggleOtherIcon(n) { 374 368 od = document.getElementById('div'+n); 375 o = document.getElementById('p'+n);376 369 oi = document.getElementById('I'+n); 377 370 if ( oi.innerHTML == htmldecode(usingtitle) ) { 378 o.innerHTML = filename[n];379 371 oi.innerHTML = usingfilename; 372 od.className = 'otherwrap usingtext'; 380 373 } else if ( oi.innerHTML == htmldecode(usingfilename) && icon[n] != '' ) { 381 o.innerHTML = icon[n];382 374 oi.innerHTML = usingicon; 375 od.className = 'otherwrap usingicon'; 383 376 } else { 384 o.innerHTML = title[n];385 377 oi.innerHTML = usingtitle; 386 }387 if ( oi.innerHTML == usingicon )388 od.className = 'otherwrap usingicon';389 else390 378 od.className = 'otherwrap usingtext'; 379 } 380 updateOtherIcon(n); 391 381 } 392 382 function updateImage(n) { … … 407 397 } 408 398 } 399 function updateOtherIcon(n) { 400 od=document.getElementById('div'+n); 401 ol=document.getElementById('L'+n); 402 oi=document.getElementById('I'+n); 403 if ( oi.innerHTML == htmldecode(usingfilename) ) { 404 txt = filename[n]; 405 } else if ( oi.innerHTML == htmldecode(usingicon) ) { 406 txt = icon[n]; 407 } else { 408 txt = title[n]; 409 } 410 if ( ol.innerHTML == htmldecode(linkedtofile) ) { 411 od.innerHTML = ab[n]+txt+'</a>'; 412 } else if ( ol.innerHTML == htmldecode(linkedtopage) ) { 413 od.innerHTML = aa[n]+txt+'</a>'; 414 } else { 415 od.innerHTML = txt; 416 } 417 } 418 409 419 var win = window.opener ? window.opener : window.dialogArguments; 410 420 if (!win) win = top;
Note: See TracChangeset
for help on using the changeset viewer.