Autore Topic: De-Generator ... direttamente dalla soffitta  (Letto 38659 volte)

serzio

  • Amministratore
  • Utente storico
  • *****
  • Post: 1706
Re:De-Generator ... direttamente dalla soffitta
« Risposta #60 il: 29 Ottobre, 2012, 18:49:35 »
Prova a modificare il codice come segue, aggiungendo la riga evidenziata:

(Attachment Link)


Ciao e grazie dell' aiuto, ho fatto quello che mi hai suggerito e quando ho richiamato il degenerator mi è apparsa questa schermata - contatti.php Fatal error: Call to undefined function chomod() in /web/htdocs/www.grafikoweb.it/home/degenerator.php on line 11


chomod ??? ??

chmod !!!!

 ;)

PierBin

  • Utente esperto
  • ***
  • Post: 323
Re:De-Generator ... direttamente dalla soffitta
« Risposta #61 il: 29 Ottobre, 2012, 18:52:42 »
chomod ??? ??

chmod !!!!

 ;)


Ok hai ragione funziona GRAZIE MILLE  ;) , ultima cosa ma questa modifica è valida su tutti i server linux aruba, o bisogna vedere server x server.
Grazie ancora

serzio

  • Amministratore
  • Utente storico
  • *****
  • Post: 1706
Re:De-Generator ... direttamente dalla soffitta
« Risposta #62 il: 29 Ottobre, 2012, 18:55:08 »
chomod ??? ??

chmod !!!!

 ;)


Ok hai ragione funziona GRAZIE MILLE  ;) , ultima cosa ma questa modifica è valida su tutti i server linux aruba, o bisogna vedere server x server.
Grazie ancora

Diciamo che con le sue infinite modifiche siamo arrivati ad un codice abbastanza standard. L'unica differenza potrebbe esserci tra win e linux.

PierBin

  • Utente esperto
  • ***
  • Post: 323
Re:De-Generator ... direttamente dalla soffitta
« Risposta #63 il: 29 Ottobre, 2012, 19:00:03 »
chomod ??? ??

chmod !!!!

 ;)


Ok hai ragione funziona GRAZIE MILLE  ;) , ultima cosa ma questa modifica è valida su tutti i server linux aruba, o bisogna vedere server x server.
Grazie ancora

Diciamo che con le sue infinite modifiche siamo arrivati ad un codice abbastanza standard. L'unica differenza potrebbe esserci tra win e linux.


GRAZIE ancora ciao

Zambelletti

  • Utente esperto
  • ***
  • Post: 482
Re:De-Generator ... direttamente dalla soffitta
« Risposta #64 il: 24 Gennaio, 2013, 12:43:29 »
Buon giorno a tutti.
Su Hosting linux non ho avuto problemi, su Ruba con hosting windows, sto avendo problemi, nel senso che nel codice html, non vedo il meta name generator.


Però quando richiamo il file php, visualizzo questo :



degenerator.php not ok![/size]imsearch.php Warning: rename(imsearch.php,imsearch.php.old) [function.rename]: File exists in D:\Inetpub\webs\sitoit\degenerator.php on line 5ok!imsitemap.html Warning: rename(imsitemap.html,imsitemap.html.old) [function.rename]: File exists in D:\Inetpub\webs\sitoit\degenerator.php on line 5ok!index.html Warning: rename(index.html,index.html.old) [function.rename]: File exists in D:\Inetpub\webs\sitoit\degenerator.php on line 5ok!pagina-1.html Warning: rename(pagina-1.html,pagina-1.html.old) [function.rename]: File exists in D:\Inetpub\webs\sitoit\degenerator.php on line 5ok!pagina-2.html Warning: rename(pagina-2.html,pagina-2.html.old) [function.rename]: File exists in D:\Inetpub\webs\sitoit\degenerator.php on line 5ok!pagina-3.html Warning: rename(pagina-3.html,pagina-3.html.old) [function.rename]: File exists in D:\Inetpub\webs\sitoit\degenerator.php on line 5ok!


p.s.
Ho modificato tutti i permessi, e ho modificato così il file php :



<?php


function evirator($webpage) {
   if ($webpage != "degenerator.php") {
      rename ($webpage, $webpage . ".old");
      $new_webpage= $webpage;
      $webpage = $webpage . ".old";


      $fp = fopen ($webpage, "r");
      $fp_out = fopen ($new_webpage, "w");
                chmod($new_webpage, fileperms ($webpage));


      while (! feof($fp)) {
         $riga = fgets($fp,1024);
         if (!stristr($riga,'<meta name="Generator" content=')) {
            fwrite($fp_out, $riga);
         }
      }


      fclose ($fp);
      fclose ($fp_out);


      echo " ok!<BR>";
   } else {
      echo " not ok!<BR>";
      }
}


$dirname=getcwd().'\\public\\..\\';
$array_ext=array('.html','.php');


$handle = opendir($dirname);


while (false !== ($file = readdir($handle))) {
   if(is_file($dirname.$file)){
      $ext = strtolower(substr($file, strrpos($file, "."), strlen($file)-strrpos($file, ".")));
      if(in_array($ext,$array_ext)){
         echo "$file    ";
       evirator($file);
      }
   }
}


$handle = closedir($handle);
   
?>




Chi sa aiutarmi?
Grazie"!
« Ultima modifica: 24 Gennaio, 2013, 12:47:15 da Pasquale D. »

milux

  • Moderatore globale
  • Utente storico
  • *****
  • Post: 1779
    • 3MD
