[PHP-DB] Re: سلام دوست من

2015-06-23 Thread Jim Giner
On 6/2/2015 2:17 PM, Mahsa Ehsani wrote: زمان ثمردهي‌اش گذشته بود و دوره بازنشستگي را طي مي‌كرد. روزگاري طراوت و سرسبزي داشت و كودك و بزرگ از قِبَلِ او مرزوق بودند. اما اكنون تمام دلخوشي‌اش اين بود كه پيامبر اعظم ـ صلي­الله­عليه­و­آله ـ چون به ايراد سخن مي‌ايستاد بر او تكيه مي‌كرد و اين براي ا

[PHP-DB] Re: Input Mathematical symbol in HTML textbox

2015-05-07 Thread Jim Giner
Use the tag? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-DB] Re: PHP 7 and sqlsrv

2015-04-10 Thread Jim Giner
On 4/10/2015 4:03 PM, John Hermsen wrote: I was wondering if there is anyone who manager to compile the sqlsrv driver for php 7. I have tried, but I haven't been able to get it compiled yet. Thanks, John php 7?? I didn't even see php 6 go past me! -- PHP Database Mailing List (http://www.php.

Re: [PHP-DB] Waiting for localhost

2015-03-16 Thread Jim Giner
On 3/16/2015 12:02 AM, Ethan Rosenberg wrote: I have this in the program -- echo ""; echo ""; echo ""; I'm testing from a form, which previously worked perfectly - TIA Ethan How does your script properly (note: 'properly') recognize that the user clicked on the 'Weigh' button? You don'

[PHP-DB] Re: Error fetching a second row from a result set (mysql)

2014-11-14 Thread Jim Giner
On 11/14/2014 1:46 PM, Mark Murphy wrote: Problem is that for the resource, the type is changed to Unknown by a different mysql_query within the loop. Any idea what will cause this? Maybe show us the whole code so we can see what you are telling us? -- PHP Database Mailing List (http://www.ph

[PHP-DB] Re: Writing Problems

2014-08-27 Thread Jim Giner
On 8/26/2014 8:44 PM, Ethan Rosenberg wrote: ini_set('display_startup_errors', 'on'); error_reporting(E_ALL | E_NOTICE); ini_set('display_errors','1'); error_reporting(1); No errors. What is wrong?? What is wrong here is your error reporting code. This is NOT what I gave you two months ago.

Re: [PHP-DB] Re: www-data file

2014-08-26 Thread Jim Giner
On 8/26/2014 11:26 AM, Matt Pelmear wrote: fopen() can create files if they don't exist. I should have read the manual b4 replying. :( -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-DB] Re: www-data file

2014-08-26 Thread Jim Giner
On 8/26/2014 12:20 AM, Ethan Rosenberg wrote: Dear list - When I use fopen, the file owner and group are both www-data. How can I ensure that the owner and group will be ethan? TIA Ethan Why should ownership be a concern when you are simply opening a file? AFAIK permissions are set at th

Re: [PHP-DB] Query does not work

2014-07-02 Thread Jim Giner
Once again you have provided the group with RANDOM pieces of code, completely out of context since you have already shown me that your query and db connection are being used in a function, hence your loss of $cxn. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http:/

[PHP-DB] Re: Query does not work

2014-07-01 Thread Jim Giner
Ethan - is error checking turned on as I showed you how to do EXACTLY last time you posted -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DB] Re: Query does not work

2014-07-01 Thread Jim Giner
On 7/1/2014 10:26 AM, Aziz Saleh wrote: On Tue, Jul 1, 2014 at 10:02 AM, Jim Giner wrote: How about just showing us the section of code instead of disjoint pieces that WE cannot be sure are applied correctly? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http

[PHP-DB] Re: Query does not work

2014-07-01 Thread Jim Giner
How about just showing us the section of code instead of disjoint pieces that WE cannot be sure are applied correctly? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DB] Re: What is my Mistake?

2014-06-24 Thread Jim Giner
Looking at your code again, I think that your query failed and your lack of error reporting isn't showing the error that occurred when you tried to access a property of the result which is not a resource but merely a value of 'false'. One should ALWAYS check the result of operations before as

Re: [PHP-DB] Re: What is my Mistake?

2014-06-24 Thread Jim Giner
I don't recognize your error reporting configuration. Try this instead: error_reporting(E_ALL | E_NOTICE); ini_set('display_errors','1'); As for php startup errors, if you are not running your own installation, you don't need that. So - if 'here3' is never echoed, then your code does NOT st

[PHP-DB] Re: What is my Mistake?

