Jump to content

techker

Members
  • Posts

    812
  • Joined

  • Last visited

Everything posted by techker

  1. hey guys i made a script for my boddy and it is only used on on PC now i have multiple little scripts to run and i don't want to make a login on each..is it possible to allow access only with his ip?
  2. well it goes to a check page and it echo's the user's name and and appointment date and if there is a note in his file it shows an icon.
  3. all the scripts i find is for triggering sound thru a button not with an event?and i would need to mix it with php? like select * from table WHERE member_id=$id if date ==today alert sound....
  4. know anything about this? http://www.schillmania.com/projects/soundmanager2b1/#requirements
  5. so i will check for javascript thx
  6. its one machine made for the scanner only.so your saying i cant use any html or serverside for this?
  7. in php but since it has something to do with mysql since im getting the info.?sorry if not.
  8. hey guys im doing a script for when a member scans his card(barcode0it gets his info in a databse .now it's a membership information, is it possible that if the membership is expired it sound an alarm ?
  9. so i fanaly found one that maybe has potential!lol xml and ajax. it works good but if i add another on the page and changed the get page to fincity2 and the divtag to city2 the both work but when i select the second one it changes the first one. i will barke down the code: the xml <script> function getXMLHTTP() { //fuction to return the xml http object var xmlhttp=false; try{ xmlhttp=new XMLHttpRequest(); } catch(e) { try{ xmlhttp= new ActiveXObject("Microsoft.XMLHTTP"); } catch(e){ try{ xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch(e1){ xmlhttp=false; } } } return xmlhttp; } function getCity(strURL) { var req = getXMLHTTP(); if (req) { req.onreadystatechange = function() { if (req.readyState == 4) { // only if "OK" if (req.status == 200) { document.getElementById('citydiv').innerHTML=req.responseText; ( } else { alert("There was a problem while using XMLHTTP:\n" + req.statusText); } } } req.open("GET", strURL, true); req.send(null); } } </script> [code] and the form [code=php:0] <form method="post" action="" name="form1"> <table width="60%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="150">Country</td> <td width="150"><select name="country" onChange="getCity('findcity.php?country='+this.value)"> <option value="">Select Country</option> <option value="ABS">ABS</option> <option value="ARMS">ARMS</option> <option value="LEGS">LEGS</option> <option value="SHOULDERS">SHOULDERS</option> <option value="CHEST">CHEST</option> </select></td> </tr> <tr style=""> <td>City</td> <td ><div id="citydiv"><select name="city"> <option>Select City</option> </select></div></td> and the reference page for the query is <? $country=$_REQUEST['country']; $link = mysql_connect('localhost', 'openshar_techker', 'techker'); //changet the configuration in required if (!$link) { die('Could not connect: ' . mysql_error()); } mysql_select_db('openshar_trainerstool'); $query="select * from $country "; $result=mysql_query($query); ?> <select name="city"> <option>Select City</option> <? while($row=mysql_fetch_array($result)) { ?> <option value><?=$row['pic']?></option> <? } ?> </select> [/php
  10. i need server side to in order to get the info from my database?
  11. but you see i ahve googled just about everything i can think of.what do i look for is the question?
  12. hey guys is tehre a way to put a select box on a page that when you select the lets say categorie it refreshe's the form to get the info(mysql) in that category? i have tryed lots of was some worked but when i trye to put more then one on a page it refreshe's the first and second box.. i have tryed googling javascript event handler onchange. but i cant find a page that shows a for with a select box refresh...
  13. techker

    select box

    it refreshs tonly the fisrt box not the second one .. check http://webworkout.info/sel3.php
  14. techker

    select box

    my error is solved with the second script i posted.now the question was can i put it multiple times on one page?
  15. techker

    select box

    SELECT DISTINCT pic,id FROM $cat
  16. techker

    select box

    ah sorry wrong box..lol here is the code for the new probleme.i got the dselect part working but now i need to add more of the same on a same page ..but it refresh's the hole page so all the boxes reset.i have tryed changing all to select2,querry2..check it out to see.. <? require "config2.php"; $connection = mysql_connect($dbhost, $dbusername, $dbpass); $SelectedDB = mysql_select_db($dbname); $cat=$_GET['cat']; ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled Document</title> <SCRIPT language=JavaScript> function reload(form) { var val=form.cat.options[form.cat.options.selectedIndex].value; self.location='sel2.php?cat=' + val ; } </script> </head> <body> <form id="cat" name="cat" method="post" action=""> <label> <select onchange="reload(this.form)" name="cat" id="cat"> <option value="selected"><? print"$cat" ?></option> <option value="ABS">ABS</option> <option value="ARMS">ARMS</option> <option value="LEGS">LEGS</option> <option value="SHOULDERS">SHOULDERS</option> <option value="CHEST">CHEST</option> </select> </label> </form> <p> <? if(isset($cat) and strlen($cat) > 0){ $quer=mysql_query("SELECT DISTINCT pic,id FROM $cat" ); }else{$quer=mysql_query("SELECT DISTINCT pic,id FROM $cat "); } echo "<select name='subcat'onChange='swapImage()' ><option value=''>Select one</option>"; while($noticia = mysql_fetch_array($quer)) { if($noticia['pic']==@$cat3){echo "<option selected value='$noticia[pic]'>$noticia[pic]</option>"."<BR>";} else{echo "<option value=/Account/PICS/$cat/$noticia[pic]>$noticia[pic]</option>";} } echo "</select>";?> </p> <p> </p> <table width="442" height="138" border="0" cellpadding="0" cellspacing="0"> <tr> <th scope="row"><form id="cat2" name="cat2" method="post" action=""> <label> <select onchange="reload(this.form)" name="cat2" id="cat2"> <option value="selected"><? print"$cat2" ?></option> <option value="ABS">ABS</option> <option value="ARMS">ARMS</option> <option value="LEGS">LEGS</option> <option value="SHOULDERS">SHOULDERS</option> <option value="CHEST">CHEST</option> </select> </label> </form> <p> <? if(isset($cat2) and strlen($cat2) > 0){ $quer2=mysql_query("SELECT DISTINCT pic,id FROM $cat2" ); }else{$quer2=mysql_query("SELECT DISTINCT pic,id FROM $cat2 "); } echo "<select name='subcat1'onChange='swapImage()' ><option value=''>Select one</option>"; while($noticia2 = mysql_fetch_array($quer2)) { if($noticia2['pic']==@$cat3){echo "<option selected value='$noticia2[pic]'>$noticia2[pic]</option>"."<BR>";} else{echo "<option value=/Account/PICS/$cat2/$noticia2[pic]>$noticia2[pic]</option>";} } echo "</select>";?></th> </tr> </table> <p> </p> </body> </html> http://webworkout.info/sel2.php
  17. techker

    select box

    ok so this is the box alone http://webworkout.info/sel.php
  18. nice thx. is there a way i can copy and past this form mulitiple times on one page?cause when i do so it refresh's all the select boxes..
  19. techker

    select box

    What do you mean?
  20. hey guys i got some part of my list boxes good but it does not stay on the selected choise? it refreshe's the page but it does not stay on the selected choice>? <? require "config2.php"; $connection = mysql_connect($dbhost, $dbusername, $dbpass); $SelectedDB = mysql_select_db($dbname); $cat=$_GET['cat']; ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled Document</title> <SCRIPT language=JavaScript> function reload(form) { var val=form.cat.options[form.cat.options.selectedIndex].value; self.location='sel.php?cat=' + val ; } </script> </head> <body> <form id="cat" name="cat" method="post" action=""> <label> <select onchange="reload(this.form)" name="cat" id="cat"> <option value="ABS">ABS</option> <option value="ARMS">ARMS</option> <option value="LEGS">LEGS</option> <option value="SHOULDERS">SHOULDERS</option> <option value="CHEST">CHEST</option> </select> </label> </form> </body> </html>
  21. techker

    select box

    hey guys i was wondering on how i can get info from my database from a select box. like i tryed this with no luck: <? require "config2.php"; $connection = mysql_connect($dbhost, $dbusername, $dbpass); $SelectedDB = mysql_select_db($dbname); $cat=$_GET['cat']; $QQQ1 = mysql_query(" SELECT id, pic FROM $cat "); if(!$QQQ1) die(mysql_error()); $err = mysql_num_rows($QQQ1); if($err == 0) die("No matches met your criteria."); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled Document</title> </head> <body> <form id="form1" name="form1" method="post" action=""> <label> <select onchange="reload(this.form)" name="cat" id="cat"> <option value="ABS">ABS</option> <option value="ARMS">ARMS</option> </select> </label> </form> <? while ($line = mysql_fetch_array($QQQ1)) { echo "<option value=\"$line[id]\">$line[pic] </option>"; }?> </body> </html> You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 im shure it's because it is executing the query before i chose the categorie?
  22. this is what i tryed up to now. <? $query = "SELECT * FROM clients_graph"; $result = mysql_query($query)or die(mysql_error()); print "<SELECT name=\"client\">"; while ($line = mysql_fetch_array($result)) { echo "<option value=\"$line[id]\">$line[2]</option>"; } //print "</select>"; echo "<img src='/Account/PICS/". $line['2'] ."' border='0' hight=120/>"; print "</select>"; ?>
  23. hey guys i have a databse withe images in it(just the path to the image folder) i want to make a list menu but instead of the pic name i want the image to show instead?is that possible??? or when you select the name the image apears?that would be better.thx
  24. hmm javascript .i will check it out
  25. hey guys i have a script that generates a page with pics on demand. now it has a grid (that i did ) as background and over it shows litle pics in the squares. now it works great but when i try to print it only shows the small pics not the background??
×
×
  • 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.