natbaker
Member
Posted 1 year ago #
When I use the {democracy:id} tag in the post it automatically inserts a lower case "n" in the published post right before the poll. Very annoying and i can't figure out how to get rid of it. What's worse is each time you go in to edit the post it adds another "n"!
jtfisher
Member
Posted 1 year ago #
I'm getting this too. Any responses?
LydiaLeibs
Member
Posted 11 months ago #
i'm also getting this. arghh!!! i suspect it may be fixed in the latest version, but it requires upgrading to wordpress 2.7, and i'm not ready to do that yet. any other ideas?
summerhogan
Member
Posted 9 months ago #
I'm using WP 2.7 and I'm getting the "n" too. I'm using Democracy in WP 2.3.2 and there are no problems, so it must be something non-compatible with newer versions of WP.
To remove the stray 'n' I've found that line 331 of democracy.php needs altering from
return preg_replace('/{democracy[\w\W\s^}]*?}/', '\n<div>\</div>', $content);
to
return preg_replace('/{democracy[\w\W\s^}]*?}/', '<div>\</div>', $content);
drekyn
Member
Posted 7 months ago #
on line 331 you have to replace the ' with the 2 this way:
return preg_replace('/{democracy[\w\W\s^}]*?}/', '\n<div>\</div>', $content);
to
return preg_replace('/{democracy[\w\W\s^}]*?}/', "\n<div>\</div>", $content);
this fix worked for me
Mariokluser
Member
Posted 5 months ago #
blogwriter
Member
Posted 3 months ago #
RE: Democracy Poll 2.0.1
removing 'n on line 331 doesn't work for WordPress v. 2.8.1 (n still shows up)
and replacing '\n with "\n doesn't work for WP v. 2.8.1 (gives fatal error)
the democracy *widget* works fine on WP v. 2.8.1
Has anyone come up with a workaround for removing the n in democracy poll 2.0.1 when using WP v. 2.8.1?
Thank you!