how can i get the height value of a table calculate with certain number and display

Discussion in 'PHP' started by macaela, Jul 28, 2011.

  1. #1
    Hi i have this table that retrieves data from the database (images) now i was wondering if is possible to get the height of the images multiply with the number of data that comes from the database and give the value into the ajax div example
    <table>
    <tr>
    <td height='90'> pick up this height value
    </td>
    </tr>
    </table>
    height * number of row from the database = $result
    number row from database * 90 =$result
    add the result value into the ajax div height
    <div id="ajaxDiv" style="height:$result.px"> </div>

    or get the number of row retrieve from the database calculate * 90
    and give the value to the
    <div id="ajaxDiv" style="height:$result.px"> </div>
     
    macaela, Jul 28, 2011 IP
  2. JohnnySchultz

    JohnnySchultz Peon

    Messages:
    277
    Likes Received:
    4
    Best Answers:
    7
    Trophy Points:
    0
    #2
    this must not be under PHP..

    anyway...

    why do you have to set the height of the div? you can set it to height:auto so the div will automatically resize to whatever the height of the content is..
     
    JohnnySchultz, Jul 29, 2011 IP
  3. macaela

    macaela Active Member

    Messages:
    181
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    51
    #3
    because the autoflow doesnt show on iphone has iphone doesnt display scrollbar unlesss use some sort of javascript, well i cant find any other way of display scrollbar without some sort of javascript so i am using the jScrollPane but that doesnt display scrollbar if databa coming from the database has it has to be set in the code itself my plan is trying to post the height of the table into the other page and insert the value into the div anyone can help me please
     
    macaela, Jul 29, 2011 IP