Home › Forum › Problemi Vari con WP › Permanent Link con IIS
-
AutorePost
-
-
9 Agosto 2008 alle 13:23 #7552olGervaPartecipante
GoodWeb
Dopo aver letto diversi post, pagine di siti, la stessa ufficiale di Wp…..
ho applicato le due diverse modalità che ho ritenuto più interessanti:
la prima con il file php.ini e la seconda con la gestione della pagina 404 di IIS
ma in entrambi i casi non riesco cmq a vedere lemie pagine se attivo l’opzione specifica.
chi mi può dare una mano a capire il perchè della cosa
Windows 2000 Server con IIS | PhP 4.3 | MySQL 4.02.x
PS: premetto che è la prima volta che installo WP
Grazie a tutti
-
9 Agosto 2008 alle 15:16 #56689SteveAglAmministratore del forum
se magari dettagli perchè parli di permalink poi di pagina 404 e php.ini… in ogni caso non possiamo dare supporto su IIS se è un problema di configurazione del server. Ci sono forum appositi.
-
10 Agosto 2008 alle 10:29 #56701olGervaPartecipante
GoodWeb,
grazie per l’interesse, scusa hai ragione ho scritto male il termine Permalinks e non Permanent come nel titolo, la fretta ……
Ho deciso di usare WP su un Win2000 server, dove ho installato PhP 4.3 e MySQL 4.02.
L’installazione dello stesso WP tutto OK, funziona tutto per l’ipressione che ne ho avuto data la mia poca dimestichezza con il prodotto.
Volendo impostare URL frendly per i motoi di ricerca, ho attivato nelle impostazioni della console
la funzione Permalinks, che da quanto ho capito permette di richiamare una pagina non visualizzando la variabile “?….” della stessa pagina , ma con un “alias” della pagina, sfruttando la funzione Permalinks.
Ora se su linux le cose vanno lisce grazie alle caratteristiche di Apache e al file htaccess, su windows le cose sono meno immediate.
Dopo aver girovagato sulla rete, nei diversi post ho trovato alcune soluzioni che ho testato, ma seza successo e qui il problema. Ho scelto le due soluzioni meno invasive senza dover instalare DLL o altro.
La prima soluzione è stata quella di creare un file php.ini nella root del mio sito e impostare due righe di codice, come suggerito dalla stessa WP:
“…. add these 2 lines to a php.ini file and store that file in your webroot
-
10 Agosto 2008 alle 10:34 #56702olGervaPartecipante
opss, mi ha tagliato il post….
-
10 Agosto 2008 alle 10:36 #56706olGervaPartecipante
cgi.fix_pathinfo = 1
cgi.force_redirect = 0
..."
La seconda quela di creare un file wp_error.php, facendo puntare IIS alla stessa che caso di errore 404 come URL.
" ....
<?
$qs = $_SERVER;
$_SERVER = substr($qs, strpos($qs, ':80')+3);
$_SERVER = $_SERVER;
include('index.php');
?>
"
Nel primo caso php.ini, WP mi ritorna come risultato della pagina/articolo info (installata di default che ha come link originale "collabora.it/?page_id=2") come contenuto visuale/testuale "Non trovato e subito sotto il campo di ricerca" e come link "collabora.it/index.php/info/"
Nel secondo caso invece ho come risultato visuale/testuale "Error 404 - Non trovato senza campo ricerca" e come link di destinazione "collabora.it/index.php/info/"
A questo punto non riesco a capire dove io possa sbagliare o se sussiste un errore di concetto o funzionalità del server.
Spero di essere stato più chiaro stavolta e ringrazio per la disponibilità .`
-
10 Agosto 2008 alle 10:41 #56704wollyAmministratore del forum
nel wiki trovi come abilitare i permalinks su iis
-
10 Agosto 2008 alle 13:36 #56708olGervaPartecipante
Grazie, ho provato a ricercare dove mi hai suggerito, ma senza esito…
Mi daresti il link diretto?
Cmq io ho seguito i suggerimenti che il sito codex.wordpress.org/Using_Permalinks, essendo la fonte ufficiale credo che siano anche attendibili.
-
10 Agosto 2008 alle 13:50 #56709olGervaPartecipante
mmmmm ….. risolto !!!
curiosando ulteriormente ho beccato questo link keyboardface.com/iis-permalinks/ e seguendo quello che suggerisce (un file htaccess.php e uno errorpage.asp) le cose fungono, anche se mi sembra un pelo lentino ….
cmq anche se avrei preferito capire e risolvere il problema alla fonte, diciamo che per iniziare questo può anche andar bene
Se ci sono risposte alternative sono ben accette
Grazie
-
10 Agosto 2008 alle 17:44 #56718SteveAglAmministratore del forum
potresti provare ad installare su IIS un modulo per la riscrittura degli URL in modo da farlo comportare come Apache e fargli supportare i file .htaccess
Ci sono diversi moduli disponibili, e la maggior parte sono a pagamento, però qualche mese fa ne avevo trovato uno free che era anche indicato per WordPress e mi pare che è segnalato nel link che ti ho dato, solo che al momento il sito non è raggiungibile.
-
11 Agosto 2008 alle 6:49 #56732olGervaPartecipante
Si grazie, questo link l’avevo gia visto.
Il fatto è che su questo server ci sono diverse applicazioni appoggiate a un Content Management CMScontrol e non vorrei poi avere problemi con le stesse.
Preferisco trovare e utilizare una soluzione che non preveda nessuna installazione di librerie o altro simile, ma che operi solo ed unicamente nella root del sito e che si basi su eventuali file nella stessa root.
Cmq ho risolto come puoi vedere sopra, mi rimane da capire perchè non funzionino tutte e tre le soluzioni suggerite oltre al fatto che mi sembra un pelo lentina l’esecuzione….
Probabilmente la mia inesperienza …….
Grazie
-
11 Agosto 2008 alle 11:01 #56739SteveAglAmministratore del forum
Preferisco trovare e utilizare una soluzione che non preveda nessuna installazione di librerie o altro simile, ma che operi solo ed unicamente nella root del sito e che si basi su eventuali file nella stessa root.
premetto che non conosco molto bene IIS, però in linea generale credo che qualsiasi soluzione diversa dall’installazione di uno di quei moduli che ti ho segnalato – ammesso che sia fattibile – ti può dare problemi di lentezza e/o di instabilità , perché a quanto ho capito quella su keyboardface è una soluzione lenta perché basata su diversi include prima di visualizzare la pagina giusta.
Io farei una prova con uno di quei moduli, se le altre applicazioni non usano permalink, .htaccess e roba simile, non dovrebbero avere problemi.
IIS Mod-Rewrite per esempio può essere attivato per i siti che necessitano di htaccess e disattivato per quelli che non ne hanno bisogno.
-
-
AutorePost
- Devi essere connesso per rispondere a questo topic.