Changeset 3392
- Timestamp:
- 01/02/2006 08:55:45 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/inline-uploading.php
r3329 r3392 33 33 case 'delete': 34 34 35 if ( !current_user_can('edit_post', (int) $attachment) ) 35 if ( !current_user_can('edit_post', (int) $attachment) ) 36 36 die(__('You are not allowed to delete this attachment.').' <a href="'.basename(__FILE__)."?post=$post&all=$all&action=upload\">".__('Go back').'</a>'); 37 37 … … 297 297 /* Define any variables we'll need, such as alternate URLs. */ 298 298 <?php echo $script; ?> 299 299 function htmldecode(st) { 300 o = document.getElementById('htmldecode'); 301 if (! o) { 302 o = document.createElement("A"); 303 o.id = "htmldecode" 304 } 305 o.innerHTML = st; 306 r = o.innerHTML; 307 return r; 308 } 300 309 function cancelUpload() { 301 310 o = document.getElementById('uploadForm'); … … 333 342 img = imgb[n]; 334 343 } 335 if ( ol.innerHTML == notlinked) {344 if ( ol.innerHTML == htmldecode(notlinked) ) { 336 345 od.innerHTML = ab[n]+img+'</a>'; 337 346 ol.innerHTML = linkedtoimage; 338 } else if ( ol.innerHTML == linkedtoimage) {347 } else if ( ol.innerHTML == htmldecode(linkedtoimage) ) { 339 348 od.innerHTML = aa[n]+img+'</a>'; 340 349 ol.innerHTML = linkedtopage; … … 349 358 oi=document.getElementById('p'+n); 350 359 ih=oi.innerHTML; 351 if ( ol.innerHTML == linkedtofile) {360 if ( ol.innerHTML == htmldecode(linkedtofile) ) { 352 361 od.innerHTML = aa[n]; 353 362 ol.innerHTML = linkedtopage; … … 362 371 o = document.getElementById('image'+n); 363 372 oi = document.getElementById('I'+n); 364 if ( oi.innerHTML == usingthumbnail) {373 if ( oi.innerHTML == htmldecode(usingthumbnail) ) { 365 374 o.src = srcb[n]; 366 375 oi.innerHTML = usingoriginal; … … 374 383 o = document.getElementById('p'+n); 375 384 oi = document.getElementById('I'+n); 376 if ( oi.innerHTML == usingtitle) {385 if ( oi.innerHTML == htmldecode(usingtitle) ) { 377 386 o.innerHTML = filename[n]; 378 387 oi.innerHTML = usingfilename; 379 } else if ( oi.innerHTML == usingfilename&& icon[n] != '' ) {388 } else if ( oi.innerHTML == htmldecode(usingfilename) && icon[n] != '' ) { 380 389 o.innerHTML = icon[n]; 381 390 oi.innerHTML = usingicon; … … 467 476 width: 128px; 468 477 } 469 .usingicon a {470 }471 478 .usingtext { 472 479 padding: 3px; … … 475 482 width: 122px; 476 483 } 477 .usingtext a {478 }479 484 .filetype { 480 485 font-size: 80%; … … 484 489 text-decoration: none; 485 490 } 486 487 491 #upload-menu { 488 492 background: #fff; … … 494 498 width: 100%; 495 499 } 496 497 500 #upload-menu li { 498 501 float: left; 499 502 margin: 0 0 0 .75em; 500 503 } 501 502 504 #upload-menu a { 503 505 display: block; … … 507 509 border-top: 3px solid #fff; 508 510 } 509 510 511 #upload-menu .current a { 511 512 background: #dfe8f1; 512 513 border-right: 2px solid #448abd; 513 514 } 514 515 515 #upload-menu a:hover { 516 516 background: #dfe8f1; 517 517 color: #000; 518 518 } 519 520 521 519 .tip { 522 520 color: rgb(68, 138, 189); … … 599 597 padding: 0.25em; 600 598 } 601 602 599 #submit input:active { 603 600 background: #f4f4f4; … … 615 612 margin: 3px 8px; 616 613 line-height: 2em; 617 618 614 } 619 615 #links textarea {
Note: See TracChangeset
for help on using the changeset viewer.