Jump to content


  • Posts

  • Joined

  • Last visited

Everything posted by dowp213

  1. I wasn't too familiar with ajax but already worked on a numerous simple flash projects, I don't know if this thread is in a right category.. but I'll try my luck here..I got this simple ajax tab working for my html from dynamicdrive-ajaxtab.. and it works just fine, my TAB2 and TAB3 are loading the "external.html" to a div container "countrydivcontainer" and this short script below the div, (I don't know what's the purpose of this, but the ajax tab doesnt works well if this script below the DIV is missing).. and I embedded some external javascript inside the <head> tag.I want my tab button to be a .swf file. did some research and tried some examples but doesn't worked.. the page navigates to the external.html file instead of displaying the content inside the DIV container.. I think the solution is the actionscript for the flash button.. <script type="text/javascript" src="http://www.dynamicdrive.com/dynamicindex17/ajaxtabscontent/ajaxtabs/ajaxtabs.js"></script><ul id="countrytabs"> <li><a href="#" rel="#default"><h1>TAB1</h1></a> </li> <li><a href="external.html" rel="countrycontainer"><h1>TAB2</h1></a></li> <li><a href="external.html" rel="countrycontainer"><h1>TAB3</h1></a></li></ul><div id="countrydivcontainer"> DEFAULT CONTENT DEFAULT CONTENT</div><script type="text/javascript"> var countries=new ddajaxtabs("countrytabs", "countrydivcontainer") countries.setpersist(true) countries.setselectedClassTarget("link") //"link" or "linkparent" countries.init()</script>
  2. hi, Im new to flash, I'ved just created a button using adobe flash cs3 AS3.0 but every time I click the button it generated another tab instead of navigating inside its tab.. im so wasted solving this , done tons of sulotion but nothing ever worked. import flash.events.MouseEvent;var getsite1:URLRequest= new URLRequest("http://www.mylink.com");var getsite2:URLRequest= new URLRequest("http://www.mylink.com");var getsite3:URLRequest= new URLRequest("http://www.mylink.com");var getsite4:URLRequest= new URLRequest("http://www.mylink.com");var getsite5:URLRequest= new URLRequest("http://www.mylink.com");item.addEventListener(MouseEvent.CLICK, click1);function click1(event:MouseEvent) :void{ navigateToURL(getsite1);}gallery.addEventListener(MouseEvent.CLICK, click2);function click2(event:MouseEvent) :void{ navigateToURL(getsite2);}about.addEventListener(MouseEvent.CLICK, click3);function click3(event:MouseEvent) :void{ navigateToURL(getsite3);}contact.addEventListener(MouseEvent.CLICK, click4);function click4(event:MouseEvent) :void{ navigateToURL(getsite4);}locations.addEventListener(MouseEvent.CLICK, click5);function click5(event:MouseEvent) :void{ navigateToURL(getsite5);} this is my simple codes.. I hope someone reply with a simple answer..
  3. yeah..thanks a lot for the help..already got it on submission..hoping for a good grade..
  4. my plan is to input the value into a chronogical order,but you decided to put a delimeter between them.. the good thing is: a typical barcode (depending on the scanner) has a delimeter before and after the content, It's either "^" or numbers.i was about to complain about the list thing,. quickhands..thanks you very much..and to mr.deirdre's dad..
  5. here's the thread.. already have Deirdre's Dad up on my thread..
  6. the problem is not with the if..else.. but rather the whole structure of my codes.. but the reply helps really well..the reply really concluded something..I'm new at this,glad that there's always a forum and it's members to help..the admin can close this thread now..
  7. this certainly helps a lot.. i replace my input type with yours.. and paste the javacodes you have provided inside my <script>..and it works very well. but before your reply, I've been searching around the internet of possible function to use.. the "getElementbyId" you used, works at any point, but i've came across some codes which has a 2 textbox and a single button and when you input a value inside the first textbox and click the button, it automatically displays the exact value at the second textbox.. I rewrite the codes and manage it to:*get the input value of the 1st textbox.*undergo an if..else function.*display the if..else statement at the 2nd textbox..and my problem is:how to input multiple value at the 1st textbox and display the output statement at the 2nd textbox as a "list", the output should be listed one after another..here's my unfinished work,this can only process a single input and output..... this is a little confusing cuz im just using a notepad, sorry for that sir..<html><head><title>Barcode Reader</title><script Language="JavaScript">function Getbarcode(){var barcode, display;barcode = document.barcodeform.txtbarcode.value; if (barcode == 001) { // my if.. else functionbarcode="soap"; // my statement is,a change of value to the variable}else if (barcode == 002) {barcode="toothpaste"; }else if (barcode == 003) {barcode="chips";}else if (barcode == 004) {barcode="juice";}else if (barcode == 005) {barcode="waffles";}else {barcode="error";}display = barcode;document.barcodeform.txtdisplay.value = display;}</Script></head><body><h2 font face="Georgia, Garamond, Times New Roman" color="#FF0000">Barcode Reader</h2><form name="barcodeform"><table border="0" cellpadding="0" cellspacing="0"><tr><td width="100">Barcode:</td><td><input type="text" name="txtbarcode" size="14"></td> <// 1st textbox></tr><tr><td width="100"><br><br></td><td><input type="button" value="Submit Barcode" onClick="Getbarcode()"></td> <//button></tr><tr><td width="100">Purchase:</td></tr></table><table border="2" cellpadding="0" cellspacing="0"> <tr><td height="100"><input type="text" name="txtdisplay" size="20"><br> </td> <//2nd textbox></tr> </table></form></body></html> and by the way, this code uses the "form" you have mentioned earlier at your reply, don't know much about it..will this be an advantage or not?..
  8. i already started a little bit.. i already got a text box and text button,.. didn't have an idea what event handler is so i googled it.. it's like executing the java codes inside of a html, it's outside the "<script>".. am i right?.. I use "<form>" for the html to initiate the java inside its code..<html> <head> <script type="text/javascript"> </script> </head> <body> <form action=""><a href></a> <fieldset> <label><b><font color="000000">Enter Value: </label> <input type="text"> </fieldset> <BR><input type="submit" value="Submit Value"> </form> </body></html> the only problem is the javascript code.. I started a little javascript but discarded it after, because it's not working..already created a thread about the if..else function.. but perhaps i need a wider approach.. maybe it's not about the javacript but rather the whole structure of the application..
  9. hi,Im not to good at javacsript and html..but i know a little bit, need some help,in a html page I place one textbox, and when I enter a data at the textbox and click submit button the data will undergo an if..else operation (I don't know what proper operation is needed) which corresponds to a string, and the string will be displayed underneath the textbox..and i have to display the previous strings.. one after another..for example I entered the value "001" which is equivalent to a "toothpaste" with a price of $1, when i click submit button it will display the toothpaste below..and the same with the soap.. each time i enter a value that corresponds a string, the string will be displayed at the top of the first one.. i think I need a table for the Price and for the string..I need the most simple codes as possible..
  10. how to assign a string to a variable in a if..else?for example:if (condition){(var output="dog")}so that the variable "output" would be displayed after....
  11. NOW THIS IS WHAT I CALL LEARNING!..THANK YOU VERY MUCH SIR.. I can easily learn if there is a reference code..instead of countless hours searching over the internet with no clue where I'm heading..And again Sir thank you for the codes, but I will not use it completely.. I will remove the CSS part.. cuz we are concentrating on javascript.. and for some infos.. I'm not really good at javascript, but as they say learning is a painful process..and YES, I really learn something here..thanks for the help guys..
  12. I'm very sorry SIR.. I really cannot deal with this.. but thanks a lot..
  13. ok.. would I still use the max() function?..
  14. this is difficult Sir, do you mind making me a 5 input while loop or just 3 and I'll handle the rest, I'm having difficulties at making codes with no reference.. :)the references i found on the internet doesn't help much at all.. and i don't know how to use array yet.. am very sorry.. T_Tbtw thanks for the rep
  15. the whole SET of odd sequence should be returned. is this possible Sir?..
  16. the next thing to do Sir, is to display the highest number as odd sequence.. for example if I input: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 the highest is obviously 10.. (in which I used max() to find the highest)so the output should look like this:13579i guess.. if this is an odd sequence.. from your understanding, what is an odd sequence Sir?..and is this possible in javascript?..
  17. thanks for the reply btw.. yeah you are right, this is a school project.. and this topic wasn't discussed to me at all.. so feel free to help me with all you can.. i guess this would be a very hard project.. odd sequencing seems to be my only problem..how can i use "if..else" function to my highest number if i used math.max() to determine the highest among 10 numbers?..is there any other functions i can use to find the highest number among 10 inputs?.. or i can use math.max() in "if..else" function?..this is my unfinished code:var a=prompt("Enter a number1:","");var b=prompt("Enter a number2:","");var c=prompt("Enter a number3:","");var d=prompt("Enter a number4:","");var e=prompt("Enter a number5:","");var f=prompt("Enter a number6:","");var g=prompt("Enter a number7:","");var h=prompt("Enter a number8:","");var i=prompt("Enter a number9:","");var j=prompt("Enter a number10:","");document.write("The highest number is:");document.write(Math.max(a,b,c,d,e,f,g,h,i,j));as you can see.. i already found out how to find the highest.. thanks for the reply, and still hoping for more..
  18. use this "show_alert("test")" instead of your old ones.. iguess this will help..
  19. let's say that 'var' give number or string value to whatever you assign them to..
  20. this is the problem: input 10 numbers and display the highest number in odd sequence.. does anyone have an idea?.. i already found a way to find the highest among 10 input numbers using math.max() function but I'm having some problem in sequencing them as odd..
  • Create New...