Trusted WordPress tutorials, when you need them most.
Beginner’s Guide to WordPress
WPB Cup
25 Million+
Websites using our plugins
16+
Years of WordPress experience
3000+
WordPress tutorials
by experts

Så här importerar du .docx-dokument i WordPress

Gillar du att skriva i Microsoft Word istället för WordPress? Vill du importera .docx-dokumentet i WordPress istället för att kopiera / klistra in vilket vanligtvis förstör formatet? I den här artikeln visar vi dig hur du importerar .docx-dokument i WordPress.

Docx to WordPress

Varför och när behöver du importera .docx-filer i WordPress på rätt sätt?

Vissa användare föredrar att skriva sina artiklar i Microsoft Word, som kommer med en built-in stavningskontroll, tesaurus, templates, stilar och format. WordPress standard visual editor erbjuder inte alla dessa funktioner.

Ett annat möjligt användningsscenario är gästbloggning. Om du ej vill ge gästförfattare tillgång till din WordPress admin area, skickar de ofta sina gästposter antingen i vanlig HTML eller i ett .docx-dokument.

Slutligen kanske du redan har en del content sparat i .docx-dokument. Att copy and paste från docx kan vara svårt, särskilt om du måste kopiera content från flera dokument.

Med detta sagt, låt oss se hur du kan importera .docx-dokument på rätt sätt i WordPress utan att bryta formatet.

Importera .docx-dokument i WordPress

Det första du behöver göra är att installera och aktivera pluginet Mammoth .docx converter. För mer detaljer, se vår steg-för-steg guide om hur du installerar ett plugin för WordPress.

Efter aktivering måste du skapa ett new post eller editera ett befintligt. På vyn för edit av post hittar du metaboxen Mammoth .docx converter under editor för post.

Mammoth docx converter in WordPress

Klicka bara på knappen Välj fil för att selecta en .docx-fil från din dator.

Så snart du väljer .docx-filen kommer pluginet att visa dig tre views för dokumenten. I tabben Visual ser du hur dokumentet kommer att se ut i WordPress.

Preview converted document

Du kommer att notera att det kommer att ignorera alla stilar som tillämpas på dina .docx-dokument som textfärg, bakgrundsfärg, padding, marginal, etc. Istället kommer det att låta ditt temas stylesheet kontrollera hur dessa saker ska visas.

Du kan också viewa den HTML som genereras av konvertern genom att clicka på knappen Raw HTML. You can click on the messages button to see if there were any warnings or errors during conversion.

Om du är nöjd med hur dokumentet ser ut i den visuella tabben kan du klicka på knappen ”Insert into editor”. Pluginet kommer att insert konverterad HTML i din WordPress post editor.

Du kan fortsätta att arbeta med posten. Om du är ny på WordPress, kanske du vill se vår guide om hur du lägger till ett nytt inlägg i WordPress och använder alla utvalda funktioner.

Mammoth .docx converter plugin konverterar en .docx-fil till ett rent HTML-format som är kompatibelt med WordPress. För närvarande stöder pluginet följande funktioner:

  • Headings som Heading 1, Heading 2, konverteras till h1,h2, etc.
  • Listor
  • Tabeller importeras utan format som gillar kant- och cellfärger
  • Vanlig HTML-format gillar fet, kursiv, superscript och subscript
  • Images som är embedda i dokument importeras till WordPress
  • Länkar
  • Textrutor konverteras till vanliga stycken

Pluginet gör inga ändringar i ditt ursprungliga .docx-dokument, det lagrar det inte ens på din WordPress webbplats.

Vi hoppas att den här artikeln hjälpte dig att importera .docx-dokument i WordPress. Du kanske också vill se vår guide om hur du embedar PDF, kalkylblad och andra dokument i WordPress.

Om du gillade den här artikeln, vänligen prenumerera på vår YouTube-kanal för WordPress video tutorials. Du kan också hitta oss på Twitter och Facebook.

