I have uploaded some files (images) which I’d like to link in my own site as well as other places, but usually I try to host a different resolution of the same image to show up on other sites.
My problem with wordpress right now is that if I upload the file to WordPress’ upload directory through FTP, I don’t see the file show up in my media (in WP-admin). I can get a link from my ftp client (cyberDuck) but it doesn’t actually link me to a working link, also the link is something like this:
http://ftp.mydomain.com/really-link-file-name-with-20%-and-at-the-end-its.jpg
So I assume it works like that b/c it contains jpg at the end but it doesn’t work and takes me to a 404 page.
Any ideas of how I can go about uploading through an FTP client and get those files to show up on wordpress and also link correctly?
Try to avoid directly uploading via FTP. WordPress doesn’t scan your uploads folder for new images. Instead, use the built-in media uploader within WordPress to upload images. WordPress will automatically place them in the correct folder, create downsized versions you can use in a quick gallery or client sales page, and store the image’s meta information in the WordPress database.
The Media Gallery pulls its information from the WordPress database, so to see your uploaded images here, this is the only way to do it!
Your client is giving you an FTP link. If you use an FTP link in a web browser like Internet Explorer (i.e. ) your browser will act like an FTP client and try to download the image rather than displaying in in the browser. What you need is an actual HTTP link, which you can get from WordPress if you uploaded through the Media Gallery.
If you uploaded directly via FTP, your link would still be something like http://www.mydomain.com/wp-content/uploads/2010/11/something-something.jpg if you uploaded to the
/wp-content/uploads/2010/11/
directory. If you put it somewhere else, change the link accordingly.To Review
The correct way to add images to WordPress and get the links is through the Media Gallery:
“Add From Server” plugin might do what you want. It can scan a folder of files on the server and copy those files to the WordPress upload folder without having to go through the Media Uploader.
http://wordpress.org/extend/plugins/add-from-server/
What’s with that url? Its possible but confusing, did you install wordpress on a sub-domain named ftp or redirect the media folder to point there?
The easiest way is to just log into wordpress–>click Media–>upload a photo and copy the direct url to the image.
Two separate issues here:
in your FTP client you see [part of] real directory structure of your server, but your site works like web server sees it (focuses on site’s root directory, not server’s). To get working link you need to upload files in directory available to web server and use path relative to site root in URL;
files uploaded directly are not picked up by WP media library. For that to happen you need either use WP media upload functionality or import media using some plugin that can do that (I only remember W3 Total Cache by name, that does that for better CDN support functionality).
Just to add on:
First, you should definitely upload your files through WordPress Media. For bigger file such as mp4, I recommend using “Add From Server” plugin.
Second, instead of manually copy your file links, you can use
“Link to WordPress Files”, which help you link your content directly
to any files you want (PDF, MP4, DOCX..).
Hope it helps.
WordPress has the ability to automatically resize images you upload and will keep the different resolutions in the uploads directory. So instead of uploading different resolutions of the file through ftp, I would upload the original resolution of the file and let WordPress create the different sizes you need.
By default, WordPress will store 4 image sizes: thumbnail, medium, large, and original. You can define these sizes in the admin under Settings -> Media. If you need more sizes than that, you can define more in a plugin or in your theme’s functions.php by using the add_image_size() function:
You can find more on this function in the codex: http://codex.wordpress.org/Function_Reference/add_image_size