- Upvotes Received
- 3
- Posts with Upvotes
- 3
- Upvoting Members
- 3
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
Java Developer
35 Posted Topics
Re: [code=php] require "dbconn.php"; $id=$_POST['id']; $checkquery = "SELECT * FROM table WHERE id = '$id'"; $checkresults = mysql_query($checkquery); $row = mysql_fetch_row ($checkresults);require "dbconn.php"; $id=$_POST['id']; $checkquery = "SELECT * FROM table WHERE id = '$id'"; $checkresults = mysql_query($checkquery); if($checkresults && mysql_num_rows($checkresults)>0) { $row = mysql_fetch_row ($checkresults); } else { if(!$checkresults) echo "Error … | |
Re: [CODE=php] <?php require_once('login.php'); ?> <html> <head> <title>Home</title> </head> <body> <link rel="stylesheet" type="text/css" href="style.css"/> <?php require_once('appvars.php'); require_once('header.php'); $dbc = mysqli_connect(DB_HOST, DB_USER, DB_PASSWORD,DB_NAME) or die('Error connecting to the MySQL server'); $query = "SELECT * FROM products"; $result = mysqli_query($dbc, $query) or die('Error querying database.'); echo '<table BORDER = 1 Width=50% height=50% align="center">'; … | |
Hi, I am generating a string from AJAX data which contains forms and submit buttons. I then try to assign this string to a div using innerHTML. This works fine in IE but Firefox strips form tags and every thing in between form tags. How to solve this issue Example … | |
Re: Try adding "From:" in the headers field while sending email [CODE]$headers = "From: abc@xyz.com\r\nReply-To: efg@xyz.com"; $mail_sent = @mail( $to, $subject, $message, $headers );[/CODE] | |
Re: [CODE] $to = "user@puruinvestech"; $subject = "Enter subject here"; $body = $_POST['name'] ." ".$_POST["mobile"]; if(mail($to, $subject, $body)) { echo "mail send"; } else { echo "error sending email"; } [/CODE] | |
I started developing an HTML editor using Java. After spending a lot of time I am now stuck in between. Most of the things are done but now I don't find any way to implement some of very important features. [B]I think[/B] java is too weak too support these features. … | |
Re: just add following line [icode] display.setHorizontalAlignment(JTextField.RIGHT); [/icode] above the statement [icode]display.setEditable(false);[/icode] Thanks | |
Hi, How can I setup a simple paypal buy now button for suscribing paypal payment. i.e not making just one time payment but to suscribe the user for monthly payment? What variables I need to setup? How can I setup a transaction so that it becomes successfull only if postal … | |
Re: Hi, You have do develop you own logic for that. Their is no direct way. May be you can find some class on phpclasses.net which lets you easily create pagination but I do it without any class. I am pasting here a function from my code which includes pagination. You … | |
Hi, I want to print many post cards with the click of a buttons with contents and addresses comming from the database using PHP. Can anybody have some ideo how to do that. My concerns is how can I print a number of post cards with any user interaction. Thanks | |
Hi, I need database for implementing dropdowns for Countries than based on selected country the States/Proviences dropdown and then the cities dropdown on the bases of selected State/Provience for all the countries in the world. I hop you understand what I need to implement. Can any body please provide me … | |
Re: Let suppose you have 10 check boxes like this [code] <input type="checkbox" name="chk[]" value="anyvalue1"> <input type="checkbox" name="chk[]" value="anyvalue2"> <input type="checkbox" name="chk[]" value="anyvalue3"> ... <input type="checkbox" name="chk[]" value="anyvalue4"> [/code] You can use following PHP code to finc dout the number of selected check boxes [code] $allChecks = $_POST['chk']; $noOfChecked = count($allChecks); … | |
Re: I think you want to get the referer page. Use [icode]echo $_SERVER['HTTP_REFERER'][/icode] to print the referer page. | |
Hi, The following JQuery works fine in all browsers excluding ie-8. It works fine even in ie-7. Not tested in ie version gater than 8. It works fine in Firefox, Chrome and ie-7. Can any body figure out what is the problem and how to solve. [CODE] <script type="text/javascript"> $(document).ready(function() … | |
Re: You can use ready-made open source forums. Check phpBB [url]http://www.phpbb.com/[/url] . Their are many other too. | |
Re: Replace line no 11 with the following [code=php] $sql = "SELECT * FROM doctors WHERE Physician LIKE '".$Physician."%'"; [/code] The problem is you have defined Physician veriable with capital "P" and using lower case "p" in the query. Php veriables are case sensitive. | |
Re: In your code $page defines the page number, $start defines the row number of starting record which will be displayed on the page, $limit defines number of records per page [icode]$page=$_GET['page'];[/icode] is actualling fetching "page" veriable appended in the url. If you see the url you will see "page" appended … | |
| |
Re: [CODE=php] <?php //Connect to server $conn = mysql_connect ("localhost", "tatty27", "monkeyboy") or die ("Could not connect to database."); //connect to database mysql_select_db("tatty27_customers") or die ("Database does not exist."); ?> <!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>Database Exercise 2.2</title> <style type="text/css"> … | |
Re: Very simple, You can use the value attribute of the button tag. This will change the test on the button also. If this is not something you required, you will have to require another global array to store the values of buttons. [CODE] <html> <head> <title> Untitled</title> <style type="text/css"> button … | |
Re: Try this code. I have written but not tested it, hopefully it will work for you. [code=php] <?php $dir="poems/"; printContents($dir); if(isset($_REQUEST['f'])) { $fh = fopen($_REQUEST['g'],"r"); $theData = fread($fh,filesize($_REQUEST['f'])); fclose($fh); echo "<pre>$theData</pre>"; } function printContents($directory) { if($scan = scandir($directory)) { foreach ($scan as $value) { if (is_dir($value) && $value!="." && $value!="..") … | |
Re: try it now [code=php] <input type="image" src="ViewHotel.PNG" name="image" width="90" height="24" onClick="window.open('viewhotel.php?id='.$row['id'].''', 'mywindow', 'width=400, height=200')"/> [/code] | |
Re: Try this [code=php] // get the search variable from URL $var = @$_GET['q'] ; // trim whitespace from the stored variable $trimmed = trim($var); // separate key-phrases into keywords $trimmed_array = explode(" ",$trimmed); // build SQL Query for each keyword entered $query = "SELECT * FROM (articles LEFT JOIN authors … | |
I had a code written long time ago which was working fine for small records but as the number of records begin to increase it completely failed. I am attaching the file with comments which will help you understand the problem. For fewer records you can see it working at … | |
The scenerio is that I have different type of drawing components on drawing area. In menu I have some combo boxes which apply different properties on these objects. and also add a new UndoableEdit to the UndoManager. Anybody worked with the swing's undo package will get the idea. This way … | |
Re: Try this. message_box_name.setModel(true); | |
Re: for selecting and comparing fields from several tables use simlar query [code] mysql_query("SELECT * FROM table1,table2,table3 WHERE table1.column_name = table2.column_name AND table3.column_name='$usre_input'"); [/code] | |
Re: Try modifying createOutput method like shown below [code] public static String [] createOutput (File myFile) { //need to declare "array" Scanner scan = new Scanner(myFile); String [] myArray; try { myArray = new String[1000]; //instead of 1000 use some appropriate method to find out total number of integers in the … | |
Re: asuming that words is an array list or a vector, modify your method as follows [code] public int indexOf(EltType e) { int i=0; for (i = 0; i < words.size(); i++){ if(words.getElementAt(i)==e) return i; } return -1; } [/code] | |
Hi, I need already written code for a simple file and folder explorer in Java similar to Project Explorer in Net Beans IDE. Instead of writing it from scratch I hope I can find which is already written. It will be very good if it allows file/directory add, remove and … | |
Re: First of all you have to create a new Project. Right click on the package icon in the Project Explorer and select New -> JFrame Form. Click on Windows -> Pallete to enable Swing and UI components ready to drag/drop on the frame. | |
Re: The query string starts after the "?" sign. The first variable must follow the "?" sign which indicates the end of the url path and start of query string variables. Further variables are then seperated by "&" sign. So to access hPage value fro the url it must be like … | |
HI, I am having trouble installing Linux over Vista. I have tried Ubantu and Red Hat Linux 9. In red hat when it comes on partitioning phase it gives error message somthing like "No device found to alter partition table". I dont remember the exact message. I have four partitions … | |
Re: Their is not much difference but some servers provide ".inc" extension as standard for includes files, ".inc" files are parsed on server side on those server. Not every server software follows or requires special configuration. [QUOTE=sikka_varun;760822]Hi.. What initially it started was that inc was used to include the files in … | |
Re: What I understood is that `data` is the date field in your table. If it is so use following query [code=php]$result = mysql_query("SELECT id,title,description,data,author,mini_img,view FROM data WHERE DATEDIFF(data,'$data_begin')>0 AND DATEDIFF(data,'$data_end')<0",$db);[/code] |
The End.