Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: jaschulz
  • Content: Threads
  • Order by date
  1. jaschulz

    scrollIntoView

    I am trying to make scrollIntoView() work (with selected text in a div), but I am having no luck. I have put up a little demo that shows the problem. It's at: http://www.wiseware.com/selectTest FF is my main concern. Of course, I would be happy to find a solution that works in IE, too...
  2. jaschulz

    http request buffer size limit

    I am working on an app that uses http requests (to local files) to fill a div. The files are large, but not huge (the largest is a little less than 1000KB) but even though there is no error during the request, I find that files larger than ~100kb do not fully load. When I load one of the...
  3. jaschulz

    Local vs. Remote

    I found a little image preload utility that works correctly only when the page is accessed remotely. The problem is with its error handling function. If one of the images to be preloaded is missing (and in the example I have posted, the image rockwell.jpg is not on the server), it should show...
  4. jaschulz

    pass by value

    How can I pass a copy of an image stored in an array to a scaling function? I have the scaling function, and it works fine, but if I pass the image to it like this: scaleThis(imageArray[x]) the original image (stored in the array) gets scaled. This is not what I want, I only want to scale a...
  5. jaschulz

    Two Questions

    1. How do I include a line feed in a string passed to document.createTextNode()? I have tried \n and <br />, but the former is simply swallowed with no effect, and the latter shows literally in the parent div. 2. I have borrowed and implemented a preload image routine that works fine online...
  6. jaschulz

    text-size change event???

    What event occurs when the user changes the text size on a page via the Browser's Ctrl++ key combination? How would I listen for this event and respond to it? Thanks, JAS
  7. jaschulz

    window.onload vs. &lt;body onload =

    What is the difference between window.onload and the onload event in the body tag? IE7 seems to treat them differently than FF2, Safari 3 and Opera 9 (Win XP PRO SP2). Is there a reason to prefer one over the other? Does it make a difference if window.onload appears in an imported script...
  8. jaschulz

    I don't understand this error

    I have been trying to study some code I found at: http://www.webreference.com/programming/javascript/gr/column3/ for preloading images. The demo site described on the page above no longer exists, so I had to build my own from the article. I did that, and you can see it at...
  9. jaschulz

    how to style dynamically created elements in IE

    I have posted an example page at: http://www.wiseware.com/test that shows a problem with the way IE7 handles (or rather, refuses to handle) styles applied to dynamically created elements. The page loads perfectly in FF2, Safari 3 and Opera 9, but I cannot find anyway to get IE7 to do it right...
  10. jaschulz

    how to load css (dynamically) in Safari

    The function below works fine in FF, IE and Opera. But it does not work in Safari. Is there a work-around for this problem? thanks, JAS function loadStyles() { var oLink = document.createElement('link') oLink.href = './CSS/myStyles.css'; oLink.rel = 'stylesheet'; oLink.type =...
  11. jaschulz

    how to get id of dynamically created element

    I create several input elements like using this function (with a different iID argument each time): function createResponseItem(iID) { var newInput = document.createElement('input'); newInput.setAttribute('id','response-' + iID); newInput.setAttribute('type','radio')...
  12. jaschulz

    how to concatenate &amp;bnsp;

    I need to build a string like this: str = "1.&nbsp;&nbsp;some other text"; This string will become the content of a new textnode (of a <p> element), but when I try the above, I get the literal characters &nbsp; rather than a non-breaking space. What's the right way to do this? Thanks, James
  13. jaschulz

    replace string with new line

    I want to test various regexp against a specific piece of text, so I wrote a function that creates a new regexp from user input. It works fine, except that if I try to replace a given string with a new line (i.e. "\n"), I get the backslash and the "n" instead of a new line. My function looks...
  14. jaschulz

    getSelection() question

    Can a script running in the FF sidebar get the currently selected text in the main FF window? If so, how is this done? Thanks, JAS
  15. jaschulz

    get selected text question

    I want to get the text currently selected in a document being edited in Google Docs. The following does not do the job (though it works fine in every other context where I have tried it): var thisText=window.getSelection ? window.getSelection() : document.getSelection ? document.getSelection()...
  16. jaschulz

    a second try

    I asked a question the other day about using javascript to do TCP, but nobody responded. What I want to do is simple enough: I just want to use javascript to send a request to the server at dict.org. Is that possible? Thanks, JAS
  17. jaschulz

    TCP

    A newbie question to be sure: Can I use javascript to make a TCP call? If so, can you point me to any help, tutorial or the like for doing this sort of thing? Thanks.
  18. jaschulz

    onclick question

    Does the function called by an onclick event know the id of the dom element that was clicked? For instance, given: <a href="#" id="DUMMY" onclick="myProc()">Dummy</a> does myProc know it was called by DUMMY, and if it does, how do I refer to DUMMY within the body of myProc? Thanks, JAS
  19. jaschulz

    Beginning AJAX question

    My HTTPRequest always returns status = 0 (which is not even listed on the WC3 page of possible responses). I am retrieving a simple text file, and the responseText does contain the text I want. So my function works even though the status is 0. What does status = 0 mean? Is this a real...
  20. jaschulz

    Scroll Question

    I have a div with a fixed height and overflow: auto. I set the content of this div via a (prototype) ajax call. Sometimes the content is long enough to force a vertical scroll bar, sometimes it isn't. If I load content A, and it is long enough to force the scroll bar, and then I use the...

Part and Inventory Search

Back
Top