Why is the quote text obscured by the advertisement?

  • Bug
  • Thread starter sylas
  • Start date
In summary, The conversation discusses a problem with advertisements obscuring text in quoted sections of posts on a forum. The proposed solution is to simplify the code by removing a table and combining two divs, which will allow for better wrapping of text around ads. This fix will also allow for ads to be placed in every post, increasing revenue for the forum.
  • #1
sylas
Science Advisor
1,647
9
I have been looking at PF without being actually logged on, and so all the advertisements were in place. And I noticed a problem. I looked through a couple of threads, and it is a consistent problem. Consider this screen shot.
ad.JPG


There is a google advertisement, placed inside the first post of the page. The text in post is wrapped appropriately so that it is not obscured by the advertisement. However, the text inside the quote box is not wrapped, so gets partially obscured by the advertisement. Having a border around an advertisement in this position would also be an improvement.

Cheers -- sylas
 
Physics news on Phys.org
  • #2
You call it a bug? Greg calls it a feature - this way more people want to pay for using forums.
 
  • #3
It's a bug I've known about for awhile. Not quite sure how to fix it. Only happens when a quote is high enough in a first post. Not too common. thanks!
 
  • #4
Borek said:
You call it a bug? Greg calls it a feature - this way more people want to pay for using forums.

:smile: The truth is finally out. :biggrin:
 
  • #5
A quick and dirty fix is to put a table in:

so:
Code:
...
<td class="alt1" id="td_post_XXXXX" style="border-right: 1px solid #E3E3E3">
   <table>
      <tr>
         <td>
            <div id="message">
               ...
            </div>
         </td>
         <td>
            <span id="googlead">
               ...
            </span>
         </td>
      </tr>
   </table>
</td>
...
 
  • #6
It's unlikely to happen in a first post, since the first post usually has nothing to quote.

It can of course happen in the 17th, 33rd, etc post … but the reader can always click the little arrow to see the original. :wink:
 
  • #7
DavidSnider said:
A quick and dirty fix is to put a table in:

I've had a look at the code. The solution is to take a table out! Furthermore, if this is fixed, you will once more be able to place an advertisement inside every post, which I believe was the case previously. So you even get the advantage of more ads to the hoi polloi. (Any hoi polloi reading this: subscribe! You know you want to.)

Quoted text currently uses html where a quote appears inside a div, which is inside a table with a single cell, which is inside a div.

Inside that, you then have another div for the header indicating who is being quoted, and then a blockquote for the quoted text.

The problem is that the table has width 100%, and this is what prevents the stuff inside from properly wrapping around the ad.

There's probably some history of development here, but the fix is to simplify. Get rid of the table, and combine the two outer divs. The table here does nothing useful and only causes the bug.

