word wrap trick..

  • roulettered56
  • Newbie
  • Newbie
  • roulettered56
  • Posts: 10

Post 3+ Months Ago

Hey guys,

let's imagine I have a content area on my page:

Code: [ Select ]
<div id="content">
            <p>
                     **Content etc**
            </p>
        </div>
  1. <div id="content">
  2.             <p>
  3.                      **Content etc**
  4.             </p>
  5.         </div>

I'd like to have an Adsense/HTML block at the top right of the text/content in which the the text wraps around.

texttexthtmlhtml
texttexthtmlhtml
texttexthtmlhtml
texttexttexttext
texttexttexttext
texttexttexttext

Can this be done?

Thank you so much for your help and don't hesitate to ask for any help.

Louis
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • righteous_trespasser
  • Scuffle
  • Genius
  • User avatar
  • Posts: 6230
  • Loc: South-Africa

Post 3+ Months Ago

I haven't ever done anything like that ... maybe something like the following could work like with images almost:
HTML:
Code: [ Select ]
<div id='content'>
<div id='adsense'>Some Ads</div>
Some content here.
</div>
  1. <div id='content'>
  2. <div id='adsense'>Some Ads</div>
  3. Some content here.
  4. </div>

CSS:
Code: [ Select ]
div#content{
width:980px;
}
div#adsense{
width:400px;
float:right;
}
  1. div#content{
  2. width:980px;
  3. }
  4. div#adsense{
  5. width:400px;
  6. float:right;
  7. }
  • tastysite
  • Proficient
  • Proficient
  • User avatar
  • Posts: 349
  • Loc: Brighouse, West Yorkshire, England

Post 3+ Months Ago

why not make 3 div's like so

texttexthtmlhtml
texttexthtmlhtml
texttexthtmlhtml
texttexttexttext
texttexttexttext


KEY:
Red part <div id="top">texttext</div>
Green part <div id="adsence">your google ads</div>
The Blue part <div id="fulltext">there rest of you text</div>

AND THEN YOU WOULD NEED TO WORK OUT THE CSS CODE, but the above one is probley more easy IF it works but use this way as a fall back cos this one will work even if it is a bit fiddly!
  • roulettered56
  • Newbie
  • Newbie
  • roulettered56
  • Posts: 10

Post 3+ Months Ago

Of course.. 3 parts ;)

Thank you guys I really appreciate it.

Louis
  • righteous_trespasser
  • Scuffle
  • Genius
  • User avatar
  • Posts: 6230
  • Loc: South-Africa

Post 3+ Months Ago

The thing is with three parts, the text won't be allowed to be dynamic, and you'd have to make it static text otherwise how will you know how much text to pull out from the database because all letters aren't the same size
  • tastysite
  • Proficient
  • Proficient
  • User avatar
  • Posts: 349
  • Loc: Brighouse, West Yorkshire, England

Post 3+ Months Ago

What database? No one said anything about a one!
  • righteous_trespasser
  • Scuffle
  • Genius
  • User avatar
  • Posts: 6230
  • Loc: South-Africa

Post 3+ Months Ago

I know ... I am just thinking ahead ...
  • roulettered56
  • Newbie
  • Newbie
  • roulettered56
  • Posts: 10

Post 3+ Months Ago

Hmm, I tried the first way but all that's showing is the text. The 3 part way is a bit complicated to simply wrap text around something.

I'm not saying this is an easy job But I'm sure it can be done.

Any solutions?

All the best
  • neksus
  • Mastermind
  • Mastermind
  • User avatar
  • Posts: 2194
  • Loc: Canada

Post 3+ Months Ago

Uhh...container div, text, float div in the container?
  • righteous_trespasser
  • Scuffle
  • Genius
  • User avatar
  • Posts: 6230
  • Loc: South-Africa

Post 3+ Months Ago

yeah like I showed in my first reply ... it does work ... I just tried it ...
  • roulettered56
  • Newbie
  • Newbie
  • roulettered56
  • Posts: 10

Post 3+ Months Ago

Would you be able to post the template example code showing it work please Rihteous?

Not that I don't beleive you it's just I want to see where I went wrong.

I'm viewing in IE.
  • righteous_trespasser
  • Scuffle
  • Genius
  • User avatar
  • Posts: 6230
  • Loc: South-Africa

Post 3+ Months Ago

  • roulettered56
  • Newbie
  • Newbie
  • roulettered56
  • Posts: 10

Post 3+ Months Ago

OK guys I'm still looking for a work around as Righteous_trespasser's help did not show in IE for me. much appreciated though, thank you.

I pasted the code into a text file and saved as html to view.

Post Information

  • Total Posts in this topic: 13 posts
  • Users browsing this forum: No registered users and 78 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.