Dotclear

Changeset 2765


Ignore:
Timestamp:
11/13/10 19:00:56 (13 years ago)
Author:
abompard
Message:

Meilleur plan B si on ne trouve pas l'image à exporter

File:
1 edited

Legend:

Unmodified
Added
Removed
  • plugins/odt/inc/class.odt.dcodf.php

    r2546 r2765  
    176176     { 
    177177          $file = $_SERVER["DOCUMENT_ROOT"].$matches[1]; 
     178          if (!is_readable($file)) { // fichier introuvable 
     179               if ($this->get_remote_images) { // on essaye de le télécharger 
     180                    $matches[0] = str_replace($matches[1], "http://".$_SERVER["SERVER_NAME"].$matches[1], $matches[0]); 
     181                    $matches[1] = "http://".$_SERVER["SERVER_NAME"].$matches[1]; 
     182                    return $this->handleRemoteImg($matches); 
     183               } else { 
     184                    return $matches[0]; // tant pis, on laisse un lien distant 
     185               } 
     186          } 
    178187          return $this->handleImg($file, $matches); 
    179188     } 
Note: See TracChangeset for help on using the changeset viewer.

Sites map