-
Website
http://HuddledMasses.org/ -
Original page
http://HuddledMasses.org/textile-plugin-26-released/ -
Subscribe
All Comments -
Community
-
Top Commenters
-
Clint Ecker
1 comment · 5 points
-
avenzke
1 comment · 1 points
-
Euri
1 comment · 4 points
-
Stuart
1 comment · 1 points
-
Luciano Evaristo Guerche
1 comment · 1 points
-
-
Popular Threads
I installed your textile 2.6 plugin and like it so far. However, I've got a problem with inserting Amazon images. I've got a code snipet like this:
!1!:2
[1] http://images.amazon.com/images/P/B000AJJNFE.01...
[2] http://www.amazon.com/gp/redirect.html..blah..b...>
< < snip >>
The result is that the serial number in the first link gets screwed up by textile and turned into an < em > block, and nothing works after that.
In your Flickr example, I would expect the same behavior with the underscores becoming blocks. Got any idea what's going on?
The complicated answer is that you should go to http://textism.com/tools/textile/ and post a bug to Dean ;)
when i put star around chinese word(ex: *a?????* )
it has no effect
No This plugin produces invalid HTML when used with blockquote, as discussed inthis WordPress Support Forum thread:
http://wordpress.org/support/topic/19587
Basically, it should not wrap the blockquote tag inside p tags, since it ends up overlapping tags if there are multiple paragraphs inside the blockquote. You end up with: p-blockquote-/p!!! It would be great if this could be fixed, since some people on a group blog I manage depend on your plugin!
You *can* use xhtml while using textile, but you need to take into account that you *are* using textile. Which is to say: if you leave a blank line, textile is going to start a new paragraph for you, unless you're in a @notextile@ block -- which does weird things converting everything to code blocks-- so to accommodate the fact that your are using textile, you need to put a leading space on the line if you're starting a block-level xhtml tag after blank lines ... or use textile markup.
bq. For example, this blockquote was put in using the bq. textile markup.
It breaks on lines like a @pre@ section, but you can use XHTML inside it, or the usual textile markup.
Now, here's some normal text, and we'll break for a new paragraph.
Lastly, I've got a simple @blockquote@ tag with a space in front of it ...
So, I guess I'm not sure what else to say.
($f)
with
(?<!<!-)($f)
// -------------------------------------------------------------
function image($text)
{
return preg_replace_callback("/
\! # opening !
#REPLACE THIS
#(\)?
#WITH THIS:
($this->hlgn) # optional alignment atts
($this->c) # optional style,class atts
(?:\. )? # optional dot-space
([^\s(!]+) # presume this is the src
\s? # optional space
(?:\(([^\)]+)\))? # optional title
\! # closing
(?::(\S+))? # optional href
(?=\s|$) # lookahead: space or end of string
/Ux", array(&$this, "fImage"), $text);
}
// -------------------------------------------------------------
function fImage($m)
{
//$this->dump($m);
list(, $algn, $atts, $url) = $m;
$atts = $this->pba($atts);
/*
REPLACE THIS
$atts .= ($algn != '') ? ' align="' . $this->iAlign($algn) . '"' : '';
WITH THIS:
*/
$atts .= (isset($m[1])) ? ' align="' . $this->iAlign($m[1]) . '"' : 'ALIGNNOTFOUND-m0='.$m[1];
$atts .= (isset($m[4])) ? ' title="' . $m[4] . '"' : '';
$atts .= (isset($m[4])) ? ' alt="' . $m[4] . '"' : ' alt=""';
$size = @getimagesize($url);
if ($size) $atts .= " $size[3]";
$href = (isset($m[5])) ? $this->checkRefs($m[5]) : '';
$url = $this->checkRefs($url);
$out = array(
($href) ? '' : '',
'',
($href) ? '' : ''
);
return join('',$out);
}
// -------------------------------------------------------------
I hope this helps...
#REPLACE THIS
#(\)?
#WITH THIS:
and
/*
REPLACE THIS
==$atts .= ($algn != a??a??) ? a?? align=a??a?? . $this->iAlign($algn) . a??a??a?? : a??a??;==
WITH THIS:
*/
==$atts .= (isset($m[1])) ? ' align="' . $this->iAlign($m[1]) . '"' : '';==
I'm having trouble with WP2.0 putting double spaces between lines because I'm using the WP2.0 rich text editor. Is there something I should be doing to make it work with WP2.0?
I'm trying to push it a little further, to use it in titles and meta fields, and here's where I'm running into a problem:
Is there a way to keep Textile from adding p tags when the content is only one line long? Then I can hard-code a field to be a header, for example, without getting a nested p tag...
Any help you could offer would be appreciated.
Thanks!
-Jeremy
is there any chance to use the plugin without harming the function allowed_tags() (used in comments.php to show what html tags are allowed)? whenever i active the textile plugin, it strips away allowed_tags' output.
Arne: Look at the bottom of the file. Line 1008.
Arne: Contact form plugin? It must be (inappropriately) calling a filter for 'the_content', 'the_excerpt', or 'comment_text' ...
@contact form plugin: well, i dont know anything about wp's plugin structure, so i dont know in which way i could change the plugin. i only can see that you're right: it's calling a filter for "the_content".
thats the plugin: http://johannesries.de/webwork/contactform/
BTW I do have this installed on MY blog and I *LOVE* it thank you so much. Though I wish I could get mine to work with Geshi like you did, but no biggie I would so rather have Textile than Geshi. Beautiful plugin now if only my family would understand how nice it is :P
In your textile2b file it says this around line 812:
@/* when using a code beautifire, we don't want this between code tags - Joel
NOTICE: this will (still) break if you use both: */
$offtags = ('pre.*|kbd.*|notextile');@
and in the geshi file (geshi.php) around line 116:
@ var $header_type = GESHI_HEADER_PRE; // The type of header to use@
That variable needs to be set to GESHI_HEADER_DIV *knocks self on head*
I can't believe how long it was staring at me. Geshi was putting pre inside the within code so it was breaking it. So yeah this will fix the problem for those that wanna use Geshi ;)
(BTW you can delete my previous posts I won't be offended and this little aside too :* )
==
* "Some text":http://www.example.com
Text on a new line.
* "Some more text":http://www.foo.bar
More text on a new line
==
the list isn't closed (the last and are missing). It seems having text on a separate line (using double space after the link) breaks something. Is this something you can fix?
Thanks for a great plugin!
Paul: You *can* parse your feeds (I just don't think RSS should have HTML embedded in it). Just uncomment the next-to-last line in the plugin: @// add_filter('the_excerpt_rss', 'textile', 6);@ (that is, delete the slashes at the front so it just looks like: @add_filter('the_excerpt_rss', 'textile', 6);@).
"(ext)This link":http://thislink.com
Textile 2.6 seems to recognize classes on spans and block-level elements only. Is there any way I can get it to recognize classes on my links? Thanks for your help.
Submitting the original comment works fine, and they work fine in posts -- it's only when editing a comment that this seems to happen.
Can you advise us whether this is a bug in WP or in Textile 2.6 Beta?
sorty, meant to say Textile Rules!!!!!!!!
For those who aren't familiar with authoring WordPress plugins, you can easily alter the main textile() function [which WordPress calls for rendering text into textile output] so that it will not take action unless the post being displayed has a custom field value specifying to do so.
Simply replace the textile() function inside textileWrapperForWordPress.php with the following code block. Then, for the posts you want to be rendered with textile, you'll need a custom field named "mime_type" that has the value of "textile" and _viola_, you've got textile output for that post only and your other posts aren't affected.
function textile( $string='' ) {
global $post;
$mime = get_post_meta($post->ID, 'mime_type', true);
if (isset($mime) && $mime == 'textile') :
$textile = new Textile;
return $textile->TextileThis($string, false, false, false, false);
else :
return $string;
endif;
}