Jump to content


  • Content Count

  • Joined

  • Last visited

Everything posted by jesh

  1. Are you executing the javascript before the browser has a chance to build the select element?
  2. You're missing an equals sign:<script language="Javascript" src="menu.js" type="text/javascript"></script>
  3. You can't use comment lines like you've described. The following is how you write comments in java script: /* This comment can span multiple lines and is typically used to describe the purpose of a function or to separate different sections of your code like you've suggested */function aFunction(){ // This is a single line comment. // To continue it on the next line, you have // to keep using the double slashes in front of // each line.}// If you want to use special characters, you can simply add// the double slashes in front of them:// ~0~0~0~0~0~0~
  4. Alternatively, you might try this.offsetWidth and this.offsetHeight rather than this.width and this.height. The offset properties do not include the units.
  5. From my understanding, no matter in what order the rules are loaded by the browser, the rules that have the most specific selectors will take precedence. #sidebar ul.sidemenu li.current a is much more specific than * li.current a
  6. Huh, I've used tinymce and it just keeps a copy of the content as text inside the textarea element but sets the display of the textarea to none. What happens if you assign an ID to the textarea and then, at some point after adding content through tinymce, you do: alert(document.getElementById("mytextareaID").value);
  7. jesh


    It may not be a keyword, but it is a method of the document object: <script type="text/javascript">alert(document.clear);</script>
  8. jesh

    Add Value To Query

    Do you mean like this? SELECT Machine AS "All"FROM ParsedDataWHERE (Date >= @Date1) OR (Date <= @Date2)GROUP BY Machine
  9. jesh

    Going Live

    You might start by looking here:http://w3schools.invisionzone.com/index.php?showtopic=3770
  10. If I understand you correctly, you can do what you're asking like so: <table class="TableClassName" cellspacing="0" cellpadding="0"><tr><td>Hello</td><td>World</td></tr></table> Then in the CSS, you can get at the table cells like this: .TableClassName td {padding:2px;background-color:red;}
  11. Have you tried his suggestion? Does it work for you?
  12. Your HTML is malformed (you have an extra forward slash in there): <textarea name="contact_motivatie" type="text" value="" /></textarea> That should read: <textarea name="contact_motivatie"></textarea>
  13. If you want it to only check one at a time, then rather than doing a bunch of if blocks, you can use an if/else block. if (frname==""){ message = "من فضلك املأ حقل الاسم"; success = false;}else if (email==""){ message = "من فضلك أدخل بريدك الإلكتروني"; success = false;} Or, if you want it to check them both, then you'll want to append the error message to the "message" variable rather than assign it: if (frname==""){ message += "من فضلك املأ حقل الاسم" + "\n"; success = false;}if (email==""){ message += "من فضلك أدخل بريدك الإلكتروني" + "\n"; success = false;}
  14. jesh

    Going Live

    You need to find a host to serve your website and you need to upload the files that make up your website there. Also, if you want a memorable name for your website, you'll need to register a domain name and have it point to the hosting server(s).
  15. Keyboard? Monitor? Mouse? Speakers?
  16. What appears to be happening is that you have it set up so that the javascript executes but then the form submits immediately after this so you're not seeing any of the error messages.If you want the form submission to be contingent upon the successful validation of the form, you'll want to remove the onclick event of the submit button and call your function from the onsubmit of the form: <form action="comment.asp" method="post" name="form1" target="_parent" onsubmit="return check();"> Notice the "return" there. This tells the form that if "check()" returns true, submit the form, otherwise, if "check()" returns false, don't submit the form.Then, modify your function to something like the following: function check () { var success = true; var message = ""; var frname = document.getElementById('name').value; var email = document.getElementById('email').value; if (frname=="") { message = "من فضلك املأ حقل الاسم"; success = false; } if (email=="") { message = "من فضلك أدخل بريدك الإلكتروني"; success = false; } if(!success) { alert(message); } return success;}
  17. If you were to alert "_left", you'll probably get "NaN" and I'm guessing this would be because you have a typo here: var _screen = screen.avilWidth;
  18. You're using javascript to modify the CSS. There are ways to do this without using javascript at all. This is what DD is talking about.Here's an example of a menu that uses only CSS:http://www.cssplay.co.uk/menus/dd_valid.html
  19. jesh

    Frame Round Image

    I'm stuck out here on the west coast of the US in Pacific Daylight Time. It seems like everyone on here has at least a two hour head start on me. I have to take every opportunity to get a post in edgewise!
  20. jesh

    Frame Round Image

    You can use CSS: <head><style type="text/css">a img {border:0;}</style></head>
  21. jesh

    Js Follow Links

    Or why it would need to be done 60,000,000 times. You trying to hack something?
  22. That's sounds about right. "#Header img" tells the browser to apply the style to all image elements which exist within an element that has an id of "Header".
  23. That's just the way that functions are defined in javascript. To declare a function: function myFunction(){} And to call a function: myFunction(); It's part of the syntax of the language.
  24. The problem is in your quotes. You have: oCell.innerHTML = "<input type='text' name='SubSocialSecurity' maxlength="11" />"; It should either be this: oCell.innerHTML = "<input type='text' name='SubSocialSecurity' maxlength=\"11\" />"; or this: oCell.innerHTML = "<input type='text' name='SubSocialSecurity' maxlength='11' />";
  25. One way is to use CSS: <html><head><style type="text/css">a {padding-left:20px;}a:hover {background:url(http://w3schools.invisionzone.com/style_images/1/folder_profile_portal/user-offline.png) no-repeat;}</style></head><body><a href="http://www.w3schools.com/">W3Schools</a></body></html> If that's not quite what you're looking for, it might be best if you posted the code you have so far and someone'll be able to help.
  • Create New...