Closed (fixed)
Project:
Advertisement
Version:
5.x-1.1-rc2
Component:
ad.module
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
29 May 2007 at 21:24 UTC
Updated:
12 Nov 2007 at 22:41 UTC
Is it possible to create an ad with BOTH text and image?
Creating a TEXT type ad I can insert an image along with text, but the ad just displays it all as HTML.
Creating an IMAGE type ad there is nowhere to add any text.
Am I missing something or is there a setting or patch I can apply to make TEXT type ads render the HTML?
Thank you!!
Comments
Comment #1
jeremy commentedThis is not currently possible. The goal with the ad_text module was to make it _very_ simple, and this is what I have done. In order to minimize display bugs, I convert everything entered into the text block to be properly displayed by javascript, unfortunately for you this also means that html tags are converted.
Patches so that html can be included in text ads would be reviewed and likely merged. I don't need (or even want) this functionality personally, but if done correctly and cleanly it would go in.
Comment #2
colorado commentedThanks Jeremy,
I've got text_ad displaying the HTML in the node by removing the function ad_text_display_prepare from the adbody in ad_text_display_ad.
But, for some reason ads are not displaying in the blocks. Any ideas why this would be?
Comment #3
jeremy commentedThe whole purpose of ad_text_display_prepare() is to sanitize the text so it can be displayed with javascript. When you remove the calls to that function, you are skipping this sanitization step, and thus your javascript ends up with invalid characters and the ad is not displayed. If you enable something like FireFox's FireBug extension you will see the javascript error. Instead, to get what you want you need to enhance the ad_text_display_prepare() function, not remove it.
Comment #4
stinky commentedHey colorado,
Did you ever figure out how to include html in your text ads?
Comment #5
colorado commentedNo stinky, but I haven't spent anymore time on it either.
Comment #6
jeremy commentedThere is now an ad_html module included in the development version of the module. It should provide what you're looking for.
Comment #7
colorado commentedWhoah great - thanks Jeremy!!
Comment #8
(not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.