2014-06-24 Thread Jim Giner
Ethan - You say your script stops here : echo 'here3'; To be sure, you mean that the script DOES echo out 'here3' or does NOT get there? I'm going to guess that it does get to that echo statement but the very next one is going to kill you because you cannot echo out a resource. ONCE AGAIN

Re: [PHP-DB] Newbie Question $2

2014-06-18 Thread Jim Giner
On 6/18/2014 2:16 PM, Aziz Saleh wrote: On Wed, Jun 18, 2014 at 2:13 PM, Karl DeSaulniers wrote: Sent from losPhone On Jun 18, 2014, at 7:56 AM, Jim Giner wrote: On 6/18/2014 12:31 AM, Ethan Rosenberg, PhD wrote: On 06/17/2014 12:02 PM, onatawah...@yahoo.ca wrote: Hi Ethan, Here

Re: [PHP-DB] Newbie Question $2

2014-06-18 Thread Jim Giner
On 6/18/2014 12:31 AM, Ethan Rosenberg, PhD wrote: On 06/17/2014 12:02 PM, onatawah...@yahoo.ca wrote: Hi Ethan, Here are some things to clean up your code: Your line: $phn = $_POST[phone]; should use quotations as follows: $phn = $_POST['phone']; Your line: $sql1 ='select Lname, Fname fr

Re: [PHP-DB] Re: Newbie Question $2

2014-06-17 Thread Jim Giner
On 6/17/2014 10:51 AM, Lester Caine wrote: On 17/06/14 15:04, Jim Giner wrote: We're all so eager to help out poor Ethan (who many of you know is NOT a newbie) but nowhere does Ethan say what difficulty he is having. The suggestions made so far are great but what are we solving? I se

[PHP-DB] Re: Newbie Question $2

2014-06-17 Thread Jim Giner
Finally figured out what the question was! Here's a better version of your code Ethan: $phn = $_POST['phone']; // note the quotes on the index if (strlen($phn) <> 10) { echo "Error in phone number entry - must be 10 digits"; exit(); } $phn = mysqli_real_escape_string($cxn,$phn);

[PHP-DB] Re: Newbie Question $2

2014-06-17 Thread Jim Giner
We're all so eager to help out poor Ethan (who many of you know is NOT a newbie) but nowhere does Ethan say what difficulty he is having. The suggestions made so far are great but what are we solving? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/u

[PHP-DB] Re: What Does God Look For In Our Heart?

