Changeset 2902
- Timestamp:
- Nov 23, 2008, 6:23:57 PM (15 years ago)
- Location:
- trunk
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/admin/include/functions.php
r2900 r2902 1949 1949 function fetchRemote($src, &$dest, $user_agent='Piwigo', $step=0) 1950 1950 { 1951 // Try to retrieve data from local file? 1952 if (!url_is_remote($src)) 1953 { 1954 $content = @file_get_contents($src); 1955 if ($content !== false) 1956 { 1957 is_resource($dest) ? @fwrite($dest, $content) : $dest = $content; 1958 return true; 1959 } 1960 else 1961 { 1962 return false; 1963 } 1964 } 1965 1951 1966 // After 3 redirections, return false 1952 1967 if ($step > 3) return false; … … 1965 1980 $content = @curl_exec($ch); 1966 1981 $header_length = @curl_getinfo($ch, CURLINFO_HEADER_SIZE); 1982 $status = @curl_getinfo($ch, CURLINFO_HTTP_CODE); 1967 1983 @curl_close($ch); 1968 if ($content !== false )1984 if ($content !== false and $status >= 200 and $status < 400) 1969 1985 { 1970 1986 if (preg_match('/Location:\s+?(.+)/', substr($content, 0, $header_length), $m)) -
trunk/admin/site_manager.php
r2530 r2902 45 45 global $template, $page; 46 46 47 if($lines = @file($url)) 48 { 47 if (fetchRemote($url, $result)) 48 { 49 $lines = explode("\r\n", $result); 49 50 // cleaning lines from HTML tags 50 51 foreach ($lines as $line) … … 113 114 $clf_url.= '?action=test'; 114 115 $clf_url.= '&version='.PHPWG_VERSION; 115 if ( ($lines = @file($clf_url)) !== false)116 if (fetchRemote($clf_url, $result)) 116 117 { 118 $lines = explode("\r\n", $result); 117 119 $first_line = strip_tags($lines[0]); 118 120 if (!preg_match('/^PWG-INFO-2:/', $first_line)) -
trunk/admin/site_reader_remote.php
r2299 r2902 49 49 if (!isset($listing_url)) 50 50 { 51 $this->listing_url = $this->site_url.' /listing.xml';51 $this->listing_url = $this->site_url.'listing.xml'; 52 52 } 53 53 else … … 66 66 global $errors; 67 67 68 if ( @fopen($this->listing_url, 'r'))68 if ($xml_content = getXmlCode($this->listing_url)) 69 69 { 70 70 $this->site_dirs = array(); 71 71 $this->site_files = array(); 72 $xml_content = getXmlCode($this->listing_url);73 72 $info_xml_element = getChild($xml_content, 'informations'); 74 73 if (getAttribute($info_xml_element , 'phpwg_version') != PHPWG_VERSION) -
trunk/admin/template/goto/install.tpl
r2819 r2902 146 146 </table> 147 147 </form> 148 {else} 149 <p> 150 <br /> 151 <input type="button" name="index" value="{'home'|@translate}" onClick="document.location = 'index.php';"/> 152 <input type="button" name="identification" value="{'Identification'|@translate}" onClick="document.location = 'identification.php';"/> 153 </p> 148 154 {/if} 149 155 </div> {* content *} -
trunk/include/functions_xml.inc.php
r2299 r2902 122 122 } 123 123 124 $file = fopen( $filename, 'r' ); 125 if ( !$file ) 124 if (!fetchRemote($filename, $xml_content)) 126 125 { 127 126 return false; 128 127 } 129 128 130 $xml_content = '';131 while ( !feof( $file ) )132 {133 $xml_content .= fgets( $file, 1024 );134 }135 fclose( $file );136 129 $xml_content = str_replace( "\n", '', $xml_content ); 137 130 $xml_content = str_replace( "\t", '', $xml_content ); -
trunk/language/de_DE/install.lang.php
r2865 r2902 58 58 $lang['install_help'] = 'Brauchen Sie Hilfe? Stellen Sie Ihre Frage auf der <a href="%s"> Forum Piwigo </ a>.'; 59 59 $lang['install_end_message'] = 'Die Konfiguration der Piwigo abgeschlossen ist, hier ist der nächste Schritt<br /><br /> 60 * Gehen Sie auf die Identifizierung Seite : [ <a href="./identification.php">Identifizierung</a> ]und verwenden Sie die Login / Passwort für Webmaster<br />60 * Gehen Sie auf die Identifizierung Seite und verwenden Sie die Login / Passwort für Webmaster<br /> 61 61 * diesem Login ermöglicht Ihnen den Zugang zu den Verwaltungs-Panel und den Anweisungen, um Platz Bilder in Ihre Verzeichnisse.'; 62 62 $lang['conf_mail_webmaster'] = 'Webmaster Mail-Adresse'; -
trunk/language/en_UK/install.lang.php
r2865 r2902 60 60 $lang['install_help'] = 'Need help ? Ask your question on <a href="%s">Piwigo message board</a>.'; 61 61 $lang['install_end_message'] = 'The configuration of Piwigo is finished, here is the next step<br /><br /> 62 * go to the identification page : [ <a href="identification.php">identification</a> ]and use the login/password given for webmaster<br />62 * go to the identification page and use the login/password given for webmaster<br /> 63 63 * this login will enable you to access to the administration panel and to the instructions in order to place pictures in your directories'; 64 64 $lang['conf_mail_webmaster'] = 'Webmaster mail address'; -
trunk/language/es_ES/install.lang.php
r2865 r2902 58 58 $lang['install_help'] = '¿ Necesidad de ayudante? Plantee su cuestión sobre él <a href="%s">foro de Piwigo</a>.'; 59 59 $lang['install_end_message'] = 'La configuración de la aplicación correctamente se celebró, coloca en la etapa próxima<br /><br /> 60 * Vaya sobre la página de identificación : [ <a href="./identification.php">identificación</a> ] Yconéctese con pseudo dado para el webmaster<br />60 * Vaya sobre la página de identificación y conéctese con pseudo dado para el webmaster<br /> 61 61 * Éste le permite acceder a la parte administración y a las instrucciones para colocar las imágenes en los repertorios.'; 62 62 $lang['conf_mail_webmaster'] = 'Dirige e-mail del Administrador'; -
trunk/language/fr_FR/install.lang.php
r2865 r2902 58 58 $lang['install_help'] = 'Besoin d\'aide ? Posez votre question sur le <a href="%s">forum de Piwigo</a>.'; 59 59 $lang['install_end_message'] = 'La configuration de l\'application s\'est correctement déroulée, place à la prochaine étape<br /><br /> 60 * allez sur la page d\'identification : [ <a href="./identification.php">identification</a> ]et connectez-vous avec le pseudo donné pour le webmaster<br />60 * allez sur la page d\'identification et connectez-vous avec le pseudo donné pour le webmaster<br /> 61 61 * celui-ci vous permet d\'accéder à la partie administration et aux instructions pour placer les images dans les répertoires.'; 62 62 $lang['conf_mail_webmaster'] = 'Adresse e-mail de l\'Administrateur'; -
trunk/language/it_IT/install.lang.php
r2887 r2902 58 58 $lang['install_help'] = 'Bisogno di un aiuto? Visitate il <a href="%s">forum di Piwigo</a>.'; 59 59 $lang['install_end_message'] = 'La configurazione di Piwigo è conclusa. Procedete al prossimo step<br /><br /> 60 * collegatevi alla pagina d\'accesso : [ <a href="identification.php">Accedi ora</a> ]e usate il vostro nome utente e password del Webmaster<br />60 * collegatevi alla pagina d\'accesso e usate il vostro nome utente e password del Webmaster<br /> 61 61 * a questo punto sarete abilitati all\'accesso al pannello di amministrazione in cui troverete le istruzioni per l\'inserimento delle immagini nelle vostre directory'; 62 62 $lang['conf_mail_webmaster'] = 'Indirizzo email del Amministratore'; -
trunk/language/nl_NL/install.lang.php
r2865 r2902 60 60 $lang['install_help'] = 'Hulp nodig ? stel een vraag op het <a href="%s" target="_blank">Piwigo forum</a>.'; 61 61 $lang['install_end_message'] = 'Het installeren van Piwigo is klaar, de volgende stap is<br /><br /> 62 * Ga naar de Indentificatie pagina : [ <a href="identification.php">Indentificatie</a> ]gebruik hiervoor het eerder opgegeven gebruikersnaam met wachtwoord<br />62 * Ga naar de Indentificatie pagina en gebruik hiervoor het eerder opgegeven gebruikersnaam met wachtwoord<br /> 63 63 * Deze gebruikersnaam geeft u toegang tot de beheermenu zodat u afbeeldingen op uw website kan plaatsen'; 64 64 $lang['conf_mail_webmaster'] = 'Webmaster email adres'; -
trunk/template/yoga/picture.tpl
r2780 r2902 25 25 </div> 26 26 {/if} 27 28 {if !empty($PLUGIN_PICTURE_BEFORE)}{$PLUGIN_PICTURE_BEFORE}{/if} 27 29 28 30 <div id="imageHeaderBar"> … … 38 40 </div> 39 41 40 {if !empty($PLUGIN_PICTURE_BEFORE)}{$PLUGIN_PICTURE_BEFORE}{/if}41 42 <div id="imageToolBar"> 42 43 <div class="randomButtons"> … … 279 280 {/if} {*comments*} 280 281 281 282 283 282 {if !empty($PLUGIN_PICTURE_AFTER)}{$PLUGIN_PICTURE_AFTER}{/if}
Note: See TracChangeset
for help on using the changeset viewer.