Jump to content

westman

Members
  • Content count

    546
  • Joined

  • Last visited

Community Reputation

10 Good

About westman

  • Rank
    Invested Member
  1. set scroll to the bottom of a div

    Thank you so much. I tried it and it works very well.
  2. set scroll to the bottom of a div

    It works nicely in the link you posted but not for me. I am also using this script to call in info to fill class="mail_text". $( document ).ready(function() { $('.pmbutton').click(function(e) { $('.mail_text').load('scripts/message.php', { id : $(this).data('id'),id2 : $(this).data('id2') }); }); }); Could I somehow insert the code needed in here?
  3. set scroll to the bottom of a div

    <div id="mail_text" class="mail_text" style="max-height:400px; overflow:auto;"> &nbsp; </div> <script type="text/javascript"> var objDiv = document.getElementById("mail_text"); objDiv.scrollTop = objDiv.scrollHeight; </script> I am using Chrome. Is there a better peace to put my JS? My example is not working.
  4. set scroll to the bottom of a div

    I tried using var objDiv = document.getElementById("mail_text"); objDiv.scrollTop = objDiv.scrollHeight; but with no luck
  5. skipping a loop or two in a while loop

    okay, works well. thank you.
  6. set scroll to the bottom of a div

    I have many lines of text. <div style="max-height:400px; overflow:scroll;"> many lines of text </div> How do I get my css to display a div at the bottom instead of the top of a scrollable div?
  7. skipping a loop or two in a while loop

    without else{ continue; } my code pulls out duplicates from the database. my code only works correctly with "continue;" in place.
  8. IE markup with <ul> <li>

    Thank you again Dsonsuk. It works well. I removed the junk and it is all vertical.
  9. IE markup with <ul> <li>

    I am using IE 11. Here is the output in chrome and ie 11
  10. IE markup with <ul> <li>

    I am not a fan of Internet Explorer but trying to get my html and css working well with it. #nav { font-family:"Arial Black", Gadget, sans-serif; text-align:left; display:inline-block; width:0px auto; /*width:100%; text-align:right;*/ margin:0px auto; padding:0; background:#5C5B5E; /* background color */ border-radius:10px; /*some css3*/ -moz-border-radius:10px; -webkit-border-radius:10px; /*box-shadow:0 2px 2px rgba(0,0,0, .5); -moz-box-shadow:0 2px 2px rgba(0,0,0, .5); -webkit-box-shadow:0 2px 2px rgba(0,0,0, .5);*/ } #nav li { margin:10px; float:left; position:relative; list-style:none; } #nav ul li:first-child > a { -moz-border-radius-topleft:10px; /*some css3*/ -moz-border-radius-topright:10px; -webkit-border-top-left-radius:10px; -webkit-border-top-right-radius:10px; } #nav ul li:last-child > a { -moz-border-radius-bottomleft:10px; /*some css3*/ -moz-border-radius-bottomright:10px; -webkit-border-bottom-left-radius:10px; -webkit-border-bottom-right-radius:10px; } #nav ul { opacity:0; visibility:hidden; padding:0; width:175px; position:absolute; background:#5C5B5E; /*sub background color*/ border:1px solid #5C5B5E; /*sub border color*/ border-radius:10px; /*some css3*/ -moz-border-radius:10px; -webkit-border-radius:10px; box-shadow:0 2px 2px rgba(0,0,0, .5); -moz-box-shadow:0 2px 2px rgba(0,0,0, .5); -webkit-box-shadow:0 2px 2px rgba(0,0,0, .5); -moz-transition:opacity .25s linear, visibility .1s linear .1s; -webkit-transition:opacity .25s linear, visibility .1s linear .1s; -o-transition:opacity .25s linear, visibility .1s linear .1s; transition:opacity .25s linear, visibility .1s linear .1s; } #nav ul li { float:none; margin:0; } <div style="position:relative; z-index:2;"> <ul id="nav"> <li><a href="?p=home#home">Home</a></li><br /> <li><a href="?p=home#services">Services</a></li><br /> <li><a href="?p=home#about">About us</a></li><br /> <li><a href = "javascript:void(0)" onclick = "document.getElementById('signin').style.display='block';document.getElementById('fade').style.display='block'">Login</a></li> </ul> </div> How do I get this to be IE friendly?
  11. skipping a loop or two in a while loop

    thank you so much.
  12. skipping a loop or two in a while loop

    Dsonesuk, Thank you. Here is my new code $uniqueValueArray = []; while ($stmt->fetch()) { $mail_main[] = $mainRow; if (!in_array($mainRow, $uniqueValueArray)) { $uniqueValueArray[] = $mainRow; }else{ continue; } } // END while ($stmt->fetch()) { echo implode(', ', $uniqueValueArray); It seems to work well. Is there any way I can remove the error Adobe DW is showing me with $uniqueValueArray = []; ?
  13. skipping a loop or two in a while loop

    thank you very much for the examples. I am not sure I am using them right in my code. while ($stmt->fetch()) { $mail_main[] = $mainRow; //$uniqueValueArray = []; this alone shows an error in Dreamweaver $uniqueValueArray [] = $mainRow; while($row = $stmt->fetch()) { if (!in_array($row, $uniqueValueArray)) { $uniqueValueArray[] = $row; } } } // END while ($stmt->fetch()) { echo implode(', ', $uniqueValueArray); What am I doing so wrong?
  14. skipping a loop or two in a while loop

    I have updated the code once more... $main_arr = ''; $main_arr_array = ""; // code while ($stmt->fetch()) { $mail_main[] = $mainRow; $main_arr_array = explode(",", $main_arr); if (in_array($mainRow, $main_arr_array, TRUE)){ continue; //break; }else{ $main_arr .= ''.$mainRow.', '; //$main_arr .= implode(", ",$mainRow); //$tmparray = implode(", ",$tmparray); } } I am still not getting the skip. Could you give a code example please?
  15. skipping a loop or two in a while loop

    thank you. I didn't see that. I have updated my code $main_arr_array = explode(",", $main_arr); if (in_array($mainRow, $main_arr_array, TRUE)){ continue; //break; } $main_arr .= ''.$mainRow.', '; echo $main_arr; This is the result... 5, 6, 5, 4, 3, 2, 1, I only want one 5 to show. How do I skip the loop?
×