On Wed, 18 Feb 2004 09:35:22 -, Slippyaah wrote:
>Well basically I think it's a problem with the declaration of variables
>and/or the way they are being processed by the form.
>
>Here is the individual addNews function:
>
>function addNews() {
> global $db;
>
> /* declare variables
On Sun, 22 Feb 2004 11:02:29 EST, [EMAIL PROTECTED] wrote:
>Dear friends,
>
>I have pap4, mysql, apache installed. How do I enable to access
> /"$_SERVER[PHP_SELF]/"
>.Comments, please
Correct your syntax errors:
\"$_SERVER['PHP_SELF']\"
Doug
--
PHP Database Mailing List (http://www.php.net
On Fri, 27 Feb 2004 01:16:20 +0100, Erwin Kerk wrote:
>Robin 'Sparky' Kopetzky wrote:
>
>> Good afternoon!
>>
>> I used SQLYOG to export the tables and data from a Mysql database. Now, when
>> i try to re-import the data back into a different database, I get an error
>> stating "Error : MySQL ser
On Mon, 1 Mar 2004 17:16:01 -0800 (PST), Mike Ni wrote:
>Hey everyone,
>
>
>Does anyone outhere is running Apache/Linux/PHP/Mysql?
>
>I am having hard time with "MYSQL PHP API". Apache/PHP
>simply would not recognize any cmysql function call
>such as "mysql_connect".
>
>I have recompile the php wi
On Thu, 04 Mar 2004 12:46:51 -0600, Mignon Hunter wrote:
>Can anyone recommend, or does anyone have handy, a script that will encrypt passwords
>AND then also be able to retrieve the encrypted password.
>
>Checking out the docs and some books has confused me mostly.
>
>Thx
>
Yes and no.
$pw =
It is a string function that returns a 32-character md5 hash of "password." MD5 is
the name for a current RSA Message Digest Algorithm encryption method.
A search in the manual for md5 gets you to the little bit of information in the manual
plus a link to RFC 1321 which likely provides more inf
Richard,
Why do you exclude the MySQL Manual from your list of references?
See sections 6.2 and 6.2.1. In 6.2.1, you will find:
Another extension is supported by MySQL for optionally specifying
the display width of an integer value in parentheses following the
base keyword for the type (for e
On Fri, 5 Mar 2004 16:45:12 -0500, Chris Ruprecht wrote:
>On Friday 05 March 2004 06:36, Kae Verens wrote:
>> Richard Davey wrote:
>> > Hi all,
>> >
>> > Sorry for such a newbie question! But I have been digging through the
>> > O'Reilly MySQL book + MySQL Cookbook and cannot find an answer to wha
Hi Karen,
Depending upon the method used for your form, you should be able to find the value in either $_GET['pagesize'] or $_POST['pagesize'].
hth,
Doug
Karen Resplendo wrote:
What is wrong with this picture? I build a pulldown for selecting page size(number of rows in one page). If page is ne
Craig:
I don't see a reply to your question in today's posts.
"Backticks" or "tick marks" allow you to use reserved words for column names. Interval is a reserved word.
Hope you weren't waiting this long for a response.
Doug Thompson
Craig Hoffman wrote:
Why
Brown, Craig wrote:
I am trying to update a database that I use to store user names and the
hashed values of passwords. The database name is Login, the table is
"users".
I have the following commands in my php file.
@ $db=mysql_pconnect('localhost','apache','password');
mysql_
JeRRy wrote:
Hi,
I have a php, mysql security question.
You know how there is a way to enable/disable hot
linking to your images via CPanel to allow/disallow
people to link to your images from an external site?
Well is there a way to allow/disable external sites
connecting to a mysql via P
Oops. For some reason my filter concluded your email was spam and it modifies the
subject line. I missed cleaning the subject line on the first reply. Here is is
again in case others filter on that keyword. I apologize for the double post and
possible confusion.
\Doug
JeRRy wrote:
Hi,
I
[EMAIL PROTECTED] wrote:
I'm running Apache/2.0.49 and PHP/4.3.5 on windows XP with MSIE 6.0. -- local host.
When I try to access the variables in the array (HTTP POST), they are empty or null. Did I miss a PHP or Apache setting in the php.ini or httpd.conf?
Use$_POST['array_element']
Doug
-{ Rene Brehmer }- wrote:
Working with PHP 4.3.0 and MySQL 4.0.14 (but code MUST be compatible with
3.23.56).
For my forums, I've got this 4-way join to load (and output) the posts with
info on the poster:
$fullthread = "SELECT
postID,hf_posts.userID,name,time,post,edit,nickname,joined,location,pos
Dan Bowkley wrote:
got it...rather than return false, mysql_result throws an error if the query
returns nothing. What a pain.
NOT True.
If the query is syntactically valid and nothing matches, mysql returns zero rows which is not an error, at least on the part of the dbms. Use mysql_num_rows() t
Tumurbaatar S. wrote:
I use pg_fetch_array() to get a record content. But it seems that
to access elements of the returned associative array, I should
use lowercase field names. Is there any way to use case-insensitive
field names?
Assuming you want all lower case, convert the form field entry usi
[EMAIL PROTECTED] wrote:
Would somebody be kind enough to explain why this query produces a false result
$latest=mysql_query("SELECT MAX(fee_recd) FROM members",$connectup)or die
("Query failed:$latestError: " . mysql_error());
but this one doesn't
$latest=mysql_query("SELECT fee_recd FROM members
Rosen wrote:
Hi,
I have a simple table:
test (
id int unsigned NOT NULL auto_increment,
data varchar(30) default NULL,
PRIMARY KEY (id))
with two simple records:
id data
1 "a"
2 "A"
When I perform "select * from test where data='a' " - it return me both
rows.
http://dev.mysq
if (is_null($row["timeout"]).)
[EMAIL PROTECTED] wrote:
Still no joy. The parse error actually refers to the -- if
($row["timeout"] IS NULL); --- line.
-Original Message-
From: Eric Schwartz [mailto:[EMAIL PROTECTED]
Sent: Friday, 6 August 2004 11:32 AM
To: [EMAIL PROTECTED]
Subject:
[EMAIL PROTECTED] wrote:
I finally got my PHP5 installation to support MySQL and now this. When I try
to edit anything on mysqlgui.exe, it just gives me this error: error in
database function: access denied for user @localhost...
I don't know if this has to do with my php installation or what. I
[EMAIL PROTECTED] wrote:
Dear Friends,
Data in the table is displayed by php query.
.Say column A, in which name of company will be stored.
Now i want to add another column B to table in which web addresse will be
stored against each name in Column B.and same should be displayed in an html
table
Michael Gale wrote:
Hello,
Right now I have a mysql select statement with the LIMIT option of 500.
Is there a way to find what the total number of selected results would
of been with out doing a mysql select first with out the limi and using
mysql_num_rows ?
Thanks
You could use SQL_CALC_FO
Mike wrote:
hi, I've currently been looking for a mysql news server where I could post
some questions on mysql database design (cause they shurely wouldn't fit
here) and I have yet to find one. Can anyone help?
http://lists.mysql.com/
--
PHP Database Mailing List (http://www.php.net/)
To unsubs
Stuart Felenstein wrote:
I am in the process of building a search form for the
database. The entire thing consists of 3 multi
selects and 2 text boxes with a "contains". Oh and
I've only rigged 2 of the multi selects for the time
being.
So the way the multiselects should work that the user
can c
Aravalli Sai wrote:
hi
this is php code for inventory management system
which is done using SQLite.this is an user
interface where an user wil giv values to the text
boxes and it should be saved in the backend database
which is sqlite..
but when i run this code on browser it is giving an
err
The variables are not being expanded. As a minimum, you need to escape the single quotes.
$query = "SELECT * from user where name=\'$userid\' and
pass=password(\'$password\')"
Alternatively, you can concatenate the expanded variables.
$query = "SELECT * from user where name='".$userid."' and
p
ian wrote:
Any body met this error?
Warning: mysql_connect(): Client does not support authentication
protocol requested by server; consider upgrading MySQL client in
/usr/local/apache2/html/poems/browse.php on line 15
http://dev.mysql.com/doc/mysql/en/Old_client.html
--
PHP Database Mailing List (h
Bishnu Prasad Dahal wrote:
Dear all,
I have to create a newsletter for a site
http://www.migratetousa.com , I didn't code for any newsletter. could
you suggest me how can I design the newsletter? And please send me
sample php codes for newsletter
Thanks,
Hame
I suggest you take a look at
http
Aravalli Sai wrote:
hi
i had designed an inventory management system where
in i can ADD,INSERT,DELETE,UPDATE the data
elements..but when i am trying to find(search) an
entry in theinventory data base system (i want to find
the entrybased on the "tagno" since this is the
primary key in my table) t
The manual is your friend.
You cannot execute the SQL statement you provided because mysql specifically
disallows it:
http://dev.mysql.com/doc/mysql/en/INSERT_SELECT.html
Same reference, your presumption about auto-increment columns is also wrong.
Doug
blackwater dev wrote:
Hello,
I want to create
Dave,
The list has been very active with many posts per day all week.
Based on your domain, you might check with the sysops and see if they've done
any updating to firewalls and/or corporate filters.
Good luck,
Doug
[EMAIL PROTECTED] wrote:
Just testing the list mail server as I haven't received a
It seems to me that the _mysql manual_ gives a most straightforward and useful
explanation:
"If you specify the ON DUPLICATE KEY UPDATE clause (new in MySQL 4.1.0), and a
row is inserted that would cause a duplicate value in a UNIQUE index or PRIMARY KEY,
an UPDATE of the old row is performed. F
I isn't my intention to start a peeing contest, but if *you* get rid of the
chip and actually read the manual excerpt, the equivalent SQL statements it
cites are very definitely available in mysql 3.xx.xx.
DT
Mark Benson wrote:
Doug, read my e-mail again, specifically the second and third paragra
Todd Cary wrote:
I have compiled interbase.so, but even though I have
extension=interbase.so
in the php.ini file, it is not part of PHP. Has anyone had success
doing this?
Todd
A quick peek at the list archives (search term="interbase.so") revealed this:
http://marc.theaimsgroup.com/?l=php-db&m
Simple _complete_ solution: Find a different hosting company that provides a
virtual server and root access to everything about your account. Cost should
be nominal, but probably not free.
Simple _partial_ solution: Use INCLUDEs for the login portions of the
script(s) and place them in a prot
Shay wrote:
Yes they gave me phpMyAdmin to use, and no, I have no access to the
user/privilege table. So the only way to output database entries is to
connect with the single super account they gave me.
Principally, this means you cannot allocate user accounts for mysql. No
big deal unless you
t as user "test."
Doug
Bastien Koert wrote:
Another thought on this:
Even though you don't have access via phpmyadmin to get to the users
table, could you try to create users/grant privileges via straight sql
thur the PMA sql window?
ie
grant select, insert, update to 'bob'
Generally, you want to use the LIMIT function.
SELECT num FROM myfile ORDER BY num LIMIT 3;
However, if the values may be repeated (e.g., 1,1,1,2,4,4,5), the query
above will return 1,1,1.
If you are interested in the three lowest values and not just smallest
entries, add DISTINCT
SELECT DISTINC
The simplest solution is to edit php.ini on your Linux box and set the
parameter register_globals to ON. As of PHP4.2.0 the default setting
is OFF and new "super globals" are available.
A better solution is to update your windows box to the same version of
PHP so that you are programming to the im
1. Is mysqld running? I don't remember if the default configuration
for RH8.0 sets it to start on system boot.
The easy way to check is:
ps aux | grep mysql
or
mysqladmin -u root ping
will return "MySQL is alive" if the server is running.
2. See chapter 2.4 of the MySQL Man
OK. I consider this an easier way. I use it to display fullsize
images when a thumbdnail is clicked. Same principle.
>From
var pixNum="",winName="", mheight="", mwidth=""
var pixURL="http://**someURL**/";
function viewPix(pixNum,winName,mheight,mwidth) {
...
if ($result) {
while ($row...
...
}
$result will be 0 (false) if nothing satisfies the query. Any other
comparison is just extra typing with no improvement in logic.
Regards,
Doug
On Thu, 09 Jan 2003 13:06:51 -0500, Michael Cortes wrote:
>I am a programming novice
You're absolutely right.
It must be the 1.5 hours of sleep last night that made my brain shrivel
up like that. 8(
Doug
On Thu, 9 Jan 2003 17:45:00 -0500, John W. Holmes wrote:
>> ...
>> if ($result) {
>> while ($row...
>> ...
>> }
>>
>> $result will be 0 (false) if nothing satisfies t
MySQL cannot find the username in its grant tables.
The error message very clearly states that there is no user named
'x,@host' which is the value of your $user variable. For your example,
$email == 'x' and $femail == '@host'. The comma is included because it
is part of the literal string, i.e.,
Here is a link to a tutorial which explains the issues and introduces
how
to use the new global variables.
Write Secure Scripts with PHP 4.2!
http://www.webmasterbase.com/article/758
Regards,
Doug
On Thu, 23 Jan 2003 00:30:24 +0100, Karina S wrote:
>Hi,
>
>I have read, that use global variables
UPDATE is for changing values in existing rows. It appears you want to
add new information. Use INSERT.
$query= "INSERT tablename SET (username, email, location) VALUES(
$username, $email, $location)";
Note that a WHERE condition is incorrect for INSERT.
Your UPDATE syntax is not correct either
ERE clause, see the
>
>INSERT table
>SELECT ...
>
>syntax.
>
>Extremely convenient. You inherit all the flexibility of the SELECT
>statement.
>
>Ignatius
>
>----- Original Message -
>From: "Doug Thompson" <
Try getting the results from the query like the following.
Doug
// generate and execute query
$query = "select * from changelog where changedBy = '$changedBy' or
vendorNumber = '$vendorNumber'
or oldName like '$oldName' or newName like '$newName' or
newVendorNumber =
'$newVendorNumber'";
$result
On Thu, 06 Feb 2003 10:33:23 -0700, Doug Thompson wrote:
>Try getting the results from the query like the following.
-snip-
With the correct syntax. 8-(
Doh!
>
>//
>$numrows = mysql_num_rows ($result);
> ^
--
PHP Database Mai
Merlin:
You might find it easiest to CREATE a temporary table.
You can use an INSERT .. SELECT query to extract the values from your
data tables and insert them in the temp table.
Then you can SELECT from the temporary table and use all of the SQL
functions for ordering, grouping, etc.
Doug
On M
If your client's friend wants to do learning/development, let him load
PHPTriad, FoxServ, or one of the other trinity setups onto his
computer.
It is truly remarkable that you/your company would even consider such a
request for longer than it takes to say: Never in a million years.
Also, if I wer
http://www.hotscripts.com/PHP/
One example:
http://www.hotscripts.com/Detailed/9026.html
Good luck,
Doug
On Fri, 14 Feb 2003 16:09:34 +0100, Ingen, Wart van wrote:
>Hi there,
>
>I'm looking for a way to let people without any knowledge of coding replace
>large fields of text and images on thei
Nikos:
The mysql.sock file is created by mysqld when it is running.
The error you report is very common and you will find troubleshooting
tips at:
http://www.mysql.com/doc/en/Can_not_connect_to_server.html
Doug
On Tue, 18 Feb 2003 10:18:42 +0200, nikos wrote:
>GlacierHi List
>I run mysql 3,23..
This recent thread from the mysql list explains a lot about the
problem.
http://lists.mysql.com/cgi-ez/ezmlm-cgi?1:mss:15034
hth,
Doug
On Sat, 1 Mar 2003 12:24:57 +0100, Frank Keessen wrote:
>Hi All,
>
>I'm trying to get a random record each time this script runs; Only it's giving me
>everytim
Without knowing your query, it is hard to say whether mysql can return the results you
want.
However, you can GROUP BY and SORT BY multiple columns in a single query. The
following simple query returns a subset of property owners grouped by lastname,
alpabetized by group, and ordered by zipcod
You will use the mysql_select_db() function. It sets the currently active database.
You will call this function each time you wish to change which database is being used
prior to issuing a query.
You need to open only one connection as long as the databases are on the same server.
If you are
There's nothing like RTFM to douse the fire in a rant.
4.2.3 Startup Options for mysqld Concerning Security
The following mysqld options affect security:
--local-infile[=(0|1)]
If one uses --local-infile=0 then one can't use LOAD DATA LOCAL INFILE.
This setting has been defaulted to 0 in re
The access denied message you are seeing is usually the result of either an incorrect
password or username, but you don't give enough information to allow guessing beyond
that.
Are you certain your script is submitting the expected values?
Doug
On Sat, 05 Apr 2003 21:54:33 -0600, [EMAIL PROTE
Unlike Luke, I'm not familiar with this book. However, it's a pretty safe bet that it
was written prior to the first version of PHP that defaulted register_globals to OFF.
All of your variables for the second page will be found in the global array $_POST[]
because the method for the form on the
Your IP users have no permissions. (Hint: N = No)
How is this a PHP problem? (Hint: It is all over the mysql list archives.)
Doug
On Thu, 12 Jun 2003 13:35:21 +0300, nabil wrote:
>GUYS help me please.
>1- mysql server in on my own machine..
>2- my machine IP is 192.168.0.1
>3- when i tired
Why not use the built-in conversion functions in mysql?
>From the manual:
INET_NTOA(expr)
Given a numeric network address (4 or 8 byte), returns the dotted-quad representation
of the address as a string:
mysql> SELECT INET_NTOA(3520061480);
-> "209.207.224.40"
INET_ATON(expr)
Given t
This is in the archives, but it was faster to find it in my stack of saved stuff:
For those who installed RH 8.0 and went threw the same php/mysql woes you
just have to go to
http://rpmfind.net/linux/rpm2html/search.php?query=php-mysql
And install the 8.0.5 (psyche?) or 8.0.7 php-mysql rpm.
D
So look a little farther down the list and try the RPM for RH9.0.
On Mon, 16 Jun 2003 00:05:19 -0400, Jack Orenstein wrote:
>Doug Thompson wrote:
>
>>This is in the archives, but it was faster to find it in my stack of saved stuff:
>>
>>
>>For those who installed
Check that mysql is still the owner of its subdirectories.
You might also look on the mysql list for other possibilities as this is a frequent
topic.
Doug
On 17 Jun 2003 10:02:29 +0800, Ramil G. Sagum wrote:
>
>On Tue, 2003-06-17 at 03:08, Nathan wrote:
>
>> # ./bin/mysqld_safe &
>> Starting
1. The default user table sets up root with no password. Leave out the password and
it will probably connect OK. You really need to fix the user table, but as long as
the system isn't accessible from outside, you can get by.
2. You don't need to use "host", in this case 127.0.0.1, when connec
An incredible interpretation of
If called without the optional min, max arguments rand() returns a pseudo-random value
between 0 and RAND_MAX. If you want a random number between 5 and 15 (inclusive), for
example, use rand (5, 15).
Doug
On Tue, 24 Jun 2003 11:14:55 -0400, Gerard Samuel wro
Maybe it's because I'm not fully awake yet that the problem seems less complex than it
is.
What is wrong with using a seperate table for each year?
Doug
On Thu, 26 Jun 2003 08:43:17 +0200, anders thoresson wrote:
>Hi,
> I'm working on a web based article planning system for a news paper, based
Full text searches only work against fulltext indexes.
http://www.mysql.com/doc/en/Fulltext_Search.html
This isn't a PHP issue.
Doug
On Fri, 18 Jul 2003 09:42:17 +0200, Angelo Zanetti wrote:
>Hi
>
>I have a table which contains 3 fields (ID, Title, Abstract) the title and abstract
>fields ha
Try one of these:
http://zez.org/article/articleprint/11
http://www.javaworld.com/javaworld/jw-07-2001/jw-0713-regex_p.html
Doug
On Fri, 1 Aug 2003 11:34:16 -0400, Aaron Wolski wrote:
>Hi All,
>
>Sorry for OT post but need some info.
>
>Does anyone know a good tutorial that explains regular
You have an error in your PHP code, just as the error says.
Including only the query, which you've already tested, isn't very helpful.
The error message is telling you that the result "link identifier" used in your fetch
statement isn't the same as returned by the query statement OR there was an
One day I'll learn to wait until two cups of coffee before attempting to post replies.
On top of which, I have no idea where "0.8" came from. 8-/
Sorry for the confusion factor.
Doug
On Tue, 12 Aug 2003 10:47:21 +0100, Phil Driscoll wrote:
>On Tuesday 12 August 2003 10:39 am, Phil Driscoll
The "%" is called the Modulus operator. It is very briefly explained in the PHP
manual in table 11-2.
In your example, $mod = $a % $b ==> $mod = 0.8
It is a very easy operator to use.
Doug
On Tue, 12 Aug 2003 11:04:39 +0200, Alain Barthélemy wrote:
>Hello,
>
>If you have
>
>$a = 24;
>$b =
On Tue, 2 Sep 2003 16:45:28 +0100, Craig Cameron wrote:
>
>Ok simple problem I hope.
>
>
>Have the following code, used to store the location and a few details about meeting
>minutes.
>
>
> $connection = mssql_connect("server","user","password");
> mssql_select_db("Doc
74 matches
Mail list logo