User Profile

Collapse

Profile Sidebar

Collapse
zaphod42
zaphod42
Last Activity: Nov 23 '08, 09:08 PM
Joined: Oct 3 '08
Location: USA
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • zaphod42
    replied to onmouseover in option
    the problem is in the case of the characters he is using in his html tag....regardle ss of how his functions work, onmouseover is supposed to be "onMouseOve r" inside of html tags
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to onmouseover in option
    The answer is in this link..... Google Search for html onmouseover....notice how it's spelled
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to events and forms
    yeah, I figured that out as well, I set the onchange event of the fieldset, but it really works more like a custom method at this point, I have it set up so that on focus of the radios the appropriate argument is sent to the onchange method of the fieldset....I had initially set the radios to onchange also, but ran into a problem as ie fires the events differently than firefox...the onchange event seemed to fire BEFORE the appropriate radio was actually...
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to events and forms
    yup....this is my tester copy, mostly my stuff with very little relative to the job, so it should be cool to post. There are mosre functions and files that go along with this obviously, but this should give you an idea....the only problem I'm still having is the wierd event when you fire onchange events for a fieldset and it relative radio buttons

    the idea is that we have a set of "template" fields:

    Code:
    GL.FieldItems['EU
    ...
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to Dynamic display of fields.
    nope, just a couple answers and this great link;)

    Usable Forms
    See more | Go to post

    Leave a comment:


  • getElementById. ...it's spelled wrong....and it should work, it's a method with a return, than means assignment inside of it's own scope....

    actually if you google "GetElementByID ", you get a list of sites that tell you how to use it properly;)
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to events and forms
    thanks for the thought acoder;) turns out I can't post this particular code online. Apparently large companies don't like proprietary script available for free online:p

    anyway, it turned out that the problem was in my 'bind' method, the known issues of dynamic form generation seem to still be mostly relative to ie and radio boxes;)
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to Dynamic display of fields.
    you could build the whole form with all possible fields, and toggle the visibility of the fields with the "display" property of the "style" object when you change the select box...do you have anything you've got started?
    See more | Go to post

    Leave a comment:


  • when you submit you could call a function to do it....e.g.:

    Code:
    function submitMyForm(form){
       var concat;
       var i;
       for(i in form.elements){
          if(form.elements[i].value){
            concat+=parseFloat(form.elements[i].value)
          }
       } 
       return concat
    }
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to events and forms
    I'll see if I can put together a small sample, it's generated from json style notation in a string....it's about 1200 lines of js and a few php files, so I didn't want to try to post the whole thing, I'll see if I can get it on a server with a link....it's a agent tool for a call center, so it's not something that will actually be online.

    Mostly I was just curious if there was a known issue....I use firebug and visual studio for debugging...
    See more | Go to post

    Leave a comment:


  • zaphod42
    started a topic events and forms

    events and forms

    funny thing....I'm dynamically building forms, well, WAS building forms, but for this project I need some very specific validation and logic handling, so while I was changing my functions to deal with this, I ended up with a "form" that is just a span with form elements inside of it, submit works fine (custom submit too), all my validation fires properly, the only thing that isn't working is setting my events.

    When I started...
    See more | Go to post

  • zaphod42
    replied to Javascript Subroutine Problem
    I can't see where myPhoto is defined in the scope of what you're doing....do you have any more javascript on the page?
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to Problems in offsetLeft.
    well...... first of all, you set the elements position to 'relative'...th e idea of relative is that it positions it relative to it's siblings....if you could move it, it would no longer be relative, it would have to be 'absolute'.
    Code:
    movDiv_1.style.position = 'relative';
    And since offsetLeft ALWAYS returns a number, (not to mention that when you add 'px' you change it to a string anyway) , the parseInt is not really necessary....
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to Changing CSS Styles in a main page
    if you want to do it client side you could add a hash to the url to tell the pages which link was clicked...but you would also have to add that hash to and local links on your page to ensure the style loads properly
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to Changing CSS Styles in a main page
    what....theoret ically.... would you like to do?
    Do you want to change css classes you have already defined?
    Are you looking to define and handle all classes in javascript?
    There are ways to do either of these, and more....do you have a page started?

    the basics are:

    Code:
         myHTMLElement.style.border="2px red groove"
         myHTMLElement.style.zIndex=3
    
    or
    ...
    See more | Go to post

    Leave a comment:


  • Based on what you said, it sounds like you need to look into "cloneNode" and "removeChil d". This is a neat article about dynamically copying form fields on your site with javascript:)

    QuirksMode domform...
    See more | Go to post

    Leave a comment:


  • zaphod42
    replied to Constructors!!!
    that's great, thanks! It just figures that this company would still be using ie6....internat ionally! Get on the ff bus people!
    See more | Go to post

    Leave a comment:


  • zaphod42
    started a topic Constructors!!!

    Constructors!!!

    Does anyone know if you can access/add to the prototype for an elements constructor with javascript? The idea is I would like to add default functionality to certain elements (specifically "Label" elements). The company that this project is for has all of their forms in flat html files that I load with ajax and add to object groups for easier manipulation, it would be really helpful if I could add the methods necessary when the html elements...
    See more | Go to post

  • zaphod42
    replied to Start Time and End Time Validation
    the value of the select boxes is a string right now, try this:


    Code:
    var start=startTimeValue.options[startTimeValue.selectedIndex].value*1
    var end=endTimeValue.options[endTimeValue.selectedIndex].value*1
    if( start > end)
    javascript will try to preform the math (*1), and will change the "string" to actual numbers if there aren't any letters in it:) There is a little more logic involved...
    See more | Go to post

    Leave a comment:


  • sorry, should have read the code more thoroughly:p
    See more | Go to post

    Leave a comment:

No activity results to display
Show More
Working...