[wp-hackers] shortcode for images?
scribu
scribu at gmail.com
Fri Jan 30 12:05:25 GMT 2009
>
> When you upload an image through the default media upload and you enter a
> caption for the image then insert into post what is inserted is something
> like:
>
> [caption id="attachment_2817" align="aligncenter" width="212"
> caption="Corporate America More GLBT-Friendly Than Ever."]<a href="
> http://www.hrc.org"><img src="
> http://blogstaging.hrcsupport.org/wp-content/uploads/2009/01/side.jpg"
> alt="Corporate America More GLBT-Friendly Than Ever." title="side"
> width="212" height="90" class="size-full wp-image-2817" /></a>[/caption]
>
> When you view this in the WYSIWYG you will see the image and the caption
> text below it. Simple enough.
>
I think shortcode for captions is justified because there isn't a HTML
equivalent for them, which is not the case for images.
Adding a performance hit of this magnitude just to make a single
> event easier to handle is a poor solution. I also think that it's
> barking up the wrong tree.
>
I agree. Speaking of migrations, what would happen if you would want to
switch to something other than WP? You would have to use another script to
parse the shortcodes, which can lead to other problems.
--
http://scribu.net
More information about the wp-hackers
mailing list