Vill du allow användare att attachment bilder och filer i WordPress kommentarer?
Images och comments är båda kraftfulla tools för att öka engagemanget hos användarna på din site i WordPress. Beroende på din webbplats nisch och målgrupp kan det öka användarnas engagement på din site avsevärt om du tillåter visitorerna att uppladdare images i comments.
I den här artikeln kommer vi att visa dig hur du tillåter användare att uploada images i WordPress comments.
Varför allow users to upload images in WordPress Comments?
WordPress comments är ett bra sätt att kommunicera med dina besökare. Folk lämnar återkoppling, ställer frågor och ger rekommendationer som kan vara användbara för att bygga ditt varumärke och förbättra produkter.
Att allow användare att uploada images i comments kan ytterligare förbättra användarupplevelsen. Besökare kan till exempel dela screenshots av sina problem i kommentarerna, vilket ger ditt support team mer information för att lösa deras problem.
På samma sätt kan det hjälpa till att starta engagerande diskussioner där människor kan dela roliga bilder och memes. Detta kommer att bidra till att göra your comments visuellt tilltalande och roligare att läsa.
Eller om du runar en blogg om resor kan det hjälpa till att samla in användargenererat content om du allow images i comments. Användare kan till exempel dela med sig av bilder från sina favoritdestinationer, platser de besökt och mycket mer.
Med detta sagt, låt oss se hur man allow image uploads i WordPress comments.
Video Tutorial
Om du föredrar skriftliga instruktioner är det bara att fortsätta läsa.
Allow Users to Upload Images in WordPress Comments (Tillåt användare att uppladare Images i WordPress kommentarer)
Det första du behöver göra är att installera och aktivera DCO Comment Attachment plugin. För mer detaljer, se vår Step-by-Step guide om hur du installerar ett plugin för WordPress.
Vid aktivering kommer pluginet att fungera ur boxen och lägga till ett alternativ för filuppladdning i WordPress comments area.
Du kan edit dess inställningar genom att gå till Settings ” DCO Comment Attachment från din WordPress dashboard.
Pluginet låter dig ställa in en maximal upload-filstorlek, göra det till ett krav att bifoga filer, embed bilagor, välja en bifogad image-storlek och mer.
You can also allow your users to attach different file types, like a document, PDF, PowerPoint presentation, excel spreadsheet, and more by checking the file type option.
Det finns också ett alternativ att select all användare eller bara allow logged in users to upload attachments in WordPress comments.
När du har gjort ändringarna, glöm inte att clicka på knappen ”Save Changes”.
Efter det, head över till någon post page på din WordPress blogg, och du kommer att se en image uppladdningsfält i kommentarerna området gillar skärmdumpen under:
Alla images som uppladdats av användare lagras i ditt mediabibliotek i WordPress. Om du vill ta bort en image som har laddats upp av en användare måste du gå till Media ” Bibliotek, lokalisera imagen och sedan ta bort den.
Detta kommer att borttaga image från comment utan att påverka kommentartexten.
För att undvika missbruk av den här funktionen rekommenderar vi att du lägger till några riktlinjer för kommentarer på din site för att låta användarna veta vilken typ av attachments de kan uploada. Du kan kontrollera WPBeginners sida för kommentarpolicy för ett exempel.
You can then add a link to your comment policy text in the WordPress comment form.
På grund av images karaktär kanske du vill granska all comments innan de visas på din site. Du kan göra detta genom att aktivera moderation av kommentarer och meddela användare när deras kommentar har godkänts på din site.
För att ytterligare öka media capabilities i dina comments kan du aktivera oEmbed support för comments i WordPress. Detta kommer att tillåta dina användare att embedda YouTube-videor, tweets, Flickr-bilder och mer tillsammans med de images de uploadar.
Vi hoppas att den här artikeln hjälpte dig att lära dig hur du tillåter användare att uploada images i WordPress comments. Du kanske också vill se våra tips om hur du får fler comments på dina blogginlägg i WordPress, och hur du startar en online store.
If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.
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!
Mike Avery says
There seems to be a new comment attachment plugin called, ”DCO Comment Attachment”,
Have you tried it yet? Can you recommend it?
WPBeginner Support says
For the moment we have not tested that specific plugin
Administratör
sr says
Any updates for ways to allow comments to upload photos and docs easily?
WPBeginner Support says
Not at the moment but once we find something we will certainly update the article
Administratör
Geoff says
I have 4 pages on my website how do i just add the comment plugin to work on just one page? thanks
WPBeginner Support says
Apologies, the plugin we are currently recommending is no longer available. We will be sure to update the article with an alternative when we are able, after which we would be able to look into conditional loading.
Administratör
Monir says
thank you, this article was really helpful!
WPBeginner Support says
You’re welcome, glad our guide was helpful
Administratör
Phoebe Moon says
The plug in is no longer available.
WPBeginner Support says
Thanks for letting us know about that, we’ll be sure to look for an alternative
Administratör
Jane Beinart says
Is it possible to post photos this way via your mobile phone? I’m finding that posting photos via the computer is fine, but via iphone just gets an error message and says it is the wrong format of image. Any ideas as to how to make this work?
WPBeginner Support says
It would depend on the file type of image that is being sent. If it is one of your allowed file types you would want to reach out to the support for the plugin to let them know and they should be able to assist.
Administratör
Rachael says
Is there anyway to filter the most top liked pictures to the top of the page?? Also is there a way for other users to reply to the comment? This worked but isn’t functioning the way I would like it to….
WPBeginner Support says
It should allow people to reply the same way they would reply to a normal content but for what you’re asking for may require a custom plugin.
Administratör
omer noiman says
Hey, I did everything as described.
when i am trying to test this, and upload an image, it redirects me to page 404
”
The page you are looking for might have been removed, had its name changed, or is temporarily unavailable. Please try another search …
”
WPBeginner Support says
Hi Omer,
Try updating your permalink structure. Simply visit Settings » Permalinks and then click on the save changes button without changing anything.
Administratör
Heidi says
Hi, I am also having a page not found issue when trying to test this out by posting a comment with an image. The plugin support seems MIA. I did try what you suggested about the permalinks and I still can’t get my image to post. Any ideas? Thanks.
WPBeginner Support says
You may want to check with your hosting provider that you are not hitting a memory limit as one possibility.
Heidi says
Thanks, that wasn’t it, unfortunately.
Michael Vivar says
Quick question. If I have an existing comment widget and I install ”Comment Attachment”, will existing comments be affected?
Chaz DeSimone says
Fantastic plugin for uploading photos with recipes submitted by readers…until we install a ”real” recipes plugin. Thank you!
Monique says
This only works if you have a business wordpress account!
WPBeginner Support says
Hi Monique,
This tutorial is for self-hosted WordPress.org websites. Please see our guide on the difference between self hosted WordPress.org vs free WordPress.com blog.
Administratör
Hossein says
Hi
May I know what is the plugin that you use for subscribing to comments?
Thanks
WPBeginner Support says
Hi Hossein,
Please see our article on how to allow users to subscribe to comments in WordPress.
Administratör
Rod Fleming says
If it’s a hosted site and you are Admin, just click on the img button and enter the URL of the image. For a local image, first upload to the Media Library and copy the URL. Paste that into the img dialogue box in the comment section and add an alt tag when prompted. No Plug-in required.
I can’t remember how long this has been available in WP but it’s a long time; I’ve been a user for nearly 10 years and it’s always been like this.
Manasa says
The wordpress website/s that I post comments to do not have the Upload Image option even though I know that users have posted images and so has the author/writer. But I do not know how else to upload an image without that option while posting comments.
Mac says
Why have you not enable the option of putting up images,while commenting?
Traruh Synred says
On a blog I post too I can’t load images. Others commenters do load images. They in could a link to the image.
This doesn’t work for me. Yet the blog does allow images.
I’ve tried various links in both email response and using WordPress reply. Niether works.. If I embed an image in an email it gets stripped out.
I assume I’m doing something wrong, but can’t figure out what?
E.g.,
Amber says
In Facebook, when you add a URL, it automatically sources the image for you. Is there a way to do that in WordPress comments?
M.Khurram says
On installation process this is happening
Unable to create directory wp-content/uploads/2015/03. Is its parent directory writable by the server?
Pamela says
nice to be able to upload but the images are huge… they don’t retain their original size why??? can this be rectified so images stay in their original size??
Marcus says
While this is certainly a great way to boost user engagement, on some hosting platform this can pose a serious security issue. It is surprisingly simple to disguise a php script as a gif image. I strongly suggest using plugins like these only in combination with some .htaccess magic preventing scripts from being executed within your uploads folder. Especially on shared hosting platforms.