Please see attached image. I'm creating a chinese jokes website and have the content (the joke) converted to image so that people without proper chinese encoding are still able to see it. However there's a
tag everytime the line breaks in the html... anyway to remove it?

Thanks!

CommentFileSizeAuthor
#6 line.jpg54.81 KBakberhussain
br tags.jpg45.41 KBiori57

Comments

danielb’s picture

Mate I really don't know off hand. Does this happen when you use textimage the normal way (without autoinsert)?

iori57’s picture

Heh first of all great module by the way, without it I don't even know how to use textimage =.=

What's the proper way to generate image from contents? I manually added the < p > tag into your module (because the content are all inside < p > tag as seen from the source page), however I can't get rid of the < br > tag..

I just want the contents to become image, is there an easy way to do it?

Thanks a lot for the great module! ^^

iori57’s picture

Sorry for the gibberish of the previous post before, didn't notice that the < p > tag actually break off my sentence..

I'm still figuring this same issue at the moment...

danielb could you tell me which variable is the final text (string) variable before it was converted to image? I could use str_replace() php function to replace "< br >" tag with empty string! ^^ I'm confused which variable to use as there are so many $text variables inside textimage module and your module..

Thanks again!

danielb’s picture

Project: Textimage autoinsert (abandoned) » Textimage
Version: 6.x-2.0 » 6.x-2.x-dev

I am convinced the problems you are having are because textimage cannot support HTML in the supplied text. You have to remove the html. I'm sure there are functions for doing that either in php or drupal, but I can't think off the top of my head what they are.
Moving this to the textimage queue.

deciphered’s picture

Status: Active » Closed (fixed)

Just moved a dupe into Textimage Autoinsert, didn't see this version that originated in Textimage Autoinsert.

As far as I'm concerned Textimage doesn't need to interpret HTML, it is doing exactly what it needs to do, render text as a textimage. If you don't want HTML tags in your textimage, don't send them to textimage, process your text before rendering it.

Sorry for the late and blunt response. The other issue I moved had a response that looked like it would solve your issue so please refer to that.

Cheers,
Deciphered.

akberhussain’s picture

StatusFileSize
new54.81 KB

. How to remove br tag in drupal
Ans: Go to Home » Administer » Site configuration » Input formats Click On configuration Full HTML and uncheck Line break converter Converts line breaks into HTML (i.e.
and

tags).

Check this picture