Results 1 to 1 of 1

Thread: A little help please with:Mike's DHTML scroller

  1. #1
    Join Date
    Jul 2005
    Location
    Staffordhsire
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Exclamation A little help please with:Mike's DHTML scroller

    Script: Mike's DHTML scroller

    http://www.dynamicdrive.com/dynamici...mikescroll.htm

    I am using Mike's scroller in a few webpages, and have modified the various bits for its general use, ie color,positions etc. and all is ok.

    I want to 'format' the position of the text within the display based on the inclusion of 'spaces' to pad out the text, I am using the Courier New font as this is a 'block' font where all the characters take the same space.

    I could not see any varible for positioning the text in the display box such as 'center', 'left', 'right' etc. which would solve the problem.

    Its no use using the xpos,padding parameters as it needs to be global to all the display messages.

    An extract of the code is:

    var myScroller1 = new Scroller(0, 0, 535, 30, 0, 10); //(xpos, ypos, width, height, border, padding)
    myScroller1.setColors("RED", "WHITE", "WHITE"); //(fgcolor, bgcolor, bdcolor)
    myScroller1.setFont("Courier New,black,Helvetica", 3);
    //myScroller1.addItem("<b>123456789012345678901234567890123456789012345678901</b>");
    myScroller1.addItem("<b>...............W H A T S N E W..................</b>");
    myScroller1.addItem("<b>............UPDATED 14TH JULY 2005.........</b>");
    myScroller1.addItem("<b>..........======================......</b>");

    (In my code the full stops (.) are actually spaces, but this forum strips the spaces out as well, so you don't get a true representation of the code content)

    In the 'additem' string, the spaces are ignored by the code, I have tried including some special characters (using the ALT+keycode) but these generate an error.

    Any suggestions please.

    regards

    Roy Yates
    Last edited by royyates; 07-14-2005 at 01:59 PM.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •