Imithetho ye-WordPress Inezinto Ezingafani, Nazo

i-wordpress apache

i-wordpress apacheI-WordPress yenze igxathu elikhulu lokuziphendukela kwemvelo phambili epulatifomu lokubhuloga, ilisondeza eduze kohlelo oluphelele lokulawulwa kokuqukethwe ngokulandela ukubukeza, ukusekelwa okwengeziwe kwamamenyu wangokwezifiso, kanye nesici esiheha kakhulu kimi ukwesekwa kwamasayithi amaningi ngemephu yesizinda.

Uma ungeyena umphathi wohlelo lokuphathwa kokuqukethwe, kulungile. Ungeqa esedlule ngalesi sihloko. Kepha kuma-techno-geek engisebenza nawo, amakhanda-amakhodi nama-apache-dabblers, ngifuna ukwabelana ngento ethokozisayo, nokuthile okupholile.

I-Multi-site iyisici esikuvumela ukuthi usebenzise noma iyiphi inombolo yamawebhusayithi we-WordPress ngokufakwa okukodwa kwe-WordPress. Uma uphatha amasayithi amaningi, kuhle ngoba ungafaka iqembu elivunyelwe lamatimu namawijethi, bese ulenza lisebenze kumasayithi amaklayenti akho. Kunezithiyo ezimbalwa zobuchwepheshe ukudweba izizinda zakho, kepha inqubo ayinzima.

Enye yezindawo ezinenkinga engizibonile kungokwezifiso zetimu. Njengoba izingqikithi zingenziwa zitholakale kumawebhusayithi amaningi, noma ikuphi ukwenza ngokwezifiso okwenzayo kusihloko kuzothinta nanoma yimaphi amanye amasayithi asebenzisa leyo ngqikithi ekufakweni kwakho kwamasayithi amaningi. Indlela yami ezungeze lokhu ukuphinda itimu ngaphambi kokuthi ngiqale ukwenza ngezifiso, futhi ngichaze ngokusobala itimu yesayithi leklayenti engiyitayelayo.

Enye inkinga ethokozisayo yilokho okwenzekayo kufayela le-.htaccess kuseva yakho ye-Apache. I-WordPress idinga ukubhala kabusha izindlela ngesisekelo se-blog-by-blog futhi ikwenza lokhu ngomthetho wokubhala kabusha nefayela le-php.

I-WordPress isebenzisa umthetho olandelayo wokubhala kabusha:

Phinda ubhaleRule ^ ([_ _ 0-9a-zA-Z -] + /)? Amafayela /(.+) wp-includes / ms-files.php? File = $ 2 [L]

Empeleni, noma yini esekhompyutheni engaphansi kwe-mysite.com/files/directory ibhalwa kabusha ku-mysite.com/files/wp-includes/myblogfolderpath ....... futhi kulapho ithakazelisa khona. Kwenzekani uma empeleni udinga ukuba nefayela kuseva yakho okuyi-mysite.com/files/myfolder/myimage.jpg? Uthola iphutha elingu-404, yilokho okwenzekayo. Umthetho wokubhala kabusha we-Apache uyangena futhi ushintshe indlela.

Kuyavunywa, ungahle ungalokothi ubhekane nale nkinga, kepha ngenzile. Benginengosi edinga ukusebenzisa iwijethi yejavascript evela kwenye iwebhusayithi, futhi ibidinga ukuthola ihluzo ku-mysite.com/files/Images/myfile. Njengoba ibingekho indlela yokushintsha ifayili kusayithi le-Host, bengidinga ukuthola indlela yokwenza lokhu kuseva yami. Isixazululo esilula ukudala isimo sokubhala kabusha esenza okuhlukile kumafayili athile.

Nansi ikhambi:

Phinda ubhale kabushaCond% {REQUEST_URI}! /? Files / Image / file1.jpg $
Phinda ubhale kabushaCond% {REQUEST_URI}! /? Files / Image / file2.jpg $
Phinda ubhaleRule ^ ([_ _ 0-9a-zA-Z -] + /)? Amafayela /(.+) wp-includes / ms-files.php? File = $ 2 [L]

Izimo zokubhala kabusha kufanele zibekwe ngaphambi komthetho wokubhala kabusha, noma leli qhinga ngeke lisebenze. Kufanele kube lula ukuguqula lesi simo ngezinjongo zakho, uma ungahlangabezana nenkinga efanayo. Isixazululo singisebenzele kahle, sangivumela ukuthi ngifake imidwebo yangokwezifiso esikhundleni sombhalo we-alt ongathandeki kangako ongahambelani nomklamo wami. Sethemba ukuthi kuzokusebenzela nawe.

UCABANGANI?

Le sayithi isebenzisa i-Akismet ukunciphisa ugaxekile. Funda ukuthi idatha yakho yokuphawula isetshenziswa kanjani.