Jump to content

DanDaBeginner

Members
  • Posts

    211
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

DanDaBeginner's Achievements

Member

Member (2/5)

0

Reputation

  1. how can sort the countries by ASC but with USA and Canada being the first.... I guess it will be something like: SELECT * FROM countries ORDER BY (country_name IN ('USA','CANADA')) ASC, country_name DESC.. Thanks in advance...
  2. wow chee thanks.. I thought that I need to submit my class or register to GNU (if for example im gonna use the GNU.).
  3. thanks ToonMariner . so meaning, for example is, all I just need to do is choose among this license that I think will be best suit for my classes, then include it (commented inside the class) on my classes stating that this class is under GPU.. thats it?
  4. hello guys and gals... how to have a license for my PHP and javascript classes? something like GNU General Public License, etc.. I've developed/currently developing a simple classes of PHP and javascript for my personal use, and thought it will be a help to others, so im going to make them available for the public/community.. but before doing that I want to have a license for them.. but how? thanks..
  5. solved.. in IE the document must be fully loaded before you can assign an handler to it.. (i guess) because my problem got fix when I added a setTimeout("set()",0). set() is the function that will assign an eventhandler to document. solve button is missing so i can't solved this thread...
  6. ok.. im trying to take an advantage on the bubbling phase of the event handler.. so I attached an onclick on the document object which the function e. I attached an onlclick event on document object to track every click on its childs, will be therefore handled by function e. as you can see on function e, it checks whether the souce/ target element is an <a> tag then checks whether this <a> tag has a rel attribute with a value of 'alert'. if true then it will alert its innerHTML. my problem is everything goes well on mozilla, bubbling phase was captured and it alerts for those <a> tags that has rel='alert' . but in IE nothing happens, and the worst is theres no errors popping up.. if you are interested i can send you the html file, 1.11 kb. hope I explained it very well.. thanks again.
  7. thanks for your response.. for sure there was a problem.. can you atleast give me a hint on whats the problem? are you using a debugger or something?
  8. I have this code just to practice on how to work with delegation.. and I was suprised that this code was not working in IE.. please somebody explain it to me why its not working.. this is place on the head tag of my .html <script> function e(y) { var y = y || window.event; var t = y.target || y.srcElement; if (t.nodeName.toLowerCase() === 'a') { if (t.rel == 'alert') { alert(t.innerHTML); return false; } } } add = function() { var t = document.getElementById("test"); var a = document.createElement("a"); a.rel = 'alert'; var text = document.createTextNode("Added"); var br = document.createElement("br"); a.href="5"; t.appendChild(br); a.appendChild(text); t.appendChild(a); } document.onclick = e; </script> in the body <div id="test"> <a href="1" rel="alert">Hello</a><br /> <a href="2" rel="alert">Yikes!</a><br /> <a href="3" rel="alert">NP</a><br /> <a href="4" rel="alert">Tae!</a> </div><br /> <br /> <a href="add" onclick="add(); return false;">Add</a>
  9. this http://www.gregphoto.net/sortable/ might be a help...
  10. this might help you http://www.gregphoto.net/sortable/ ...
  11. . let me start by giving an example code: <script> var t = function() { var obj = document.getElementById("menu"); alert(obj.value); } </script> <form name="form1"> <select name="menu" id="menu" onchange="t(this);"> <option value="Pizza">Pizza</option> <option value="French Fries">French Fries</option> <option value="Ham Burger">Ham Burger</option> </select> </form> ok now my question is, the function accessed the select by its id, is there a way that i can get the form name (<form name="form1">) where this select came from? somethine like: <script> var t = function() { var obj = document.getElementById("menu"); var formName = getForm(obj); // and the value of the formName will be form1... } </script> thanks in advance, hope i explained it correctly..
  12. i don't know whats wrong with my function, its working great in firefox and safari, but it does'nt in IE 6 and 7.. please help function addKey() { globalSmartKey = true; addS = document.getElementById("addS"); removeS = document.getElementById("removeS"); addS.style.display = "none"; removeS.style.display = "block"; var smartkey = document.getElementById("smartkey"); fields = ['Gender','DOB','Height','Weight']; var p = document.createElement("p"); p.setAttribute("id","pSmart"); p.innerHTML = '<br /><strong>Please fill in the information below to set up your SmartKey. It will be pre-programmed and waiting for you when you arrive at the club.</strong><br />'; p.innerHTML +='<br /><small style="font-size:10px;">This information is private. It is only used to pre-load your SmartKey so that it may provide you with accurate fitness information during and after your workout.</small><br />'; for(var t=0; t<fields.length; t++) { p.innerHTML += '<label for="fname">' + '<span id="err' + fields[t] +'" class="error"></span>' + '<span class="error">*</span>' + fields[t] +':' + '</label>' + '<input class="medium" id="' + fields[t] +'" name="' + fields[t] +'" type="text" value="" />'; } p.innerHTML += '<br /><br />'; smartkey.appendChild(p); }
  13. got question regarding this cron, can't explain it so i'll just going to give a sample. no got a script that resizes the images per folder. images may take 10 to hundreds. so for example the script is currently running to folder 10, and the script will be running again as i set it in the cron, what if the script is still running on folder 10 and it will try to work on folder 11, will that be an issue? everytime cron is running at a given time, is it just acting as like opening it into a new browser? so script works on folder 10 will not going to effect script that is running to folder 11?
  14. ooopss, did I say subquery?? I mean, never thought you can put IN statement on ORDER BY.. can you lead me to a tutorial that does this? been searchin for a tutorial but never found that does this..
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.