VideoHelp Forum




+ Reply to Thread
Results 1 to 5 of 5
  1. Member Dr. DOS's Avatar
    Join Date
    Sep 2004
    Location
    Mid Atlantic
    Search Comp PM
    I just implemented some new javascript into a intranet web reporting page I maintain.

    Here is a screen shot of the page.



    The headers are clickable to sort the page but also are too big. and I can't for life of me figure how to change the font.

    Here's the code... anyone have any ideas. I've inserted font tags, p tags all over the page and nuttin is working.

    I tried to primarily insert them in the first myObjectArray but I think my syntax is wrong. Anyone know how to insert proper font / p tags into some jscript.


    Code:
    <SCRIPT LANGUAGE="JavaScript"><!--
    function myObject() {
        for (var i = 0; i<myObject.arguments.length; i++)
            this['n' + i] = myObject.arguments[i];
    }
    
    var objectArrayIndex = 0;
    var myObjectArray = new Array();
    
    function showObjectArray(object,length) {
        var output = '<LEFT><TABLE BORDER=\"2\" CELLPADDING=\"5\">';
        output += '<TR>';
        for (var j=0; j<width; j++)
             output += '<TH><A HREF="reports_new4.htm?n' + j + '">' + eval('object[0].n'+j) + '<\/A><\/TH>';
        output += '<\/TR>';
        for (var i=1; i<length; i++) {
            output += '<TR>';
            for (var j=0; j<width; j++)
                output += '<TD>' + eval('object[i].n'+j) + '<\/TD>';
            output += '<\/TR>';
        }
        output += '<\/TABLE><\/LEFT>';
        document.write(output);
    }
    
    function myObjectBubbleSort(arrayName,length,property) {
        for (var i=1; i<(length-1); i++)
            for (var j=i+1; j<length; j++)
                if (eval('arrayName[j].' + property + 'SurveyPage','Registration Report       
    Program Status Report','');
    Quote Quote  
  2. Sorry Doc, that looks a lot like computer programming! Just moving your topic along a little.

    Cobra
    Quote Quote  
  3. Member mats.hogberg's Avatar
    Join Date
    Jul 2002
    Location
    Sweden (PAL)
    Search Comp PM
    You could make a different style for the <TH> tag: Include:
    Code:
    <style>
    th {font-family:Verdana, Arial;font-size:7pt;color="#FFFFFF";background-color="#a4adc6"}
    </style>
    in the <head> part of your HTML.
    Change the size and color values as you see fit!

    /Mats
    Quote Quote  
  4. Member Dr. DOS's Avatar
    Join Date
    Sep 2004
    Location
    Mid Atlantic
    Search Comp PM
    Thanks Mats....

    I will work on the code

    Tim
    Quote Quote  
  5. Give a go with what mats.hogberg said, otherwise its got me stumped.

    All the things I would normally suggest you've tried by the sounds of it.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!