WordPress: MySQL Tshawb Nrhiav thiab Hloov Hloov siv PHPMyAdmin

wordpress

Kuv tau hloov kho me ntsis rau kuv nplooj ntawv txheej txheem hnub no. Kuv twb nyeem rau John Chow blog thiab nyob rau Problogger lub blog qhov muab tso rau koj tshaj tawm hauv lub cev ntawm kev tshaj tawm yuav ua rau muaj kev nce nyiaj hauv cov nyiaj tau los. Dean tab tom ua haujlwm ntawm nws ib yam nkaus.

Ntawm Darren lub vev xaib, nws sau tias nws tsuas yog teeb meem ntawm qhov kev nyeem qhov muag txav. Thaum lub chij nyob rau saum toj ntawm nplooj ntawv, tus nyeem ntawv hla nws uas tsis muaj kev ua kom pom tseeb. Txawm li cas los xij, thaum kev tshaj tawm mus rau sab xis ntawm cov ntsiab lus, tus nyeem ntawv yuav ua tiag hla nws.

Koj yuav pom tias kuv tseem sim ceev kuv cov nplooj ntawv hauv tsev - tso kev tshaj tawm sab nraud ntawm cov ntawv blog. Kuv paub tseeb tias kev hloov ntawd thiab ua rau lawv nkag mus ntxiv yuav ua rau kuv tau nyiaj los ntxiv; txawm li cas los xij, Kuv ib txwm tawm tsam qhov ntawd vim tias nws yuav cuam tshuam tiag tiag cov neeg nyeem kuv hlub txog feem ntau - cov uas tuaj xyuas kuv qhov home page txhua hnub.

Ib qho teeb meem nrog tso cov tshaj tawm no rau hauv txoj cai sab saum toj yog tias qhov no yog qhov uas kuv feem ntau tso cov duab rau cov kev ua kom zoo nkauj thiab hnav kuv pub thiab cais nws los ntawm lwm qhov txauCov. Kuv feem ntau yog ua lwm daim clipart los yog sab xis lossis sab laug hauv kev xa ntawv uas siv:

Daim duab sab laug:


Duab Muaj Cai:


Nco tseg: Qee tus pej xeem nyiam siv cov cwj pwm rau qhov no, tab sis cov kawm tuab si lug tsis ua haujlwm hauv koj qhov kev siv noj CSS.

Hloov tshiab txhua tus ncej siv Tshawb Nrhiav thiab Hloov:

Yuav kom yooj yim hloov kho ib qho duab nyob hauv txhua tus ncej kom paub meej tias tag nrho kuv cov duab sab laug tuaj yeem ua tau yooj yim siv cov lus nug hloov tshiab hauv PHPMyAdmin rau MySQL:

hloov kho table_name teeb table_field = hloov (table_field, 'replace_that', 'with_this');

Tshwj xeeb rau WordPress:

hloov tshiab `wp_posts` teeb `post_content` = hloov (` post_content `, 'hloov_that', 'with_this');

Txhawm rau kho kuv qhov teeb meem, Kuv tau sau cov lus nug los hloov "duab = 'txoj cai'" nrog "duab = 'sab laug'".

NCO TSEG: Nco ntsoov meej kiag li los backup koj cov ntaub ntawv ua ntej ua qhov hloov tshiab no !!!

16 Comments

  1. 1
  2. 3

    Ua tsaug rau muab cov ntaub ntawv ntxiv ntawm cov ncauj lus no. Kuv tau pom cov ntawv tshaj tawm sab laug lossis sab xis ua ntej ntawm lwm lub vev xaib kom nws zoo li yog qhov chaw nrov. Koj cov ntawv tshaj tawm ntws tawm ntawm sab xis ntawm txoj cai.

    Kuv tuaj yeem hloov mus rau txoj cai qhia kuv cov tshaj tawm dhau rau yav tom ntej. Nws yuav nthuav kom pom tias ib qho nyiaj tau los ntxiv yog tshwm sim los.

    • 4

      Kuv yuav mus twv yuav raug hu lawv. Tshaj tag nrho cov kev xav tau qis me ntsis tam sim no, yog li cov nyiaj tau los kuj poob qis. Kuv yuav muab ob peb lub lim tiam kom pom! Kuv yuav nco ntsoov qhia rau nws.

  3. 5

    Koj puas tau txais dab tsi nrog cov chij tshaj tawm ntawm koj qhov nplooj ntawv ntsuas, Doug? Kuv tsis tau ua zoo rau lawv.

    Feem ntau, cov kev tshaj tawm xov xwm (180 thiab 250 dav) thiab qhov kev tshaj tawm tom qab kev tshaj tawm (336 dav) tau txais ntau tshaj plaws.

  4. 7
  5. 9

    muaj qhov teeb meem los hloov thib ob nrog "txoj cai" koom nrog hauv mysql
    HLOOV TSHIAB ivr_data QHOV CAI (ROOJ, 2) = '00' QHOV ROOJ (LUB SIJ HAWM, 2)! = '00';

  6. 10

    Hav Doug. Tsuas yog siv koj cov lus qhia txhawm rau hloov kho kuv tus email chaw nyob hauv kuv tus WP DB. Ua haujlwm zoo li ntxim nyiam. Ua Tsaug.

    BTW, tuaj hla no ncej hauv Google, tshawb "siv mysql tshawb nrhiav cov lus nug hloov." Tuaj Txog 3rd.

    • 11

      Woohoo! Thib 3 zoo! Kuv tus xaib zoo li tau pom qee qhov kev tso kawm zoo hauv Kev Tshawb Xyuas Kev Tshawb Fawb tshaj xyoo tas los. Ironically, Kuv rank saum toj no ntau Search Engine Blogs. 🙂

  7. 12

    qhov no zoo ua hauj lwm zoo dua rau kuv mysql… ..

    HLOOV TSHIAB wp_posts SET post_content = hloov (post_content, 'hloov no', 'nrog qhov ntawd');

  8. 13

    Qhov no ua haujlwm rau kuv

    HLOOV TSHIAB wp_posts SET post_content = REPLACE (post_content, 'www.alznews.net', 'www.alzdigest.com');

    tej zaum qhov 'hloov' xav tau los ntawv nqis peev

  9. 14
  10. 15

    Ua tsaug! Mine hais kom siv "tsis yog" puag ncig qhov nrhiav thiab hloov cov ntawv sau. Kuv tau siv nws txav tag nrho cov ntaub ntawv SQL ntawm ib lub vev xaib mus rau lwm qhov. Nws tau khaws ntau yam haujlwm!

  11. 16

    Kuv nyuam qhuav xav hloov cov hlua tsis pub dhau MySQL ntawm yoov, tab sis daim teb yuav ntim tau 2 yam khoom. Yog li kuv qhwv REPLACE () nyob rau hauv REPLACE (), xws li:

    REPLACE (REPLACE (field_name, "yam peb tab tom nrhiav", "hloov thawj yam") "" lwm yam peb tab tom nrhiav "," hloov thib ob ")

    Nov yog ib qho syntax uas kuv tau siv los tshawb txog tus nqi boolean:

    HLOOV (HLOOV (teb, 1, "Yog"), 0, "Tsis muaj")

    Vam tias qhov no yuav pab!

Yuav ua li cas koj xav hais tias?

Qhov Web site no siv Akismet los txo cov kev pabcuam. Kawm li cas koj cov ntaub ntawv tawm tswv yim tiav.