Lars M
Forum Replies Created
-
Forum: Themes and Templates
In reply to: Image thumbnailsSolved my problem, solution here: How to create a page that presents all post images?
Forum: Fixing WordPress
In reply to: How to create a page that presents all post images?Solved my problem:
<?php query_posts('post_type=page&post_parent='.$parent); ?> <?php /* WordPress Loop - Display only linked thumbnails ==================================================== */ if (have_posts()) : while (have_posts()) : the_post(); update_post_caches($posts); $images = get_children( array( 'post_parent' => $post->ID, 'numberposts' => -1, 'post_status' => 'inherit', 'post_type' => 'attachment', 'post_mime_type' => 'image', 'order' => 'ASC', 'orderby' => 'menu_order' ) ); if ( $images ) { foreach ( $images as $id => $image ) { $img = wp_get_attachment_thumb_url( $image->ID ); $link = get_permalink($page->ID); echo "\n\n" . '<a class="alignleft" href="' . $link . '"><img src="' . $img . '" alt="" /></a>'; } } endwhile; echo '<div class="clear"></div>'; else : echo '<div class="errorbox">' . __('Sorry, no posts matched your criteria.') . '</div>'; endif; ?>Forum: Fixing WordPress
In reply to: How to create a page that presents all post images?Do you know how I could make this work with the listing of pages instead of posts?
Forum: Themes and Templates
In reply to: Image thumbnailsI’m trying to make an Archives page which lists all the images attached to each page
(I’m not using posts) and I need each image to link to its respective page.Haven’t had any luck with the codes I found here on the forum or elsewhere.
Do anyone know how I would go about doing this?Forum: Plugins
In reply to: Jquery cycle images captionsActually I think I could fix this if I just knew how to get the alt tag for the images and put this in a different div. Could anyone please help me with this?
Forum: Plugins
In reply to: Jquery cycle images captionsI already tried taking both the_title(); and the_excerpt(); out.
Probably didn’t explain that right..
I want the cycle to display each image WITH the description or title,
but right now it cycles through the images and the title.Forum: Plugins
In reply to: How to use archives.php as an index?So in ‘Reading settings’
Front displays a static page:
Front page: a page that shows only one post
Posts page: a page that shows several posts, like index.php would normally doIs wordpress able to process both these requests or only one of them?
Forum: Themes and Templates
In reply to: Getting thumbnails of images attached to a post?These are two different things, Dunkkan;
– you are using this code on the index page to get the first post
– I’m using a code on the single page to get all the images from a post, without displaying the textForum: Fixing WordPress
In reply to: Separating images and text in a single postYes, I did.. the only problem I have is that the image column doesn’t link to the attachmentspage, unless I use `echo wp_get_attachment_link’ but then the thumbnails code stops working. I’ve sort of hacked it through css, but I’m still sure that there is an easier way to hack this (without using plugins).
Forum: Themes and Templates
In reply to: Getting thumbnails of images attached to a post?<?php $images =& get_children( 'post_type=attachment&post_mime_type=image&post_parent=' . $post->ID ); foreach( $images as $imageID => $imagePost ) echo wp_get_attachment_link($imageID, 'thumbnail', false); ?>This gets images and links to the image, but not the attachment page (unfortunately). Still asking how to do that.
Forum: Fixing WordPress
In reply to: Separating images and text in a single postThis code removes images from a post
http://chrisschuld.com/2008/08/removing-images-from-a-wordpress-post/but doesn’t link to the attachments page or show alt info, how do I include all that?
Forum: Themes and Templates
In reply to: Getting thumbnails of images attached to a post?What if you would like them to link to their attachment pages?
I tried doing this from the image-upload, but they are still just dead (no links)Forum: Fixing WordPress
In reply to: Separating images and text in a single postOK, so this gets only the images:
$images =& get_children( ‘post_type=attachment&post_mime… . $post->ID );
foreach( $images as $imageID => $imagePost )
echo wp_get_attachment_image($imageID… ‘thumbnail’, false);
How do I get the rest of the content into the other div, with images being the only exception?Forum: Fixing WordPress
In reply to: Separating images and text in a single postThanks, but I don’t really like NextGen — and I’m trying to avoid using any plugins for this. It should be really simple, but obviously I don’t know enough PHP to get the get_content to display images in one div and text in another. I hope someone will be able to help out?