Subsections


4.14 User-submitted Advertisements

Since reading interesting text and clicking links are what visitors to a Scoop site are generally there for, unobtrusive text ads generally have a much higher click-through rate than flashy graphical banner ads. Scoop's built-in ad server can handle both text, graphical, and mixed text and graphical ads.

The ad system is turned on using the variable use_ads. Whether you are using free ads or paid ads, the line

use Scoop::Billing;
must be uncommented in etc/startup.pl. If you want paid ads, see section 4.19 for details on setting up payment processing.

All advertisement configuration and approval is handled through the Advertising Admin Tool (A.15).

4.14.1 Creating Ad Templates

Ad template creation is a five-step process.

Using the Blocks Admin Tool, create a little self-contained block of HTML that could be inserted anywhere. Usually this is a little table, but if you're going CSS it could just as easily be a DIV. This block can contain any of the special keys TITLE, TEXT1, TEXT2, LINK_URL, or FILE_PATH. No special processing is done on any of these keys apart from sanitizing them; they are replaced with whatever the advertiser enters. Leaving a special key out means that the advertiser isn't given a text box for that field.

Using the Advertising Admin Tool, go to Edit Ad Properties and fill in the properties for your new template to whatever is appropriate for this particular ad. You will not be able to activate it yet.

Still in the Advertising Admin Tool, go to Edit Example Ad and create an example ad for your new template. Show off its layout.

Back in the Blocks Admin Tool, pick the appropriate page template and put the box ad_box where the ad should display, specifying the ad's position number (see below for some tips on the ad position) if it's other than 1.

In the Advertising Admin Tool again, go to Edit Ad Properties and activate the ad.

The different types of ads and the different page locations can draw from the same or different pools of ads, using the ``Ad Position'' property. Each Ad Position number represents a distinct pool of ads, which can be filled from several different ad templates and poured into several different locations on a page.

One type of ad can only have one ``Ad Position'' number, but several types of ads can share a position number and hence be mixed into the same pool. Similarly, a given ad box placed on a page can have only one position number and draw only from that pool, but several ad boxes in different locations on the page can share a position number and hence draw from the same pool of ads.

4.14.2 Graphical Ads

If you want to use graphical ads or ads with a mixture of text and graphics, there are only a few extra things to watch while following the instructions above. Before you start working with graphical ads at all, the variables ad_files_base and ad_server_url and that directory's permissions must be correctly set so Scoop can successfully save and retrieve image files.

The ad template that you create in the first step above must use as its image source ``|ad_server_url||FILE_PATH|'' so the link to the ad image works properly. You may also want to specify the width and height of the ad image so the page layout doesn't get altered by a user submitting an image that is entirely the wrong size.

When setting the ads properties in the second step above, you should put a reasonable file size limit on the files that can be uploaded.

The above information can actually apply to any ads that require a separate file, such as embedded java or flash; you will then simply use the appropriate HTML tag instead of the IMG tag. Scoop does not actually check what type of file is being uploaded.

4.14.3 Approving and Managing Ads

When an advertiser buys an ad, it must be approved before it enters the ad pool for display. Ads waiting to be approved are listed in the Advertising Admin Tool, under Judge Submissions (also the first page to appear when you enter the Advertising Admin Tool).

If you have the variable ads_judge_unpaid turned on, you will see both paid and unpaid ads on the judging page; if off, only paid ads will be shown.

Ads must be both approved and activated before they start appearing in the normal ad rotation. If you aren't getting payments for the ads via paypal or credit card, you may want to turn the variable activate_upon_approve on so the ads are activated as soon as you approve them. If you are getting payment through Paypal or credit card, Scoop will activate approved and paid ads from the cc_bill_orders and paypal_bill_orders crons (A.14), depending on payment method.

4.14.4 Ad Comments

Ads in Scoop are each filed into a story, with all the features that implies--including comments.

For each type of ad, the admin can turn ad comments on or off on the Edit Ad Properties page, then when an advertiser buys an ad (if the ad type has comments available) the advertiser can leave comments on or turn them off for that one ad.

A smart advertiser will leave comments on, because not only do ad impressions on the story and comment view for the ad not count towards what he's paying for, he also has the reader's full attention directed to his ad, and can explain, clarify, and expand on what the ad or the advertised product is all about.

The ads available for commenting are filed in the section named in the variable ad_story_section. You will have to create this section in the Sections Admin Tool before it will list the ad stories, and set its Post Story section permissions to ``Hide'' for all groups except Superuser to prevent people from posting regular stories to that section. Both Read permissions and the Post Comment permission should all still be ``Allow''. Ads will not show up on the ``Everything'' section page unless you remove the ad section from the variable sections_excluded_from_all.


janra
2004-03-26