Re:De-Generator ... direttamente dalla soffitta
« Risposta #65 il: 24 Gennaio, 2013, 13:31:37 »
Buon giorno a tutti.
Su Hosting linux non ho avuto problemi, su Ruba con hosting windows, sto avendo problemi, nel senso che nel codice html, non vedo il meta name generator.


ma sull'hosting windows è attivo il php?
**OS : Windows 7 - 63Bit (uno è andato perso e non lo trovo..) + W10
**Website X5 :  Evo 10(active) - Evo 11(active) - 13(active)
**Wysiwyg Web Builder 12 (passa al lato oscuro..)
**Hosting : LINUX
**Editor : Notepad ++ / Geany

Zambelletti

  • Utente esperto
  • ***
  • Post: 482
Re:De-Generator ... direttamente dalla soffitta
« Risposta #66 il: 24 Gennaio, 2013, 13:41:41 »
pare di si,

milux

  • Moderatore globale
  • Utente storico
  • *****
  • Post: 1779
    • 3MD
Re:De-Generator ... direttamente dalla soffitta
« Risposta #67 il: 24 Gennaio, 2013, 13:43:08 »
pare, parebbe o ne sei sicuro al ciento pe ciento...?

**OS : Windows 7 - 63Bit (uno è andato perso e non lo trovo..) + W10
**Website X5 :  Evo 10(active) - Evo 11(active) - 13(active)
**Wysiwyg Web Builder 12 (passa al lato oscuro..)
**Hosting : LINUX
**Editor : Notepad ++ / Geany

Zambelletti

  • Utente esperto
  • ***
  • Post: 482
Re:De-Generator ... direttamente dalla soffitta
« Risposta #68 il: 24 Gennaio, 2013, 13:53:32 »
verifico
« Ultima modifica: 24 Gennaio, 2013, 13:58:11 da Pasquale D. »

lemonsong

  • Anziani
  • Utente storico
  • *
  • Post: 1867
    • lemonsong's world
Re:De-Generator ... direttamente dalla soffitta
« Risposta #69 il: 24 Gennaio, 2013, 14:02:44 »
Pare che "un po' di php" ce l'hai:

www.fabrizioamorosoarchitetto.it/imsearch.php

Hai letto tutto il topic?

Sono il meno adatto per esprimermi su questo linguaggio ma nei primi post si parla di Aruba e Windows.



Zambelletti

  • Utente esperto
  • ***
  • Post: 482
Re:De-Generator ... direttamente dalla soffitta
« Risposta #70 il: 24 Gennaio, 2013, 14:14:22 »
Pare che "un po' di php" ce l'hai:

www.fabrizioamorosoarchitetto.it/imsearch.php

Hai letto tutto il topic?

Sono il meno adatto per esprimermi su questo linguaggio ma nei primi post si parla di Aruba e Windows.


Ho letto tutto, e ho fatto tutto!
il php, mi dicono che c'è, solo che è su hosting windows.

Zambelletti

  • Utente esperto
  • ***
  • Post: 482
Re:De-Generator ... direttamente dalla soffitta
« Risposta #71 il: 23 Maggio, 2013, 10:50:24 »
Buon giorno, scusate......
per farlo funzionare anche con la versione 10, debbo fare qualcosa?


oppure funziona coma la 9?


Grazie!

Topografo

  • Utente esperto
  • ***
  • Post: 264
Re:De-Generator ... direttamente dalla soffitta
« Risposta #72 il: 05 Luglio, 2013, 19:53:41 »
Ho una domanda...
Ma se modificassi la riga

Citazione
<?php

function evirator($webpage) {
    if ($webpage != "degenerator.php") {
        rename ($webpage, $webpage . ".old");
        $new_webpage= $webpage;
        $webpage = $webpage . ".old";

        $fp = fopen ($webpage, "r");
        $fp_out = fopen ($new_webpage, "w");

        while (! feof($fp)) {
            $riga = fgets($fp,1024);
            if (!stristr($riga,'<meta name="Generator" content=')) {
                fwrite($fp_out, $riga);
            }
        }

        fclose ($fp);
        fclose ($fp_out);

        echo " ok!<BR>";
    } else {
        echo " not ok!<BR>";
        }
}

$dirname='./';
$array_ext=array('.html','.php');

$handle = opendir($dirname);

while (false !== ($file = readdir($handle))) {
   if(is_file($dirname.$file)){
      $ext = strtolower(substr($file, strrpos($file, "."), strlen($file)-strrpos($file, ".")));
      if(in_array($ext,$array_ext)){
         echo "$file    ";
         evirator($file);
      }
   }
}

$handle = closedir($handle);
   
?>

In qualcosa del tipo             
Citazione
if (!stristr($riga,'<meta name="Generator" content=')) then $riga="<meta name="generator" content="Incomedia WebSite X5 Evolution 11.0.0.0000" />
" {

O l'equivalente (non in basic) posso cambiare il valore della stringa?

stesil

  • Anziani
  • Utente storico
  • *
  • Post: 1219
    • quellidelcucuzzolo
Re:De-Generator ... direttamente dalla soffitta
« Risposta #73 il: 07 Luglio, 2013, 22:01:59 »
Ma a che ti serve cambiare quella stringa? Posso capire toglierla, ma cambiarla .. mah ...

Comunque così dovrebbe funzionare:

Codice:
Only registered users can see contents. Please click here to Register or Login.

Topografo

  • Utente esperto
  • ***
  • Post: 264
Re:De-Generator ... direttamente dalla soffitta
« Risposta #74 il: 07 Luglio, 2013, 22:17:23 »
In effetti non serve... è un idea bislacca...
Ma era interessante scrivere una versione inesistente di WS X5 (es. WS X6) e poi chiedere a quelli dell'official come mai non mi funzionava il codice...  :D