Here I give a complete example in html, with the original and the revised methods, but all the other guff for the page stripped out. This contains what is effectively a post with two quoted sections, and a floating ad. I put the current method first, and the proposed version after, with headings to say which is which. You can see that the quotes have one div replacing what was two divs and a table, all nested. Observe the difference in the attached screen shot. Margin widths still give the same spacings as at present.
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<style type="text/css">
.quote {
    margin:15px 10px;
    background: url([PLAIN]https://www.physicsforums.com/images/misc/q.gif)[/PLAIN]  0 0 no-repeat;
    padding-left:25px}
.smallfont
{
    color: #26353F;
    font: 10px verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif;
}
blockquote.bq {
    font: italic 10pt verdana, geneva, lucida;
    background: #dbdada;
    border-left:2px solid #cacaca;
    border-right:0px solid #81ba3c;
    border-top:0px solid #81ba3c;
    border-bottom:3px solid #cacaca;
    margin:0px;
    padding:5px}
</style>
<body>

<h3>Original version</h3>

<!-- Here is the advertisement -->

<span style="margin: 2px; float: right; width: 301px; height: 251px;">
<!-- =================== CODE FOR RECTANGLE  300x250 ============== -->
<!-- sylas commented out the script: <script  src="http://tag.contextweb.com/TagPublish/getjs.aspx?action=VIEWAD&cwrun=200&cwadformat=300X250&cwpid=####&cwwidth=300&cwheight=250&cwpnet=1&cwtagid=####"></script>--><div style="border: 1px black solid; width:300px; height: 251px;">This is text to use in place of the script that calls up something to get hold of an advertisement. The actual add comes with a background color, I think, which obscures the text underneath. I've added a border.</div></span>

<!-- Here is the post -->

<div id="post_message_6666">Prefix<br />
  <div style="margin:3px; margin-top:5px; ">
    <table cellpadding="6" cellspacing="0" border="0" width="100%">
    <tr>
        <td><div class="quote" style="margin-bottom:2px">
            <div class="smallfont" style="margin-bottom:2px">
                Originally Posted by <strong>PosterName</strong>
                <a href="showthread.php?p=6666#post6666" rel="nofollow"><img class="inlineimg" src="[PLAIN][PLAIN][PLAIN]https://www.physicsforums.com/Prime/buttons/viewpost.gif"[/PLAIN]   [/URL] border="0" alt="View Post" /></a>
            </div>
            <blockquote class="bq" style="font-style:italic">This is a bit of quoted text from the post linked just above, with the author indicated just above as well.</blockquote>
        </div></td>
    </tr>
    </table>
</div>This is a response to the first quoted portion, which sets the stage for the next bit.<br />

<div style="margin:3px; margin-top:5px; ">
    <table cellpadding="6" cellspacing="0" border="0" width="100%">
    <tr>
        <td><div class="quote" style="margin-bottom:2px">
            <div class="smallfont" style="margin-bottom:2px">
                Originally Posted by <strong>PosterName</strong>
                <a href="showthread.php?p=6666#post6666" rel="nofollow"><img class="inlineimg" src="[PLAIN][PLAIN][PLAIN]https://www.physicsforums.com/Prime/buttons/viewpost.gif"[/PLAIN]   [/URL] border="0" alt="View Post" /></a>
            </div>
            <blockquote class="bq" style="font-style:italic">This is another bit of quoted text, but this time it is a bit longer so that it spills over two lines at least.</blockquote>
        </div></td>
    </tr>
    </table>
</div>This is more response from the post, to finish up with an incisive contribution to the discussion that puts the two quoted extracts into context where they are immediately understood by everyone reading.</div>

<h3>Corrected version</h3>

<!-- Here is the advertisement -->

<span style="margin: 2px; float: right; width: 301px; height: 251px;">
<!-- =================== CODE FOR RECTANGLE  300x250 ============== -->
<!-- sylas commented out the script: <script  src="http://tag.contextweb.com/TagPublish/getjs.aspx?action=VIEWAD&cwrun=200&cwadformat=300X250&cwpid=####&cwwidth=300&cwheight=250&cwpnet=1&cwtagid=####"></script>--><div style="border: 1px black solid; width:300px; height: 251px;">This is text to use in place of the script that calls up something to get hold of an advertisement. The actual add comes with a background color, I think, which obscures the text underneath. I've added a border.</div></span>

<!-- Here is the post -->

<div id="post_message_6666">Prefix<br />
    <div class="quote" style="margin: 19px; margin-top: 25px; margin-bottom:12px">
            <div class="smallfont" style="margin-bottom:2px">
                Originally Posted by <strong>PosterName</strong>
                <a href="showthread.php?p=6666#post6666" rel="nofollow"><img class="inlineimg" src="[PLAIN][PLAIN][PLAIN]https://www.physicsforums.com/Prime/buttons/viewpost.gif"[/PLAIN]   [/URL] border="0" alt="View Post" /></a>
            </div>
            <blockquote class="bq" style="font-style:italic">This is a bit of quoted text from the post linked just above, with the author indicated just above as well.</blockquote>
</div>This is a response to the first quoted portion, which sets the stage for the next bit.<br />

<div class="quote" style="margin: 19px; margin-top: 25px; margin-bottom:12px">
            <div class="smallfont" style="margin-bottom:2px">
                Originally Posted by <strong>PosterName</strong>
                <a href="showthread.php?p=6666#post6666" rel="nofollow"><img class="inlineimg" src="[PLAIN][PLAIN][PLAIN]https://www.physicsforums.com/Prime/buttons/viewpost.gif"[/PLAIN]   [/URL] border="0" alt="View Post" /></a>
            </div>
            <blockquote class="bq" style="font-style:italic">This is another bit of quoted text, but this time it is a bit longer so that it spills over two lines at least.</blockquote>
</div>This is more response from the post, to finish up with an incisive contribution to the discussion that puts the two quoted extracts into context where they are immediately understood by everyone reading.</div>

</body></html>

The essential replacement is this only. Replace:
Code:
<div style="margin:3px; margin-top:5px; ">
    <table cellpadding="6" cellspacing="0" border="0" width="100%">
    <tr>
        <td><div class="quote" style="margin-bottom:2px">
            <div class="smallfont" style="margin-bottom:2px">
                Originally Posted by <strong>PosterName</strong>
with
Code:
<div class="quote" style="margin: 19px; margin-top: 25px; margin-bottom:12px">
            <div class="smallfont" style="margin-bottom:2px">
                Originally Posted by <strong>PosterName</strong>

The last two lines in the above extracts are identical, just given for context. The difference looks like this:
FixQuotes.JPG


The fix requirements for existing code should be very easy, I think, and it will let you put in more advertisements.

Cheers -- sylas
 
Last edited by a moderator:
  • #8
tiny-tim said:
It's unlikely to happen in a first post, since the first post usually has nothing to quote.

It can of course happen in the 17th, 33rd, etc post … but the reader can always click the little arrow to see the original. :wink:

It happens only in the first post in the thread or top of the subsequent pages. Those are the only posts that have adverts in the right-hand corners. That's one reason why I log in every time I wander over here, so I can read the entirety of the top post. But then I miss out on the Physorg links, which I actually liked and didn't mind at all in the second post spot.

But, yeah. No, the adverts messing with the first post when you're not logged in and/or don't have a subscription isn't new.
 
  • #9
sylas said:
you will once more be able to place an advertisement inside every post, which I believe was the case previously

Can't be, no more than 3 AdSense frames per page allowed by Google contract.
 
  • #10
Borek said:
Can't be, no more than 3 AdSense frames per page allowed by Google contract.

Ah... well there are comments associated with every post marked google_ad_section_start and google_ad_section_end. I guess they must be placeholders.

Still, I've given the bug fix, if programmers (hi chroot) would like to get rid of this behaviour some time.

Cheers -- sylas
 

FAQ: Why is the quote text obscured by the advertisement?

What does "Quote obscured by advert" mean?

"Quote obscured by advert" means that a quote or saying has been blocked or hidden by an advertisement. This could be on a website or in a physical location, where the quote is not visible due to the presence of an advertisement.

Why would a quote be obscured by an advert?

In most cases, a quote is obscured by an advert because the advertiser wants to gain more visibility for their product or service. By placing an advertisement in front of a quote, they hope to attract the attention of people who may not have noticed it otherwise.

Is it ethical to obscure quotes with adverts?

This is a subjective question and opinions may vary. Some may argue that it is a form of censorship and goes against the original intention of the quote. Others may see it as a harmless marketing tactic. Ultimately, it is up to the individual to decide what they believe is ethical in this situation.

Can quotes be obscured by adverts without permission?

It depends on the context. If the quote is in a public space, such as a street or park, then anyone can place an advertisement in front of it as long as they have the necessary permits. However, if the quote is in a private space, such as a website or book, then permission from the owner may be required.

How can I view a quote that is obscured by an advert?

If the quote is on a website, you can try disabling your ad blocker or using a different browser. If the quote is in a physical location, you may need to physically move the advert or find a different angle to view the quote. Alternatively, you can try searching for the quote online or in a book to view it without any obstructions.

Similar threads

Replies
12
Views
2K
Replies
1
Views
1K
Replies
2
Views
3K
Replies
147
Views
17K
Replies
6
Views
6K
Replies
3
Views
937
Back
Top