www.webdeveloper.com

Search:

Type: Posts; User: ricp

Page 1 of 19 1 2 3 4

Search: Search took 0.06 seconds.

  1. Replies
    1
    Views
    12,742

    You can create a new Date object using the epoch...

    You can create a new Date object using the epoch time.

    var myDate = new Date( epochTime );
    alert(myDate.toUTCString());

    Docs:...
  2. Replies
    2
    Views
    725

    onclick="changeClass('tablecell',this.checked?'new...

    onclick="changeClass('tablecell',this.checked?'newclassname':'oldclassname');"

    ..not that yours was incorrect, of course.
  3. Replies
    5
    Views
    1,158

    :eek: That has to be some of the worst code I...

    :eek:

    That has to be some of the worst code I have ever seen. You are effectively opening 8 browser instances with those eval's.

    I am off to go an lie down, it's all too traumatic..
  4. Replies
    2
    Views
    5,141

    Stored Procedure? As a database one? If so,...

    Stored Procedure? As a database one?

    If so, you aren't doing that with client side script alone, you will need some server side language to do the actual query.
  5. Replies
    1
    Views
    679

    Two things here, a preloader and an image...

    Two things here, a preloader and an image rotator. Both simple.

    In regard to a preloader, it get's no simpler than:



    var img = new Image();
    img.onload = function(){ alert("I've loaded"); }...
  6. Replies
    3
    Views
    1,555

    You can't is the simple answer. In IE you...

    You can't is the simple answer.

    In IE you could (pre v7) add "fullscreen=yes" to force kiosk mode (you can also do it from the command line by calling IE with a -kiosk parameter). However that has...
  7. Replies
    1
    Views
    717

    Ok,well you can pick up the x/y co-ords of the...

    Ok,well you can pick up the x/y co-ords of the mouse pointer, that's easy enough with the .x / .y (for IE) and .pageX / .pageY (for Moz) properties on the event object.

    However to find the...
  8. Replies
    1
    Views
    476

    By the sounds of it you are talking about...

    By the sounds of it you are talking about xmlhttp, especially so as you've called your page ajax.html.

    You can read more about xmlhttp here: http://faq.ii.no/xmlhttp

    However I am not clear on...
  9. Replies
    2
    Views
    574

    Could you mark which ones are the same? for...

    Could you mark which ones are the same? for example, is the "multisection combo box" (which by that I presume you mean a multiple select) the same one or is there three?

    In general btw, it is very...
  10. Replies
    3
    Views
    529

    fixing the problem would be the most obvious...

    fixing the problem would be the most obvious solution.. ;)

    to show errors (and equally to hide them) read this: http://faq.ii.no/showerrors
  11. Don't disable the submit button if you are trying...

    Don't disable the submit button if you are trying to stop multiple submissions, some browsers don't like it. A more elegant way is to stop the submission like so:



    <form .. .. onsubmit="if...
  12. Replies
    16
    Views
    1,317

    ricp's js annoyance list: #1 using an...

    ricp's js annoyance list:

    #1 using an evaluated string in a setTimeout/Interval.

    setInterval(function, delay);

    not

    setInterval("function()",delay);
  13. Replies
    7
    Views
    798

    Good work, mrhoo :) btw, just incase anyone...

    Good work, mrhoo :)

    btw, just incase anyone wasn't aware of it, but the offsetHeight/Width takes into consideration any padding/borders/margins depending on the box model you are using.
  14. Replies
    19
    Views
    1,463

    One minor thing to add onto this, it's not just...

    One minor thing to add onto this, it's not just accessibility you are looking to support, but also other devices. There are numerous different mobile devices out there all with differing levels of...
  15. Does the container have a fixed height? If so...

    Does the container have a fixed height? If so then you can do it entirely via CSS.



    #myContainer {
    width:200px;
    height:200px;
    position:absolute;
    top:50%;
    left:50%;
  16. Thread: window scroll bar

    by ricp
    Replies
    2
    Views
    691

    All depends on when you want to do it. As it's...

    All depends on when you want to do it. As it's opened you can set scrollbars=0 in the properties of the window.open method, like so:



    window.open("foo.html", "foo", "scrollbars=0");


    Once...
  17. Replies
    3
    Views
    641

    You need to change method format () to that of a...

    You need to change method format () to that of a collection [], and the innerText can be replicated by detecting the .nodeVale of the child text node. So:


    ...
  18. Got me stumped. All the onkey events...

    Got me stumped.

    All the onkey events (on/up/press) return identical values from both keys and there isn't any property to pick up on the event object to detect if it's the keypad used (or even if...
  19. Replies
    8
    Views
    875

    An example would be helpful, but as I am at work...

    An example would be helpful, but as I am at work and I am only checking the site in between meetings, you'll need to wait for it.. ;)
  20. Replies
    25
    Views
    4,335

    If you want a cross browser and cross platform...

    If you want a cross browser and cross platform solution for playing media in a webpage, use flash. Doing so removes most of the problems that leaving the audio (or video) to the designated default...
  21. Thread: onresize problem

    by ricp
    Replies
    4
    Views
    579

    Right, I don't have WinXP/SP2/IE6 to test that,...

    Right, I don't have WinXP/SP2/IE6 to test that, but what I will say is dump all that controlling JS. It's totally not needed as and it can be replace by about 4 lines of CSS.

    Basically imagine you...
  22. Replies
    5
    Views
    4,055

    Could I just say, it is far more sensible to make...

    Could I just say, it is far more sensible to make one page the degrades elegantly for whatever is viewing it. It's the classic "object detection" vs "browser detection" however for your case replace...
  23. You can. ...

    You can.



    window.open("http://mozilla.org","foo","location=0");


    However there are conditions.

    1) IE7 won't allow windows with address and status bars.
  24. Replies
    2
    Views
    693

    "Any idea on how to do it?" As in how to...

    "Any idea on how to do it?"

    As in how to create an xmlhttp request? Read this: http://faq.ii.no/xmlhttp

    I believe that when running an extension (or Greasemonkey script) you are running in a...
  25. Hmm... I would ask about this in the ASP or...

    Hmm...

    I would ask about this in the ASP or SQL forum and not JS, as the only javascript related piece of code (the MM_ vars) is valid.
Results 1 to 25 of 452
Page 1 of 19 1 2 3 4
HTML5 Development Center



Recent Articles