Custom Filter is not applied until the node is edited

sjtout - August 25, 2009 - 00:14
Project:Custom filter
Version:6.x-2.0-beta5
Component:Code
Category:support request
Priority:normal
Assigned:Unassigned
Status:closed
Description

I have email from a mailing list auto-populating a forum. When email comes in, I place an '...eom...' marker at the very end of every email. I've created a custom filter to filter out content from the end of the first reply in an email to the '...eom...' marker -- removing all the content of previous emails from the reply.

When I first view an item in a forum, the custom filter isn't applied -- all of the content from the whole email conversation is visible on each email that is part of the forum thread. However, if I click the edit tab and then save a comment or node, the custom filter gets applied to that comment or node; it filters out all of the conversation from previous emails, as expected; and the result is what I want.

Any idea why this might be happening? Anything I can do to provide additional useful information? Any thoughts for ways I might address the issue?

Thanks

#1

kiamlaluno - August 25, 2009 - 02:50
Title:Custom Filter not applied until I edit the node» Custom Filter is not applied until the node is edited
Status:active» postponed (maintainer needs more info)

From the description given, I would think that the custom filter is set to cache the result; that would explain why saving the content actually applies the filter.

I would need more information, to be able to tell you what is the exact cause, but I think that is the more plausible cause.

#2

sjtout - August 25, 2009 - 15:34

Based on your post, I've turned off all caching available on the 'Performance' page, and am seeing the same result.

I'm using Drupal 6.11 with:

Apache 2.2.11
PHP: 5.2.9-2
MySQL: 5.1.33
(WampServer 2.0)

The process I'm using for creating nodes and comments is not standard -- since they're coming in via email. Any Custom Filter dependency there that might be involved?

Also, I have found that this PHP version is a little stricter about some things (not sure exactly what, but, for example, it in other situations, it threw this error:

Cannot use object of type stdClass as array

When other people weren't seeing it. (That's in this unrelated issue: http://drupal.org/node/531690.)

Is there anything I can do to provide you with more information, or anything I can do to assist in troubleshooting?

Thanks

#3

sjtout - August 25, 2009 - 16:13

Well, I'm not sure what's going on -- but right now, things seem to be working as expected (just started to about 15 mins ago). Maybe it was a caching issue. I'll monitor for the next couple of days and let you know if things stay good or backslide. Thank you for the prompt response.

#5

kiamlaluno - August 25, 2009 - 17:33

Bear in mind that also Custom filter has an option for the cache that you find in the filter edit page (see the attachment).

#6

kiamlaluno - August 25, 2009 - 17:36

I had problems in attaching the screenshot. Let us see if it works now.

AttachmentSize
Voila_Capture_32.png 26.46 KB

#7

sjtout - August 28, 2009 - 16:42

Thank you. I'm still getting strange results from this workflow, but am not sure which module/code is causing the problems. Right now, what's happening is that even though my default module is set to 'Filtered HTML' (to which I've added some custom filters); the system seems to be applying a default of either 'no filter' (is that even possible), or a filter that I've deleted--I'm not sure which... still looking into it.

#8

sjtout - August 28, 2009 - 16:44

Actually -- may I ask, do you know which table in the database associates a node with a specific filter? Knowing that would help troubleshoot this issue I think, and I haven't been able to find the answer...

#9

kiamlaluno - August 28, 2009 - 17:04

It should be the table node_revisions, which save it in the field format.

#10

kiamlaluno - August 30, 2009 - 12:48
Status:postponed (maintainer needs more info)» active

#11

kiamlaluno - September 11, 2009 - 08:32
Status:active» fixed

As I have not gotten any feedback, I am marking this report as fixed because it already had an answer.

#12

sjtout - September 11, 2009 - 15:02

For the most part, I'm not seeing the behavior anymore, though I'm not sure what the critical change was. I say 'for the most part' because very occasionally it does seem to happen, or regex expressions I test in one environment (e.g., Regex Coach), don't produce the same results when they're built into filters. This makes me unsure of whether the filter isn't being applied, or I'm not defining it well. It does seem as though dead simple filters sometimes do not get applied. Anyway, if I find anything else useful, I'll add it to this thread, but until then, I think it's reasonable to close the issue. Thank you.

#13

kiamlaluno - September 11, 2009 - 15:06

As Regex Coach is thought for Perl regular expressions, I would expect a different result, in some cases.
I reported in the project page a link for the differences between the regular expressions used in PHP, and Perl.

#14

sjtout - September 12, 2009 - 00:40

I'll check it, thank you!

#15

System Message - September 26, 2009 - 00:40
Status:fixed» closed

Automatically closed -- issue fixed for 2 weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.