0
votes
0answers
15 views

Change default options on attachment page

I'm currently adjusting someone's plugin, and they're pulling data from the attachment page. Rather than edit the whole plugin entirely, I'm after a quick fix. Is it possible to change the wording on ...
0
votes
0answers
40 views

How to show post attachment image

i am going to create a slidershow by post attachment in single.php. i use this code but the result is null. <?php if ( have_posts() ) while ( have_posts() ): the_post(); ...
0
votes
1answer
48 views

View list of all attachments on site

I'm new to WordPress theme development and I'm trying to figure out if there is a way to display a list of public attachments similar to how you can view a list of posts with a specific tag or author. ...
0
votes
0answers
218 views

Make Add media button accessible to all in front end

I am trying to add an interface in which any user(including non logged in) can create a post from the front-end. I am able to bring the default wordpress editor to front-end using the wp_editor ...
0
votes
0answers
18 views

wp insert attachment from local drive [duplicate]

Is there some way to upload images from local drive to posts without using dashboard. Something like function wp_insert_attachment, bur for that function is a rule that files must be on server.
4
votes
4answers
3k views

Get first image in a post

I am using this code directly from the codex. function echo_first_image ($postID) { $args = array( 'numberposts' => 1, 'order'=> 'ASC', 'post_mime_type' ...
1
vote
1answer
110 views

Add attachment for all images in post

I want to move someone else's WordPress blog to a new server. I only have access to the exported XML file of the blog. When importing the XML with the Wordpress Importer plugin, everything went fine ...
0
votes
1answer
401 views

Get attachments by user

Is there a way to get attachments by user? I need a way to display all the images uploaded by a specific user. (I probably need the attachment IDs so that I can use wp_get_attachment_url to display ...
0
votes
3answers
3k views

Getting Different Size Of Attachment Images

I'm confused, because there are a lots of functions about attachments . I've tried a lots of functions. I'm setting a featured image for my every blog post. I have to get different sizes of this ...
0
votes
1answer
25 views

Theming media inserts

When I Insert media into my post or page it's rendered as a normal link. Would it be possible to somehow theme links that point to e.g. PDF or other file types?
1
vote
1answer
1k views

attachment.php code or tutorial

I am confused about the exact purpose attachment.php ( and image.php) . I notice many themes dont have them. If single.php displays the image the way I want then is it OK to leave it out. On the other ...
0
votes
1answer
943 views

How to force unlink on attached/inserted images?

When users insert an image into the content, WordPress automatically wraps the image in a hyperlink that, when clicked, creates an "attachment" page showing only the image inside the theme. Can I ...
0
votes
1answer
935 views

How to query details of images in gallery that is attached to a post

I have several images attached to each post. I need to generate a gallery, but because it's heavily customized I don't want to use a gallery plugin, nor the gallery short code. It's also situated in a ...
2
votes
4answers
4k views

using upload image with media_handle_upload .. but !

I'm tring to upload image in wordpress by using some function .. I found the way to upload images but there are one problem .. when the user upload his image , wordpress create more than one image ...
2
votes
3answers
681 views

How can you determine whether an image is merely attached or has actually been inserted into a post?

Bear with me. I promise there's a question when I'm done :) In WordPress, you can upload images while editing a post and have the option to insert them into the content (or not). Regardless, the ...
2
votes
1answer
693 views

Doubled titles when using All in One SEO with custom template

I created a separate template, attachment.php, for displaying image attachments. It's relatively simple; basically a stripped down version of single.php. Everything is working great except that when ...