Jump to content

zohab

Members
  • Posts

    223
  • Joined

  • Last visited

Everything posted by zohab

  1. hi all, I want to remove non-empty directory from Linux. If i use [root@localhost]#rmdir directoryname then it gives me an error message as Failed to remove 'directoryname' :directory not empty any ideas?
  2. Ok alert(document.getElementById("outsideForm").value); working But if i have not id in the field then how to get value suppose if i have like this <input type="text" name="outsideForm" value="Outside Form"> here id="outsideForm" is missing. <!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> <script language="javascript" type="text/javascript"> function validate() { alert(document.formName.insideForm.value); //working //alert(document.outsideForm.value); //alert(document.getElementById("outsideForm").value); // working alert(document.getElementByName("outsideForm").value); alert(document.getElementByTag("outsideForm").value); } </script> <body onload="validate();"> <html> <form name="formName"> <input type="text" name="insideForm" id="insideForm" value="Inside Form"> </form> <input type="text" name="outsideForm" id="outsideForm" value="Outside Form"> </html> </body> </html>
  3. Hi all, I wrote simple stored procedure and it is not working and giving error, CREATE PROCEDURE simpleproc BEGIN select * from tablename END I got this example syntax from following url http://dev.mysql.com/doc/refman/5.1/en/create-procedure.html any idea what is going wrong?
  4. Hi all, I need one small example of stored procedure. I have gone through the documentation of mysql site. http://dev.mysql.com/doc/refman/5.0/en/faqs-stored-procs.html#qandaitem-22-4-1-1 I understand the theory concept. I am not able to find simple example like select* from tablename in stored procedure and function. Any URL where i will get example. Thanks in advance
  5. hi all, I have HTML form <html> <form name="formName"> <input type="text" name="insideForm" id="insideForm" value="Inside Form"> </form> <input type="text" name="outsideForm" id="outsideForm" value="Outside Form"> </html> To get form values in javascript i have to write like alert(document.formName.insideForm.value); =>Inside Form but to get "outsideForm" values ,what i should do? Following will not work. alert(document.outsideForm.value); =>not worked alert(document.getElementsById("outsideForm").value); =>not worked alert(document.getElementsByName("outsideForm").value); =>not worked alert(document.getElementsByTag("outsideForm").value); =>not worked Any Ideas? Thanks in Advance
  6. Hi all, I have an array as follow. Array ( [0] => orange [1] => banana [2] => apple [3] => raspberry ) I want to convert it to key value array. Array ( [orange] => banana [apple] => raspberry ) How can i implement it dynamically(using for loop or any other solution). Any idea?
  7. hi thorpe , I have 100 tables in my database and i want to replace 'xyz' to 'pqr' I am not able to do it for every table.For this i have to write 100 queries. i want to run one small query that will replace 'xyz' to 'pqr' in whole database (includes 100 tables)
  8. hi all, if i want to update table with new value i will do as update table set id='4' where id='3' this will replace id='3' to id='4' table id name 1 name1 2 name2 3 name3 but if i want to replace it in whole database ,how will i do it. table 1 id name 1 name1 2 name2 3 name3 table 2 id name 1 name1 2 name2 3 name3 table 3 id name 1 name1 2 name2 3 name3 any ideas?
  9. Hi peddel, I do not know the value of identical record
  10. hi all, I want to select identical records from table table id firstname lastname email 1 first last email 2 xyz pqr sss 3 first last email 4 mmm lll rrr 5 first last email in above table records 1,3 and 5 are identical I want to know select query to get record 1,3 and 5
  11. HI , When my site page get loaded they move to right side then come to center. any idea about this?
  12. hi I have created one text area but when i click on it it start typing from middle instead of start <table width="100%" border="1"> <tr> <td> </td> <td> </td> </tr> <tr> <td> </td> <td><textarea name="txtComments" rows="5" cols="100" style="font-family:tahoma;font-size:10px;" id="txtComments"> </textarea></td> </tr> </table> any ideas? [attachment deleted by admin]
  13. Hi all With the help of following command i am able to open link in new window. window.open("http://google.com", "Google"); I want to open link in new tab How can i implement it. any ideas?
  14. Hi all Can we upload file with the help of javascript thanks in advance
  15. Hi all I want to know how can we upload file with the help of ajax and php any example. thanks in advance
  16. Hi all, I have page with image i do not want user to take print screen or save image as or any other way user can save the image . how can i do it. any ideas? thanks in advance.
  17. Hi all, On my site i want count number of visitors visiting the site. How can i implement it using 1.Php or 2.Javascript. any ideas? regards zohaib.
  18. hi all i have created one check box and from a javascript function when i provide hard coded name for checkbox then it shows check but in case of dynamic value it does not show check checkbox in html [code]<input type="checkbox" name="checkbox2" id="checkbox2" value="checkbox"> var i=2; var check="checkbox"+i; document.frmCheck.checkbox2.checked=true; // working document.frmCheck.checkboxi.checked=true; // not working document.frmCheck.checkbox+i.checked=true; // not working document.frmCheck.check.checked=true; // not working any ideas? full code as below pls try it <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=shift_jis"> <title>Untitled Document</title> </head> <body> <form action="" method="post" name="frmCheck"><table width="100" border="1"> <tr> <td>Check1</td> <td><input type="checkbox" name="checkbox1" id="checkbox1" onClick="return test();"value="checkbox"> <input type="hidden" name="value1" id="value1" value="1"> </td> </tr> <tr> <td>Check2</td> <td><input type="checkbox" name="checkbox2" id="checkbox2" value="checkbox"> <input type="hidden" name="value2" id="value2" value="2"> </td> </tr> <tr> <td>Ckeck3</td> <td><input type="checkbox" name="checkbox3" id="checkbox3" value="checkbox"> <input type="hidden" name="value3" id="value3" value="3"> </td> </tr> <tr> <td>Check4</td> <td><input type="checkbox" name="checkbox4" id="checkbox4" value="checkbox"> <input type="hidden" name="value4" id="value4" value="4"> </td> </tr> <tr> <td>Field</td> <td><input type="text" name="textfield" id="textfield" value=""></td> </tr> </table> <script language="javascript" type="text/javascript"> function test() { var value=document.frmCheck.value1.value; var i=2; var check="checkbox"+i; document.frmCheck.checkbox2.checked=true; // working //document.frmCheck.checkboxi.checked=true; // not working //document.frmCheck.checkbox+i.checked=true; // not working //document.frmCheck.check.checked=true; // not working } test(); </script> </form> </body> </html> [/code]
  19. Hi all I have id column in my table id 1 2 3 4 5 6 7 8 9 10 Now i want to select 2end max record from table ,to do this i will do following select max(id) from table where id not in (select max(id) from table). but if i want to find 3 max or 5 max or 8 max record from table how can i do this? any ideas?
  20. hi all any one know the difference between <?php and <? example <?php echi "hi"; ?> and <? echo "hi"; ?>
  21. hi when u call ajax at that time disable the submit button till u get request from server with the help of ajax when ajax is working /processing the request submit button will be disabled as soon as ajax processing is over submit button will be active.
  22. hi rhodesa do u understand my question? Or i need to explain it in a different way. basically i want ajax return value in some php variable ,so that i can do some processing on the return value from ajax. example get.php <?php echo "hi"; ?> ajaxPage.php <?php /* suppose i get value from get.php from ajax in $test variable then i can check following condition. */ if($test=="hi") { echo"i get value from get.php"; } else { echo "i do not get value from get.php"; } ?> ?>
×
×
  • 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.