kasperbs
Forum Replies Created
-
Forum: Plugins
In reply to: Let Editors &Authors create WP Photo AlbumsI just updated the plugin, but it seems like you still can’t control the privileges.
Forum: Plugins
In reply to: Let Editors &Authors create WP Photo AlbumsStill no solution to this unfortunately. Hopefully someone knows something about this issue.
Forum: Plugins
In reply to: Let Editors &Authors create WP Photo AlbumsI have spoken to few other people about his issue, and they have agreed that it would indeed be a great feature to have. But none of us are great PHP coders so we would really appreciate any advice we can get.
Forum: Plugins
In reply to: Let Editors &Authors create WP Photo AlbumsWell being kind of a PHP beginner student I haven’t been able to make much happen with this. So I guess this post is just shameful *BUMB*
Forum: Plugins
In reply to: Let Editors &Authors create WP Photo AlbumsUnfortunately I’m still in search for a solution to this problem. it would really extend the possibilities for this plugin if editors and authors could post photo albums a well.
Thank in advance for any help.
Forum: Plugins
In reply to: Let Editors &Authors create WP Photo AlbumsI think this plugin works great, and it is just what I’m looking for, but I need a way to let authors and editors upload photos and create albums. If anyone could either help me with a solution or maybe suggest another plugin that is similar but let’s other than the administrator upload photos, I would be glad.
Forum: Plugins
In reply to: Let Editors &Authors create WP Photo AlbumsSorry for writing again, but I am desperately in need for a solution to this problem. Any help that can point me in the right direction will be appreciated.
Forum: Plugins
In reply to: WordPress Photo Album (WPPA) Modification RequestOK I found out how to do this. I find it strange that no one has taken the time to post this solution somewhere as it was extremely easy to do, even for non PHP coder as me.
OK first find the line in wppa.php that says
$url = get_permalink() . wppa_sep() . 'album=' . $_GET['album'] . '&photo=' . $thumb['id'];
Its about line no.: 990change that to:
$url = get_bloginfo('wpurl') . '/wp-content/uploads/wppa/' . $thumb['id'] . '.' . $thumb['ext'];
Then open wppa_theme.php and change this line:
<a href="<?php wppa_photo_page_url(); ?>" class="img"><img src="<?php wppa_thumb_url(); ?>" alt="*" /></a>
To:
<a href="<?php wppa_photo_page_url(); ?>" rel="lightbox[<?php wppa_album_name(); ?>]" class="img"><img src="<?php wppa_thumb_url(); ?>" alt="*" /></a>
That’s all you have to do and every thumbnail will open with lightbox. If you got that installed of course.
Forum: Plugins
In reply to: WordPress Photo Album (WPPA) Modification RequestThis is a great plugin, but would be even better if you could integrate lightbox. I would be happy for any help with this as well. After having searched the web, it seems like it’s a problem quite a few people are struggling with.
Forum: Plugins
In reply to: Show related posts with excerpt and key/valueThanks, by placing this just before the comment template, it seems to work perfectly. Thanks again for you fast and accurate support.
Forum: Plugins
In reply to: Show related posts with excerpt and key/valueNo, the comment still show up on some other post. What happens is, as soon as a press submit comment, I’m taken to another post where my comment shows up.
EDIT:
It seems that the problem only exists on certain posts. I’m not sure what it is but on some posts there is no problem. I will keep trying to figure out if there is some kind of pattern.UPDATE:
OK I have now made a few dozens of comments, and the problem is on every post where there are related posts, whether or not the rewind_post() is shown or commented out.Forum: Plugins
In reply to: Show related posts with excerpt and key/valueOk I might have been too fast here. There seems to be problem with the commenting after I have implemented this. When I make a comment it appears on a completely different post. The code below is my template. (it works if I take out the code inside the related_items div:
<?php the_content() ?> <div class="related_items"> <?php $limit = 3; // # of posts to display $art_img_teaser = 'art_img_teaser'; // custom field key for image url $posttags = get_the_tags(); if ($posttags) { foreach($posttags as $tag) { $sep = ( $tags ) ? ',' : ''; $tags .= $sep . '\'' . $tag->name . '\''; } } $rand_tag_posts = $wpdb->get_results("SELECT $wpdb->posts.* FROM $wpdb->posts INNER JOIN $wpdb->postmeta ON ($wpdb->posts.ID = $wpdb->postmeta.post_id) INNER JOIN $wpdb->term_relationships ON ($wpdb->posts.ID = $wpdb->term_relationships.object_id) INNER JOIN $wpdb->term_taxonomy ON ($wpdb->term_relationships.term_taxonomy_id = $wpdb->term_taxonomy.term_taxonomy_id) INNER JOIN $wpdb->terms ON ($wpdb->term_taxonomy.term_id = $wpdb->terms.term_id) WHERE $wpdb->term_taxonomy.taxonomy = 'post_tag' AND $wpdb->terms.name IN ($tags) AND $wpdb->postmeta.meta_key = '$art_img_teaser' AND post_type = 'post' AND (post_status = 'publish') AND $wpdb->posts.ID <> $post->ID GROUP BY $wpdb->posts.ID ORDER BY RAND() LIMIT $limit"); if( $rand_tag_posts ) : foreach( $rand_tag_posts as $post ) : setup_postdata($post); // Variables to collect from the retrieved posts $art_img_teaser_url = get_post_meta($post->ID, $art_img_teaser, true); $rel_excerpt = $post->post_excerpt; // collect the $art_img_teaser value ?> <div class="related_post"> <a href="<?php the_permalink(); ?>"><img src="<?php bloginfo(url); echo $kasper_image_path .'teasers/thumb_'; ?><?php echo $art_img_teaser_url; ?>" alt="<?php the_title_attribute(); ?>" title="<?php the_title_attribute(); ?>" /></a> <a href="<?php the_permalink(); ?>"> <h3> <?php the_title(); ?> </h3> <?php if ( $post->post_excerpt ) : // If there is an explicitly defined excerpt ?> <?php $sentences = preg_split('/\./', $rel_excerpt, -1 , PREG_SPLIT_NO_EMPTY); echo '<p>' . $sentences[0] . '</p>'; ?> <?php else : ?> <?php wswwpx_content_extract ($more_link_text = 'More', $test_len=85, $cut_len='1:s', $addtodb=false, $beforehtml='<p>', $afterhtml='</p>', $strip_tags=true, $with_more_link=false); ?> <?php endif; ?> </a> </div> <?php endforeach; endif; //rewind_posts(); ?> </div> </div> <div class="post_meta2"> </div> <?php endwhile; ?> <?php else : ?> <p>Sorry, but you are looking for something that isn't here, try searching for it.</p> <?php include (TEMPLATEPATH . "/searchform.php"); ?> <?php endif; ?> </div> </div> </div> </div> <div id="sub_wrapper"> <?php comments_template(); ?> <div class="clear"></div> </div> <?php get_footer(); ?>
Forum: Fixing WordPress
In reply to: Set a Varible to use on all template filesThanks Otto42, that works. Thanks for the explanation as well. it’s always nice to know what you are doing.
Forum: Fixing WordPress
In reply to: Set a Varible to use on all template filesThanks but it doesn’t work. I put this in the header:
<?php $image_path = '/wp-content/uploads/images/reviews/'; ?>
Then echo $image_path in home.php but it didn’t work. It only worked if I put that variable in the home.php file
Forum: Fixing WordPress
In reply to: PHP Question: How to echo an ArrayEDIT:
Thanks that worked perfectly.