Jump to content


Photo

Dot leaders


  • Please log in to reply
4 replies to this topic

#1 JTFinNH

JTFinNH

    Newbie

  • Member
  • Pip
  • 7 posts

Posted 08 April 2007 - 05:54 AM

I have to admit that the last time I asked this in a public forum, that I was responded to like a child who should know better; but, seriously I do not know how to accomplish this. I know I can create dot leaders using the str_pad function. Unless I use pre tags they don't line up. Unless I'm doing something wrong, I'm also ending up with a generic font as well. I know there is at least one, if not serveral methods of accomplishing this. I do not know any of them.

Please reply with a solution and indicated if there is a php version limitation.

#2 megan

megan

    Support Team Member

  • Support Team
  • PipPip
  • 92 posts

Posted 08 April 2007 - 07:41 AM

I'm a coldfusion programmer and know nothing of php, but have you tried styling your output using css and the span tag - you know, create a special class in your style sheet that sets font-family, alignment, size, color etc, and then use span class=myclass around the dots ???

hth ~megan

#3 JTFinNH

JTFinNH

    Newbie

  • Member
  • Pip
  • 7 posts

Posted 11 April 2007 - 03:16 PM

I'm a coldfusion programmer and know nothing of php, but have you tried styling your output using css and the span tag - you know, create a special class in your style sheet that sets font-family, alignment, size, color etc, and then use span class=myclass around the dots ???

hth ~megan


A CSS Solution is a beginning. I've either got to find a way to precalculate the width of font for the "non-dot" text and accomodate it, using your solution, or find some way to retain the font-face yet have uniform, no pun intented, character widths. I believe somewhere within text or font attributes that there is a monospace attribute, I think the question is to whether or not the major browsers support it or not.

#4 Ric

Ric

    Project Manager

  • Admin
  • PipPipPipPipPip
  • 1,535 posts
  • Gender:Male
  • Location:Cambridge,UK
  • Interests:Electronics
    Internet in general
    Open source projects
  • SourceForge IDmpgcan
  • Wiki ID: Ric
  • Main OS: Windows XP

Posted 11 April 2007 - 03:50 PM

This page may be of interest:

http://home.tampabay...ot-leaders.html

Save the page and view itís source, there are two additional links these may also help.
:lol:

#5 Ric

Ric

    Project Manager

  • Admin
  • PipPipPipPipPip
  • 1,535 posts
  • Gender:Male
  • Location:Cambridge,UK
  • Interests:Electronics
    Internet in general
    Open source projects
  • SourceForge IDmpgcan
  • Wiki ID: Ric
  • Main OS: Windows XP

Posted 17 April 2007 - 06:17 PM

If it bugs me, I will look at it, never even considered this. Just hate to push you to another site. Hope this will help its not definitive but contains a few ideas.

http://center.unifor..._leaders_1.html

:lol:




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users