Affiliate Marketing
Forum Search

Reply
 
LinkBack Thread Tools Display Modes

  #1 (permalink)  
Old 09-02-06
Northern Monkey's Avatar
Member
 
Join Date: Jan 2004
Location: UK
Posts: 142
Thanks: 0
Thanked 0 Times in 0 Posts
Northern Monkey is an unknown quantity at this point
  Question Text alignment help

Ok,

I can create a curve in paint shop pro and have text rolling along it but does anyone know how to have a curved alignment e.g.

xxxxxxxxxxx
xxxxxxxxxxx
.xxxxxxxxxxx
xxxxxxxxxxx
xxxxxxxxxxx

This will preferrably be done in paint shop, or if you have a routine to hand in php (bearing in mind I'd just want to enter a bulk of text and let it roll the text over automatically.

Cheers,

NM.
__________________
Holiday Villa In<br>
<font size=2>If it moves, kick it. If it doesn't move, kick it till it moves and hen kick it because it moved</font>

Last edited by Northern Monkey; 09-02-06 at 02:05 PM..
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 09-02-06
Registered User
 
Join Date: Feb 2006
Location: Gillingham
Posts: 503
Thanks: 0
Thanked 0 Times in 0 Posts
Donk is an unknown quantity at this point
You could try something like this

<?php
$inset=20;
?>
<span style="margin-left:<?php echo $inset;?> px">text</span><br>
<span style="margin-left:<?php echo $inset+5;?> px">text</span><br>
<span style="margin-left:<?php echo $inset+10;?> px">text</span><br>

bob
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 09-02-06
Northern Monkey's Avatar
Member
 
Join Date: Jan 2004
Location: UK
Posts: 142
Thanks: 0
Thanked 0 Times in 0 Posts
Northern Monkey is an unknown quantity at this point
Cheers Donk,

After a 2 second flutter I decided to create some of my own nasty code, will post it here when I've finished incase anyone wants it.

NM.
__________________
Holiday Villa In<br>
<font size=2>If it moves, kick it. If it doesn't move, kick it till it moves and hen kick it because it moved</font>
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 09-02-06
Registered User
 
Join Date: Feb 2006
Location: Gillingham
Posts: 503
Thanks: 0
Thanked 0 Times in 0 Posts
Donk is an unknown quantity at this point
This one is based on the quadratic equation ax*x +bx +c

<?php
$text= array ("this","is","a","routine","to","create","curved", "text","just","change","the","variables");
for ($x=0;$x<12;$x++) {
?>
<span style="margin-left:<?php echo curvey($x);?> em"><?php echo $text[$x] ?></span><br>
<?php }

function curvey ($x)
{
$inset=10;
$a=.1;
$b=1;
$c=1;
$y= $a*($x-10)*($x-10)+$b*($x-10)+$c;
$y=$inset-$y;
return $y;
}
?>

bob
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #5 (permalink)  
Old 10-02-06
Northern Monkey's Avatar
Member
 
Join Date: Jan 2004
Location: UK
Posts: 142
Thanks: 0
Thanked 0 Times in 0 Posts
Northern Monkey is an unknown quantity at this point
Ahh just the ticket, now can you just explain the a, b, c?

I need to try and specify maximum bulge width. and at present if you have 15 lines it goes pear shaped and doesn't make a perfect semi circle....

Bloody good so far though, any ideas?

NM.
__________________
Holiday Villa In<br>
<font size=2>If it moves, kick it. If it doesn't move, kick it till it moves and hen kick it because it moved</font>
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 10-02-06
Registered User
 
Join Date: Feb 2006
Location: Gillingham
Posts: 503
Thanks: 0
Thanked 0 Times in 0 Posts
Donk is an unknown quantity at this point
Reducing the $a to say $a=0.05 would flatten the curve. and the x-?? seems to level the top and bottom

The formula is a threwback to my school maths in the 60's so I,m not too sure what the rest of it does.

You can get a graphical representation at this site or google "parabola" if that one doesn't load.

<?php
$text= array ("this","is","a","routine","to","create","curve d", "text","just","change","the","variables","with","f ifteen","words");
for ($x=0;$x<15;$x++) {
?>
<span style="margin-left:<?php echo curvey($x);?> em"><?php echo $text[$x] ?></span><br>
<?php }

function curvey ($x)
{
$inset=10;
$a=.05;
$b=1;
$c=1;
$y= $a*($x-17)*($x-17)+$b*($x-17)+$c;
$y=$inset-$y;
return $y;
}
?>
As the $b+$c are both set to 1 I guess leaving them out won't make much difference. Perhaps a mathemetican could create a general formula based just on the array count

bob
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Getting Code for text links leaddo TradeDoubler 6 01-06-05 07:20 AM
Formatting and storing text? Northern Monkey Widgets, Coding, AJAX, PHP - Technology & Affiliate Marketing 2 16-04-05 10:22 PM
Dell text link will 68 TradeDoubler 2 12-08-03 04:42 AM
fancy text generator emma246 Widgets, Coding, AJAX, PHP - Technology & Affiliate Marketing 5 07-11-02 02:37 AM


Affiliate Marketing RSS Feeds - Contact Us - Affiliate Marketing - Archive - Privacy Statement - Top

Content Relevant URLs by vBSEO 3.2.0 RC7