2014-06-05 Thread Jim Giner
Really? Do we go around proselytizing about our particular concerns , broadcast them to you when you are doing something completely unrelated? Do you have no sense of propriety? How about the maxim of keeping your religion to yourself and let others keep theirs? Religious zealots (as appare

[PHP-DB] PDO Connection problem

2014-01-10 Thread Jim Giner
History: I'm trying to help a friend who is hosting his domain with the same company that I use. I've been using this company for several years and have used a certain 'connection' script all the time. Part of it looks like this: $host="mysql:host=mydomain.com;dbname=$sc_dbname;charset=utf8

[PHP-DB] Re: joints - extracting common results from comparing 2 tables

2013-10-23 Thread Jim Giner
On 10/23/2013 8:15 AM, Taco Mathijs Hillenaar-Meerveld wrote: Good afternoon, i haven't done much with php and Mysql the past 2 years so my knowledge is not really up-to-date. i'm not a hero when it comes to math. actually, it's a weakness but trying to fix that. i made a query where i compare

Re: [PHP-DB] Subject Matter

2013-08-23 Thread Jim Giner
On 8/23/2013 4:52 AM, Matt Pelmear wrote: On 08/23/2013 04:36 PM, Lester Caine wrote: Matt Pelmear wrote: I am not sure who runs the list, whether they care about off-topic posts, or whether anyone else cares about it. The php lists are only loosely moderated, but comments like yours usually

Re: [PHP-DB] Re: mysql query

2013-08-23 Thread Jim Giner
On 8/23/2013 4:32 AM, Lester Caine wrote: Karl DeSaulniers wrote: If your on a PC I would just get Eclipse. But if you have netbeans, you can set the syntax highlighting for the different scripts you write in the preferences. PHP, java, javascript, etc... But the problem tha5 has been identifi

Re: [PHP-DB] Re: mysql query

2013-08-23 Thread Jim Giner
On 8/22/2013 8:08 PM, Ethan Rosenberg wrote: Ethan Rosenberg, PhD /Pres/CEO/ *Hygeia Biomedical Research, Inc* 2 Cameo Ridge Road Monsey, NY 10952 T: 845 352-3908 F: 845 352-7566 erosenb...@hygeiabiomedical.com On 08/22/2013 06:56 PM, Jim Giner wrote: On 8/22/2013 4:14 PM, Ethan Rosenberg

Re: [PHP-DB] Re: mysql query

2013-08-22 Thread Jim Giner
On 8/22/2013 4:14 PM, Ethan Rosenberg wrote: On 08/22/2013 11:54 AM, Jim Giner wrote: On 8/22/2013 9:52 AM, Jim Giner wrote: On 8/21/2013 7:48 PM, Ethan Rosenberg wrote: Dear List - I can't figure this out mysql> describe I

[PHP-DB] Re: mysql query

2013-08-22 Thread Jim Giner
On 8/22/2013 9:52 AM, Jim Giner wrote: On 8/21/2013 7:48 PM, Ethan Rosenberg wrote: Dear List - I can't figure this out mysql> describe Inventory; +-+-+--+-+-+---+ | Field | Type| Null | Key | Default

[PHP-DB] Re: mysql query

2013-08-22 Thread Jim Giner
On 8/21/2013 7:48 PM, Ethan Rosenberg wrote: Dear List - I can't figure this out mysql> describe Inventory; +-+-+--+-+-+---+ | Field | Type| Null | Key | Default | Extra | +-+-+--+-+-+---+

[PHP-DB] Re: mysql query

2013-08-22 Thread Jim Giner
On 8/21/2013 7:48 PM, Ethan Rosenberg wrote: Dear List - I can't figure this out mysql> describe Inventory; +-+-+--+-+-+---+ | Field | Type| Null | Key | Default | Extra | +-+-+--+-+-+---+

[PHP-DB] Re: One query, different tables?

2013-08-09 Thread Jim Giner
On 8/9/2013 10:56 AM, Karl-Arne Gjersøyen wrote: Hello. I am newbie in this and need som basic help. I have a form witch checkbox'es with different serialnumbers. The serialnumbers reflect different products and every product category have their own tables. I can transfer items from store to tr

[PHP-DB] Re: Mysql PDO statement with params in HAVING problem

2013-06-27 Thread Jim Giner
On 6/27/2013 7:51 AM, Alexander Pletnev wrote: Hi everyone, im new here, so please correct me if i created or formated topic incorrectly. I found a problem. I have a simple query for my needs: $stmt = $dbh->prepare("SELECT concat(first_name,' ',last_name) as full_name,t.* FROM `specia

Re: [PHP-DB] Re: Problem with query

2013-06-25 Thread Jim Giner
On 6/25/2013 2:32 AM, OJFR wrote: Yeah, Jim, please explain what u mean by "Per the manual, associative arrays using string indices should always use ' ' around them. They work (as mentioned in the manual) but are wrong". As long as I remember I could use associative ar

Re: [PHP-DB] Re: Problem with query

2013-06-25 Thread Jim Giner
On 6/25/2013 6:06 AM, Toby Hart Dyke wrote: What Jim means is here in the manual: http://www.php.net/manual/en/language.types.array.php#language.types.array.donts In a nutshell: Always use quotes around a string literal array index. For example, /$foo['bar']/ is correct, while

[PHP-DB] Re: Problem with query

2013-06-23 Thread Jim Giner
On 6/23/2013 2:31 PM, Ethan Rosenberg, PhD wrote: Dear List - There is an error in my query, and I cannot find it. This fails: $_SESSION['Cust_Num'] = $_REQUEST['cnum']; $_SESSION['CustNum'] = $_REQUEST['cnum']; echo "session"; //this has the proper values print_r($_SESSION); $sql10 = "selec

Re: [PHP-DB] Sorting a PHP array

2013-05-16 Thread Jim Giner
On 5/15/2013 1:38 PM, Bastien wrote: Bastien Koert On 2013-05-15, at 12:32 PM, "Charlie Lewis" wrote: I have a bookseller database list read into a PHP array with dimensions [row][field]. There are 32 fields in each record/row and up to 500 records. What is the neatest way to sort the ar

[PHP-DB] Re: Sorting a PHP array

2013-05-15 Thread Jim Giner
On 5/15/2013 12:32 PM, Charlie Lewis wrote: I have a bookseller database list read into a PHP array with dimensions [row][field]. There are 32 fields in each record/row and up to 500 records. What is the neatest way to sort the array by any of the fields, such as author or title? I know I s

Re: [PHP-DB] Placing a form on a page

2013-05-06 Thread Jim Giner
Centering a form is a simple process - as you stated about your first example form. So - obviously the problem is in all that other crap you presented to us, expecting us to do your debugging. I still don't know what you want to do - perhaps you could have given us a para on what it is wrong.

Re: [PHP-DB] PDO Exceptions

2013-04-25 Thread Jim Giner
On 4/25/2013 6:49 AM, Niel Archer wrote: Greetings, I am new to this list. I have a question about which functions need to be included in a try block. Of "new PDO", "prepare", "bindParam", "execute", "fetch", and "query", it seems that bindParam is the only one that throws an exception. So is

Re: [PHP-DB] Re: PDO Exceptions

2013-04-24 Thread Jim Giner
le a failure of those functions. Of course, if I'm wrong, I'm positive we'll start seeing responses to your question. :) -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php Hi Jim, I agree that failures would normally be catched

Re: [PHP-DB] Re: PDO Exceptions

2013-04-24 Thread Jim Giner
rse, if I'm wrong, I'm positive we'll start seeing responses to your question. :) -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php Hi Jim, I agree that failures would normally be catched as an exception. But how do/can you determi

[PHP-DB] Re: PDO Exceptions

2013-04-24 Thread Jim Giner
On 4/22/2013 11:55 AM, Onatawahtaw wrote: Greetings, I am new to this list. I have a question about which functions need to be included in a try block. Of "new PDO", "prepare", "bindParam", "execute", "fetch", and "query", it seems that bindParam is the only one that throws an exception. So i

[PHP-DB] Re: Undefined variables in update query

2013-03-26 Thread Jim Giner
On 3/26/2013 11:19 AM, VanderHart, Robert wrote: Hi, I'm pretty new to PHP and to this discussion list. I have a web form to update some fields in a data table. I'm getting "undefined variable" notices in my error logs when I submit the form and the table row doesn't get updated. Here's the

Re: [PHP-DB] Saving Image in mySQL

2013-03-20 Thread Jim Giner
On 3/20/2013 8:43 AM, Toby Hart Dyke wrote: You're right - you're pulling $file out of thin air. Once uploaded, the file is stored in $_FILES['file']['tmp_name'], and you need to manually read the data into $file yourself. Something like: file_get_contents($_FILES['file']['tmp_name']) To

Re: [PHP-DB] Saving Image in mySQL

2013-03-20 Thread Jim Giner
Absolutely - do not store any images in a db. Makes no sense. The data (the image) is static, basically safe from alteration or changing in any way, so what is the need? Save the location/name of the image only and store all of them in one (or more) secured folders on the server. No db over

Re: [PHP-DB] My Comments

2013-02-22 Thread Jim Giner
re attempting to work with now. Why do you keep pointing it out? Many of us (older folks) here probably wrote Fortran at some point in our careers - do you think any of us remember the first thing about it? Or use anything gleaned from it in today's world? Sincerely, seriously, and k

Re: [PHP-DB] Ajax

2013-02-21 Thread Jim Giner
On 2/21/2013 2:34 AM, Karl DeSaulniers wrote: Hi Ethan, With all due respect, I really wish I could help, but your structure of how your doing your html and php and javascript mix doesn't make sense enough for me to understand what it is your doing or how to help you. I copied and pasted your ori

Re: [PHP-DB] Re: AJAX/Javascript??

2013-02-11 Thread Jim Giner
On 2/11/2013 10:08 AM, Michael Oki wrote: Create a form and add a submit button that will run a php file. The SQL query in the php file will have something like "SELECT custName FROM table WHERE lname='$lname'; This will come after you have retrieved the data from a form like this $lname = $_POST

[PHP-DB] Re: AJAX/Javascript??

2013-02-10 Thread Jim Giner
On 2/9/2013 10:51 PM, Ethan Rosenberg, PhD wrote: I know that this might be an Ajax/Javascript question. Hopefully you can help. I do not know of any other source for good info. I would like to be able to click on one field in a table, and retrieve the data in another field. Here is the infor

[PHP-DB] Re: Processing Account Login

2013-02-07 Thread Jim Giner
On 2/6/2013 8:01 PM, Ron Piggott wrote: Hi Everyone When I login to PayPal a total of 3 web pages are used: 1 – A screen for the user to type in their user name & password 2 – A screen saying “ Logging in “* 3 – My Welcome / Personalized Account Summary Screen * During the 2nd web page my PHP

Re: [PHP-DB] pdo ?

2013-01-25 Thread Jim Giner
On 1/25/2013 10:56 AM, Jim Giner wrote: On 1/24/2013 7:07 PM, Matt Pelmear wrote: On 01/24/2013 04:02 PM, Jim Giner wrote: I took my 6 line override php.ini file and replicated (with a script) into all of my possible folders under my web root. NOt exactly an elegant solution, but with the

Re: [PHP-DB] pdo ?

2013-01-25 Thread Jim Giner
On 1/24/2013 7:07 PM, Matt Pelmear wrote: On 01/24/2013 04:02 PM, Jim Giner wrote: I took my 6 line override php.ini file and replicated (with a script) into all of my possible folders under my web root. NOt exactly an elegant solution, but with the script, easy to maintain. Honestly, you

Re: [PHP-DB] pdo ?

2013-01-24 Thread Jim Giner
On 1/24/2013 6:09 PM, Matt Pelmear wrote: On 01/24/2013 01:34 PM, Jim Giner wrote: If you are using another web server or running PHP as FastCGI you may need to consider other options (changing the setting globally or doing a require_once() of your config changes?, or see the FastCGI example

Re: [PHP-DB] pdo ?

2013-01-24 Thread Jim Giner
On 1/24/2013 6:03 PM, Matt Pelmear wrote: On 01/24/2013 01:37 PM, Karl DeSaulniers wrote: On Jan 24, 2013, at 2:15 PM, Matt Pelmear wrote: On 01/24/2013 12:00 PM, Jim Giner wrote: On 1/24/2013 1:41 PM, Richard Quadling wrote: On 24 January 2013 17:48, Matt Pelmear wrote: On 01/24/2013 09

Re: [PHP-DB] pdo ?

2013-01-24 Thread Jim Giner
On 1/24/2013 4:37 PM, Karl DeSaulniers wrote: On Jan 24, 2013, at 2:15 PM, Matt Pelmear wrote: On 01/24/2013 12:00 PM, Jim Giner wrote: On 1/24/2013 1:41 PM, Richard Quadling wrote: On 24 January 2013 17:48, Matt Pelmear wrote: On 01/24/2013 09:23 AM, Jim Giner wrote: On 1/24/2013 12:05

Re: [PHP-DB] pdo ?

2013-01-24 Thread Jim Giner
If you are using another web server or running PHP as FastCGI you may need to consider other options (changing the setting globally or doing a require_once() of your config changes?, or see the FastCGI example here: http://www.askapache.com/php/php-htaccess-tips-tricks.html) -Matt It sounds like

Re: [PHP-DB] pdo ?

2013-01-24 Thread Jim Giner
On 1/24/2013 1:41 PM, Richard Quadling wrote: On 24 January 2013 17:48, Matt Pelmear wrote: On 01/24/2013 09:23 AM, Jim Giner wrote: On 1/24/2013 12:05 PM, Matt Pelmear wrote: http://stackoverflow.com/questions/5801951/does-php-auto-escapes-quotes-in-string-which-is-passed-by-get-or-post

Re: [PHP-DB] pdo ?

2013-01-24 Thread Jim Giner
your queries, I would recommend disabling it. -Matt On 01/24/2013 08:55 AM, Jim Giner wrote: ok - new to using pdo functions, but I thought I had a handle on it. I'm writing out to my page an input tag with the following value in it: 49'ers I can confirm it by using my browser'

[PHP-DB] pdo ?

2013-01-24 Thread Jim Giner
ok - new to using pdo functions, but I thought I had a handle on it. I'm writing out to my page an input tag with the following value in it: 49'ers I can confirm it by using my browser's "view source" to see that is exactly how it exists in the page. When I hit a submit button and my script

[PHP-DB] Re: PDO ?

2013-01-15 Thread Jim Giner
Never Mind A little careful re-reading of the docs told me what I was doing wrong. I always use PDO::FETCH_ASSOC in my fetch statements. Discovered that I have to have numerical array results in order to utilize the List command. Voila! -- PHP Database Mailing List (http://www.php.net/

[PHP-DB] PDO ?

2013-01-15 Thread Jim Giner
Doing some conversion - looking for a solution. Currently I do something like this: while (list($var1,$var2) = mysql_fetch_array($qrslts)) { handle the vars } Is there something in the PDO functions that emulates this same ability? Some of my uses of the sql syntax have many more vars and

[PHP-DB] Re: Preventing repetition of a Form

2013-01-07 Thread Jim Giner
On 1/7/2013 7:00 PM, Ethan Rosenberg, PhD wrote: Dear list - I have a program [*pseudo code*]: if(!isset($_REQUEST["welcome_already_seen"])) { initialize variables } $errors_array = array(); if($_REQUEST["welcome_already_seen"]== "al

[PHP-DB] Re: Programs not Running - SOLVED

2013-01-06 Thread Jim Giner
On 1/6/2013 7:17 PM, Ethan Rosenberg, PhD wrote: Dear List - Thanks to all for your help. The problem was in this piece of code: require '/var/www/pass.inc'; $db = "Store"; $cxn = mysqli_connect($host,$user,$password,$db); if ( !$cxn ) { die( 'con

Re: [PHP-DB] Programs not running

2013-01-04 Thread Jim Giner
for parameters. The >>> programs run beautifully on the desktop, but refuse to run on the laptop. >>> Error_reporting is set to -1. I receive no errors. >>> >>> Advice and help, please. >>> >>> Ethan > = > Jim and Mat

Re: [PHP-DB] Programs not running

2013-01-04 Thread Jim Giner
On 01/03/2013 08:54 PM, Ethan Rosenberg, PhD wrote: = I can't answer because I do not understand. gives the correct output. Ethan - whatever do you mean the phpinfo gives the correct output? Do you mean that you compared every line and found them to match EXCEPT where you

[PHP-DB] Re: Programs not running

2013-01-03 Thread Jim Giner
On 1/3/2013 7:35 PM, Ethan Rosenberg, PhD wrote: Dear List - I am running sid on my Lenovo desktop and squeeze on my Dell laptop. The php.ini files are the same. The programs are the same except foro the locatioln of the password file and of a file to be read for parameters. The programs run be

[PHP-DB] Re: Prepared Statements - Search

2012-12-03 Thread Jim Giner
On 12/3/2012 2:30 PM, Ethan Rosenberg, PhD wrote: Dear List - I am trying to use prepared statements with the following code: $allowed_fields = array ('Cust_Num' => 'i', 'Fname' => 's', 'Lname' => 's', 'Street' => 's','City'=> 's', 'State' => 's', 'Zip

[PHP-DB] Re: Prepared Statements - Search

2012-12-03 Thread Jim Giner
On 12/3/2012 2:30 PM, Ethan Rosenberg, PhD wrote: Dear List - I am trying to use prepared statements with the following code: $allowed_fields = array ('Cust_Num' => 'i', 'Fname' => 's', 'Lname' => 's', 'Street' => 's','City'=> 's', 'State' => 's', 'Zip

[PHP-DB] Re: Formatting - Solved

2012-11-26 Thread Jim Giner
On 11/26/2012 1:04 PM, Ethan Rosenberg, PhD wrote: Dear list Here is the answer ORIGINAL Search Results Site Medical Record First Name Last Name Phone Height Sex History Birthday Age \n"; $_SESSION['exe'] = 2; ?> \n";

Re: [PHP-DB] Re: Formatting

2012-11-25 Thread Jim Giner
On 11/25/2012 5:39 PM, Ethan Rosenberg, PhD wrote: List - Any more ideas. = Keep on debugging jg Jim - I've been at this for a few weeks, and am stuck. Thanks for all your help. Ethan + On Nov 25, 2012, at 1:59 PM, "Ethan Rosenberg, PhD" wrote: On 11/25/201

[PHP-DB] Re: Formatting

2012-11-25 Thread Jim Giner
On 11/25/2012 12:46 PM, Ethan Rosenberg, PhD wrote: Dear list - When I run the following code, the results are preceded by at least one screen full of blank lines. I am showing you a large code block since I do not know where the error is: if(isset($_REQUEST['Sex'])&& trim($_POST['Sex']) !

[PHP-DB] Re: Program Dies

2012-10-15 Thread Jim Giner
On 10/14/2012 5:57 PM, Ethan Rosenberg, PhD wrote: Dear List - Thank you ever so much for all your help. I apologize in advance for dumping all this code on you. I cannot get any debugger to work for me [see my separate email on debuggers]. I placed numerous echo and print_r statements in the

[PHP-DB] Re: Prepared Statements - Select - Bind Parameters w/ correction

2012-09-27 Thread Jim Giner
On 9/27/2012 12:40 PM, Ethan Rosenberg, PhD wrote: Dear list - SEE CORRECTION IN $_POST VARIABLE BELOW. Thanks to all for your help. I hope [??] that this question will solve all the remaining problems. So that we are on the same page, here is what was previously stated. mysqli_stmt_bind_par

Re: [PHP-DB] opening error messages in a new window

2012-09-26 Thread Jim Giner
On 9/26/2012 9:35 AM, Jimi Thompson wrote: So tell the error message to open in a target="_blank" On Wed, Sep 26, 2012 at 3:41 AM, Dr Vijay Kumar < vaibhavinformat...@gmail.com> wrote: In filling a form, error messages should come in a new widow while retaining the form filled on the screen.

[PHP-DB] Re: opening error messages in a new window

2012-09-26 Thread Jim Giner
On 9/26/2012 4:41 AM, Dr Vijay Kumar wrote: In filling a form, error messages should come in a new widow while retaining the form filled on the screen. Coding in php is required. If I read your rather terse message correctly, you are looking for a way to provide error responses to the user wit

[PHP-DB] Why the sudden dis-interest?

2012-09-21 Thread Jim Giner
What's with all the people suddenly wanting to unsubscribe? Did they suddenly become experts - no longer needing the community for support? Or did they suddenly discover they had actually enlisted for the influx of emails they were getting and wanted to stop them? Sure seems odd -- PHP D

[PHP-DB] Re: Many columns (as FK) vs 3x more Columns (in the same table)

2012-09-19 Thread Jim Giner
On 9/19/2012 3:12 PM, Jim Giner wrote: On 9/18/2012 8:52 AM, Bruno Sandivilli wrote: Hi, i strugling to decide what is the best choice: I have a 15 row x 3 columns Flash DataGrid, it means, for each row i have 3 values. To represent this in my Database, I could: 1. Create 2 Tables : A

[PHP-DB] Re: Many columns (as FK) vs 3x more Columns (in the same table)

2012-09-19 Thread Jim Giner
On 9/18/2012 8:52 AM, Bruno Sandivilli wrote: Hi, i strugling to decide what is the best choice: I have a 15 row x 3 columns Flash DataGrid, it means, for each row i have 3 values. To represent this in my Database, I could: 1. Create 2 Tables : A Values table - with 3 columns ; and a Bill

Re: [PHP-DB] Re: Problems w/ insert -- SOLVED!!!

2012-09-13 Thread Jim Giner
On 9/13/2012 9:15 PM, Ethan Rosenberg, PhD wrote: Dear list - Thanks to all. It now works! The problem, as you correctly noted, was the erroneous inclusion of the bind-results statement. Removed that and it worked!! Thanks again! Ethan Methinks Ethan is thanking the group for assistance o

[PHP-DB] Re: Adding entry to /dev

2012-09-10 Thread Jim Giner
On 9/10/2012 7:41 PM, Ethan Rosenberg, PhD wrote: Dear list - How do I add a new entry to /dev; eg, /dev/sdb? Thanks, Ethan Rosenberg Ethan, Sometimes google is great at answering this kind of stuff. Did you try a search on your question. I did and found an answer in the fifth result ret

Re: [PHP-DB] Re: Problems w/ insert

2012-09-10 Thread Jim Giner
On 9/11/2012 12:04 AM, Matt Pelmear wrote: Ethan, I am curious why you are using mysqli_stmt_bind_result() on a statement that is an INSERT query? I don't use mysqli, but as I read the documentation it seems to me that this method is intended to bind results from a SELECT query into variables so

[PHP-DB] Re: Problems w/ insert

2012-09-10 Thread Jim Giner
On 9/10/2012 8:06 PM, Ethan Rosenberg, PhD wrote: Dear list - Here is my code: $sql3 = "select max(Indx) from Visit3"; $result7 = mysqli_query($cxn, $sql3); $row7 = mysqli_fetch_array($result7, MYSQLI_BOTH); $Indx = $row7[0]; $sql2 = "INS

Re: [PHP-DB] Re: Problems w/ insert

2012-09-10 Thread Jim Giner
On 9/10/2012 8:29 PM, Karl DeSaulniers wrote: On Sep 10, 2012, at 7:06 PM, Ethan Rosenberg, PhD wrote: Dear list - Here is my code: $sql3 = "select max(Indx) from Visit3"; $result7 = mysqli_query($cxn, $sql3); $row7 = mysqli_fetch_array($result7, MYSQLI_BOTH);

Re: [PHP-DB] Another PDO ?

2012-09-10 Thread Jim Giner
On 9/10/2012 11:10 AM, Lester Caine wrote: Jim Giner wrote: On 9/10/2012 10:49 AM, Bastien Koert wrote: On Mon, Sep 10, 2012 at 9:48 AM, Jim Giner wrote: Reading up on the pdostatement class. Wondering what the intent of the columnCount function is. I mean, aren't the number of colum

Re: [PHP-DB] Another PDO ?

2012-09-10 Thread Jim Giner
passed in. That's my guess. On Mon, Sep 10, 2012 at 8:51 AM, Jim Giner wrote: On 9/10/2012 10:49 AM, Bastien Koert wrote: On Mon, Sep 10, 2012 at 9:48 AM, Jim Giner wrote: Reading up on the pdostatement class. Wondering what the intent of the columnCount function is. I mean, aren&

Re: [PHP-DB] Another PDO ?

2012-09-10 Thread Jim Giner
On 9/10/2012 10:49 AM, Bastien Koert wrote: On Mon, Sep 10, 2012 at 9:48 AM, Jim Giner wrote: Reading up on the pdostatement class. Wondering what the intent of the columnCount function is. I mean, aren't the number of columns in a result known when you write the query? Granted, you

[PHP-DB] Re: PDO user question

2012-09-10 Thread Jim Giner
On 9/8/2012 2:02 PM, Jim Giner wrote: I finally delved into learning how I was going to replace my MYSQL calls with a different interface. Had to go with PDO since my hoster doesn't support MYSQLI for my plan. I've had some success with querying using pdo and prepared statements as

[PHP-DB] Another PDO ?

2012-09-10 Thread Jim Giner
Reading up on the pdostatement class. Wondering what the intent of the columnCount function is. I mean, aren't the number of columns in a result known when you write the query? Granted, you might have some very complex query that you may not know the number, but for most queries you will kno

[PHP-DB] PDO user question

2012-09-08 Thread Jim Giner
I finally delved into learning how I was going to replace my MYSQL calls with a different interface. Had to go with PDO since my hoster doesn't support MYSQLI for my plan. I've had some success with querying using pdo and prepared statements as well. One thing that I'm curious about is How

Re: [PHP-DB] mysqli_connect ??

2012-09-07 Thread Jim Giner
No - they are not. :( On 9/7/2012 1:32 PM, Bastien Koert wrote: On Fri, Sep 7, 2012 at 10:54 AM, Jim Giner wrote: Experimenting with prepared statements - trying out for the first time. I keep getting a fatal error on this statement: mysqli_connect(.) Message is: Fatal error: Call to

[PHP-DB] mysqli_connect ??

2012-09-07 Thread Jim Giner
Experimenting with prepared statements - trying out for the first time. I keep getting a fatal error on this statement: mysqli_connect(.) Message is: Fatal error: Call to undefined function mysqli_connect() in /home/albany/php/sqli_db_connect_select.php on line 6 My host is running php 5

Re: [PHP-DB] Re: Prepared Statements Insert Problem

2012-09-03 Thread Jim Giner
On 9/3/2012 2:44 AM, tamouse mailing lists wrote: On Sun, Sep 2, 2012 at 10:24 PM, Ethan Rosenberg, PhD wrote: mysqli_stmt_bind_result(): Number of bind variables doesn't match number of fields in prepared statement What exactly is unclear about that? Actually - from looking at the code the

Re: [PHP-DB] Re: Prepared Statements Insert Problem

2012-09-02 Thread Jim Giner
So do u have the revised code to show us? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-DB] Re: Prepared Statements Insert Problem

2012-09-02 Thread Jim Giner
On 9/2/2012 12:45 AM, Ethan Rosenberg, PhD wrote: Dear List - I wish to accomplish the following with prepared statements: FYI - The Database: mysql> describe Intake3; ++-+--+-+-+---+ | Field | Type| Null | Key | Default | Extra | ++---

Re: [PHP-DB] Re: No data?

2012-07-27 Thread Jim Giner
On 7/27/2012 11:03 AM, Brad wrote: Even though my permissions are 777 in my /tmp I am trying to send the file to a tmp directory in my webroot and if I can even get it to create the file it has the wrong name of 'Array', and then it still does not update my database. 0)

Re: [PHP-DB] Re: No data?

2012-07-26 Thread Jim Giner
Not sure what you mean - "Program reads array". What program is doing is utilizing the FILES element to get the info about the uploaded file and proceeds to finish the upload by moving it to a temporary folder of your creation. Once that is done you HAVE the file under whatever name you want

[PHP-DB] Re: No data?

2012-07-26 Thread Jim Giner
Are you any closer to getting your solution to work yet? If not, could I ask for the general concept again? From what I can remember, You want to allow a user to upload a csv file which you will then put into a sql table. Additionally your code seems to be creating a new table for each file

Re: [PHP-DB] Re: Stuck trying to upload and grab file name

2012-07-24 Thread Jim Giner
On 7/24/2012 12:40 PM, Graham H. wrote: If by "the line" you mean: ["tmp_name"]=> string(14) "/tmp/phpcLtE6W" That is from the bottom of this Pastie link: http://pastie.org/4317155 $file = $_FILES["file"]["tmp_name"]; I meant the above line. -- PHP Database Mailing List (http://www.php.

[PHP-DB] Re: Stuck trying to upload and grab file name

2012-07-24 Thread Jim Giner
On 7/24/2012 4:16 AM, Brad wrote: $file = $_FILES['file']['name']; //$presql = "CREATE TABLE IF NOT EXISTS (`$_SESSION[SESS_MEMBER_ID]_$file`)"; $presql = "CREATE TABLE IF NOT EXISTS `$_SESSION[SESS_MEMBER_ID]_$file`";

Re: [PHP-DB] Re: Stuck trying to upload and grab file name

2012-07-24 Thread Jim Giner
On 7/24/2012 12:05 PM, Graham H. wrote: Does the problem have anything to do with this: ["tmp_name"]=> string(14) "/tmp/phpcLtE6W" So this: $file = $_FILES["file"]["tmp_name"]; Would make $file == "/tmp/phpcLtE6W" I'm not sure if that's what you want. Seems more likely that you'd want it

  1   2   3   >