[wp-testers] the_excerpt tag

Aaron aaron at paintbox.org
Wed Mar 26 17:57:45 GMT 2008


I wouldn't expect to have the gallery removed from a short post.  I  
have set up several installs that make heavy use of photos, and many  
times there is only an image in the post, and I can see sometimes  
having only a gallery as a post.  I usually do this in conjunction  
with Kaf's post_image plugin to display the thumbnail, and the  
excerpt tag to keep it only the thumbnail, as soon as I remove the  
excerpt tag it displays the thumbnail and the full image.

I am sure that if I need to I can go through and do some re-write in  
my themes and possibly the plugins I am using but I would rather not.

Aaron C


On Mar 26, 2008, at 10:30 AM, Aaron Harun wrote:

> The strip_tags() in wp_trim_excerpt() strips only the tags and not the
> contents of script and style elements. We either need to strip all of
> script and style tags [1] before strip_tags is called or not strip
> galleries.
>
> The question is, would a user expect to have the gallery removed in a
> short post?
>
> Aaron Harun.
>
> [1] With Regex like: <script[^>]*?>.*?</script> and <style[^>]*?>.*? 
> </style>
>
> On Wed, Mar 26, 2008 at 12:59 PM, Aaron <aaron at paintbox.org> wrote:
>> I am testing 2.5RC2
>> When using the gallery function in the image upload I am having some
>> problems with one of my themes that uses the excerpt tag.
>> When there is a gallery added to a post and the use of the_excerpt()
>> the following is displayed
>> "
>> gallery {
>> margin: auto;
>> }
>> .gallery div {
>> float: left;
>> margin-top: 10px;
>> text-align: center;
>> width: 33%; }
>> .gallery img {
>> border: 2px solid #cfcfcf;
>> }
>> "
>> I have also tried using the_excerpt_reloaded plugin, and I get the
>> following displayed
>> "
>> [gallery]
>> "
>>
>> css not displayed but still in error.
>>
>> Anythoughts?
>>
>>
>> _______________________________________________
>> wp-testers mailing list
>> wp-testers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-testers
>>
> _______________________________________________
> wp-testers mailing list
> wp-testers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-testers



More information about the wp-testers mailing list