Avslöjande: Vårt innehåll stöds av våra läsare. Det innebär att om du klickar på några av våra länkar, kan vi tjäna en provision. Se hur WPBeginner finansieras, varför det är viktigt, och hur du kan stödja oss. Här är vår editoriala process.

Avatar

Editorial Staff at WPBeginner is a team of WordPress experts led by Syed Balkhi with over 16 years of experience in WordPress, Web Hosting, eCommerce, SEO, and Marketing. Started in 2009, WPBeginner is now the largest free WordPress resource site in the industry and is often referred to as the Wikipedia for WordPress.

Den ultimata WordPress-verktygslådan

Få GRATIS tillgång till vår verktygslåda - en samling WordPress-relaterade produkter och resurser som varje professionell användare bör ha!

Reader Interactions

27 kommentarerLämna ett svar

  1. Syed Balkhi says

    Hey WPBeginner readers,
    Did you know you can win exciting prizes by commenting on WPBeginner?
    Every month, our top blog commenters will win HUGE rewards, including premium WordPress plugin licenses and cash prizes.
    You can get more details about the contest from here.
    Start sharing your thoughts below to stand a chance to win!

  2. Mrteesurez says

    Thanks for these, this is what I have been looking for as I used to write my posts offline, this will help me keep the format and style therein.
    Hope the plugin also works with Google docs on Mobile ?

  3. malcolm brigden says

    What this comment coyly neglects to mention is that you cannot use this plug in without having the $250 plan, as I found out to my chagrin after having read it and assumed the functionality I needed would be there with my $120 plan- I wonder what this chap was paid not to have mentioned this key fact in the first paragraph

    Malcolm Brigden MD

  4. Ahmed says

    I would like to know why when using plugin the other plugin like mammoth , which is docspress which import word press with all details as a short code , why the content is not appearing at all in SEO ENGINES as google

    • WPBeginner Support says

      For issues with a specific plugin, you would want to reach out to the support for that specific plugin and they should be able to assist.

      Administratör

  5. Marty says

    WordPress support installed this plug in and it does not input the images in the posts. It is no different than cutting and pasting. And actually it is more time consuming.

  6. Munna says

    Agree with Yoda. Just copy the article from wordpress and paste it on Visual editor . You don’t need any plugin for this.

  7. Ravinder says

    Hi Syed,

    I do not comment often on blog but today I got to upload blog post fast from .docx but didn’t know how to do it. Then I started searching on google and after 4 5 useless blog I came to this page and got answer to how to do it. Thanks :)

  8. Ted Sherwood says

    So glad I am signed up to your posts. I just finished a post in a fraction of the time it usually takes. Thanks.

  9. Hemang Rindani says

    There are two basic ways to export MS doc files to WordPress Content Management system, one through native server and two, with the help of FTP. Apart from this, WP also has some plugins where mammoth .docx converter is the one with maximum popularity. The effortless dashboard with this plugin makes it easier for a developer to transfer a .docx file to WP without losing the formatting of the file.

  10. Beni Iskandar says

    Thank you for this awesome trick, I write my raw article on notepad++ because when you block some of word in this app, you can check how many keyword and where you put it on paragraph .. Hmm it would be great if there build in word count tools.

  11. yuda says

    In what way is this different than a simple copy-paste from Word/Google Docs?

    It used to be that such direct copy/paste carried with it a lot of garbage – especially office-generated XML – plus a lot of visual hiccups. Nowadays this is not the case, at least not in 99% of the cases. So why still use a dedicated plugin? Am I missing something?

  12. farhang says

    wow!
    great article, im one of your fans that come to your website every day. best wp learning base ever

Lämna ett svar

Tack för att du väljer att lämna en kommentar. Tänk på att alla kommentarer modereras enligt våra policy för kommentarer, och din e-postadress kommer INTE att publiceras. Vänligen använd INTE nyckelord i namnfältet. Låt oss ha en personlig och meningsfull konversation.