Hi,
I am having problems with this code. I want to update a members number of
days they have been a member can anyone help?
$query["days"]=("UPDATE users set days_member VALUES = ('days_member' +
'1'));
$result=mysql_query($query["days"]);
Thanks in advance
JD
--
PHP Database Mailing List (
they
explain in technical terms in which 98% of us don't understand. So we have
to do things by trial and error and learn by our mistakes and pray that
someone who does know can explain in a way that we can understand.
Regards
Jennifer Downey
"Miles Thompson" <[EMAIL PROTECTED]&g
nto the database.
As soon as test.php shows in browser, the Username, submit button and box ar
e there but also
it prints the "There has been a problem." right off the bat. Now I know
there are misprints in the book
and I hope I was smart enough to catch them but maybe not. can someone
ame & password?
>
> I've found the articles at devshed to be helpful in the past. This
> particular one has a pretty good explaination of setting up a user
> authentication system:
>
> http://www.devshed.com/Server_Side/PHP/TimeIsMoney/TimeIsMoney1/page1.html
>
> Robe
ate
once
a day.
Any help would be appreciated!
Thanks
Jennifer Downey
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hi again,
I am having trouble with updating. How do I tell php to update the database
at mid night instead of every time the browser is
refreshed? I have looked for it but can't find the info.
Also I thought session ID's were different between users. Is this true?
Thanks
Jenni
a way to set this code
up to do what I need?
Thanks in advance!
Jennifer Downey
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Ok I have the cron job figured out. The only thing I would like help with is
how to update all users in a table.
This just updates a spacific user:
$db["points"]=("UPDATE wt_users set points = points + 1000 WHERE
uid={$session["uid"]}");
$result=mysql_query($db["points"]);
How would I use this t
If anyone knows of one, would someone please point me towards a good
tutorial on storing images in a database then fetching them out again.
I would really appreciate it and thanks in advance!
Jen Downey
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.
harola = "tempimages/". $userfile_name;
>
> // insert path into database here
> # connect to db
> $connectionToDBid = odbc_connect("cdefc5onwesulertt", "joeyscon",
> "joeyscon");
>
> session_register("consultantid");
> $c
Could someone point me in the right direction for joining tables? I have
searched the php manual for it but only found info on joining arrays.
If someone could point me to a code snip or a tutorial I would much
appreciate it.
Thanks in advance
Jen Downey
--
PHP Database Mailing List (http:/
h help :)
>
> JOIN is an SQL command, so check out the manual of your RDBMS (ie.
> http://www.mysql.com/doc/J/O/JOIN.html for MySQL)
>
> good luck :)
>
> Beau
>
> // -Original Message-
> // From: Jennifer Downey [mailto:[EMAIL PROTECTED]]
> // Sent: Thursday, 2
Can someone tell me why I am getting a parse error in this little snip?
Original value is $origVar";
$origVar += 25;
echo "Added a value, now it's $origVar";
$origVar -= 12;
echo "Subtracted a value, now it's $origVar";
$origVar .= " chickens";
echo "Final answer: $origVar";
?>
Thanks in adv
or wasting all your time. I'll try to think better in the future.
Thanks
Jen
"Jennifer Downey" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Can someone tell me why I am getting a parse error in this little snip?
>
>
>
Hi All,
Would someone please help me with the following code?
I am trying to make this work like if I have 15 gold pieces and I deposit 5
it will subtract 5 from the gold pieces I have and deposit the 5 into my
account
showing that I now have 10 gold pieces I can deposit and 5 in the bank.
I wo
n["uid"]}" );
$result=mysql_query($db["bank_points"]);
Thanks in advance
Jennifer Downey
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
l_result <= "0") {
echo "you don't have enough points!";
}else{
echo "Your withdraw has been made!";
}
Thanks in advance
Jennifer Downey
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
ints are at 0 then print no points and quit.
if ($sql_result <= "0") {
echo "you don't have that many points";
exit;
} else {
echo "Your withdraw has been made!";
Thanks again in advance
Jennifer Downey
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
arguments as well (default:
'sendmail -t -i').
;sendmail_path=this is the path to sendmail
<--leave this commented out.
HTH
Jennifer Downey
"Crosswalkcentral" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> any one know h
(id)
) TYPE=MyISAM;
Thanks in advance
Jennifer Downey
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
query($pet);
$query = "select binary_data,filetype from image_data where id=$id";
$result = @mysql_query($query);
I'm using echo ""; to display the image
how do I join the two tables so that the id's match and give the correct image?
And again thanks in advance for your
Ok thanks for that info, but I guess I am ignorant to what MS Access is.
Please enlighten me.
Thanks
Jennifer Downey
"Marius Ursache" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED].;
> the best tool for building "join" queries is MS Access .
>
>
mage?
if($id) {
$id = $pet;
$query = "select bin_data,filetype from image_data where id=$id";
$result = mysql_query($query);
$data = mysql_query($result,0,"bin_data");
$type = mysql_query($result,0,"filetype");
Header( "Content-type: $type");
echo $data;
};
echo "";
Thanks
Jennifer Downey
mysql_fetch_row($ret))
$yearly_interest=$bank_points * $interest;
print("Your yearly interest is : $yearly_interest");
$daily_interest=$yearly_interest / $days;
$round_daily_interest = round($daily_interest);
print("Your daily interest is : $daily_interest");
Thanks
Jennifer Downe
y_interest=$round_yearly / $days;
$round_daily = round($daily_interest);
$query = "UPDATE wt_users set bank_points = bank_points + $round_daily";
$ret = mysql_query($query);
If I use the users session id then it works fine. With the query all I'm doing is
updating ALL users bank_points right? I want to use cron to update all users at
midnight.
Thanks again
Jennifer Downey
Hi all,
Can anyone point me to a good tutorial on how to disable a submit button
once clicked?
preferably in php.
Thanks
Jennifer Downey
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Wondering do I have to have the WHERE clause in a select query?
$b=mysql_query( SELECT * FROM my_table) <-can I use something like this
or do I have to put WHERE in the statement?
Thanks
Jennifer
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net
Hi all,
I have a table called pets, here is a partial dump:
At this time this is all I am working with.
uid int(10) NOT NULL default '0',
num_pet tinyint(1) NOT NULL default '1',
There are three steps to adding the pet into the db
Step 1 create the record, this is in create.php. And yes b
Hi all,
Wondering if anyone might know how to empty a table with a php script and
cron job?
Would someone point me to a tutorial or help with this?
TIA
Jennifer
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hi All!
Hope I'm not bothering you nice people too much.
I have a account called Test, when I click the submit button I get this
error
Unknown column 'Test' in 'field list'
My table only has two fields id and user_name
I am not trying to insert the data into the field Test but into usre_name.
Never mind I forgot to put ' ' around $u_name in my insert.
Jen
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hi all,
Just a simple question (I think).
When should I use tinyint over int. and what is the difference between the
two?
Thanks
Jennifer
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hi all,
I have a table called items here is a dump:
CREATE TABLE items (
id int(10) NOT NULL auto_increment,
name varchar(50) NOT NULL default '',
item_type int(4) NOT NULL default '0',
image varchar(100) NOT NULL default '',
price int(10) NOT NULL default '0',
quantity int(5) NOT NU
Hi all,
If I have a feild called 'date' and the type is date when a form is
submitted isn't it suppose to automatically enter the date or do I need to
somehow enter it through the form?
The reason I ask is that I have another form with a date type and no
reference to it in the form and it is al
Hi all,
I know I've asked this before and wouldn't be asking again if I had the
email that you people replied back with. Windows took a you know what on me
and I had to format the hard drive.
Anyway here is what I have.
This is items.php:
";
echo "$return[name]";
echo "Quantity $return[quanti
> wrote in message
news:[EMAIL PROTECTED]...
> On Friday 05 April 2002 07:55, Jennifer Downey wrote:
> > Hi all,
> >
> > I know I've asked this before and wouldn't be asking again if I had the
> > email that you people replied back with. Windows took a you know
In any case the email or replies are not in the archives. I have searched
them and came up empty.
"Marius Ursache" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>
>
> Jennifer Downey a écrit :
>
> > If you had read
Hi all,
This code is working greate except for one minor bug.
If I have 2 or 3 items at different prices buy.php is updating the points of
the user at the last priced item.
In other words if
item 1 costs 1965
item 2 costs 564
item 3 costs 25
and item 1 is clicked it only takes away 25 points i
Hi all,
Just wondering if something like this is valid. If not how can I make it
valid?
if (mysql_num_rows($result) and (mysql_num_rows($ret) == 0)
Thanks
Jennifer
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.344 / Virus Da
Hi all,
I guess I should have gone ahead and put the whole code in because I didn't
get accomplished what I set out to do in the last if else question.
I found a slight bug and am wondering if someone could help.
If another user logs in and buys the same item as I do then my item is
updated in
I to have about 16 text fields in my db that are NOT NULL and they work
fine.
Just an observation.
Jennifer
"Lisi" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I am trying to create the following table using PHPMyAdmin:
>
> CREATE TABLE IF NOT EXISTS ayny(
Hi all,
You are probably getting tired of me asking questions but I have another and
will try to keep them down from now on.
If I have let's say five items with different id's, image's and so forth how
do I display all items on one page. Do I have to use multiple selects
or is there another easi
about?
> If so, I have the code for it. I wrote the cart that is hosted on that
page
> and can post some code from it if you would like..
>
> Thanks,
>
> Bob Weaver
>
> "Jennifer Downey" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">ne
Hi all,
I had to re-write this so it would at least show something on the page.
$query = "SELECT id, name, image, quantity FROM {$config["prefix"]}_my_items
WHERE uid={$session["uid"]} ORDER BY id";
$ret = mysql_query($query);
$row = mysql_fetch_array($ret);
$id = $row['id'];
$image = $row['ima
Thank you Jason that worked out great!
Jennifer
"Jason Wong" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]...
> On Wednesday 10 April 2002 23:54, Jennifer Downey wrote:
> > Hi all,
> >
> > I had to re-write this so it would at least show
Hi everyone!
Is there a good tutorial on how to write html tables in PHP?
In my last post "Not displaying all records" I have the items displayig all
the contents of the table but they are in descending order.
like this
item 1
item 2
Here is the code I am using
$query = "SELECT id, name, image
Thank you all I managed to get it worked out like this
$name$quantity";
echo "$display_block";
}
echo"";
?>
Jennifer
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.344 / Virus Database: 191 - Release Date: 4/2/2002
--
Hi everyone,
I originally posted this in general by mistake.
I have a question about this code. The way it sits now it always shows the
last record in the database table.
In other words if the user has 6 items, like:
item id 1
item id 2
item id 5
item id 6
item id 7
item id 8
it will only show
efore to do what appears to be similar while loops..
> Wouldn't the data still get retrieved in array form with that? If I'm
wrong,
> feel free to publicly ridicule me..
>
> Later,
>
> Bob Weaver
>
> "Jennifer Downey" <[EMAIL PROTECTED]> wr
s:[EMAIL PROTECTED]...
> on 4/12/02 11:15 PM, Jennifer Downey at [EMAIL PROTECTED] appended the
> following bits to my mbox:
>
> > I believe it has something to do with the first while statement's
closing
> > curly bracket placement
> > but I can't seem to get i
Hi all,
Is there a way to delete a record from a mysql table without fragmenting the
db?
Here is the query I am using and it does a horrible job. Fragment city.
if ($quantity == 0)
{
$gone = mysql_query("D
Hi all,
I'm not sure if my first post showed up so I am going to post it again and I
apologize if it shows up twice.
Is there a way to delete a record from a mysql table without fragmenting the
db?
Here is the query I am using and it does a horrible job. Fragment city.
if ($quantity == 0)
{
Hi all,
Would someone kindly point me to a tutorial on designing a search script for
mysql db.
I have tried to build one but can't get anywhere with it.
Thanks
Jennifer
--
The sleeper has awaken
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.co
This is basically what I am trying to do
if($search)
{
$query = "SELECT uid, id, image, iname, quantity, type FROM
{$config["prefix"]}_shop WHERE iname = $shopsearch";
$ret = mysql_query($query);
while(list($quantity)=mysql_fetch_row($ret))
$name = $row['user'];
echo $name;
}else{
By the way SELECT uid, id, image, iname, quantity, type, user where it shows
below that user isn't in the query- it is there in my editor.
I just forgot to put it in before sending.
Jennifer
"Jennifer Downey" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">new
Hi all,
I have been trying to build a search script for my site that deals with only
one table in my db.
As Julie Meloni pointed out look in the MySQL manual for LIKE clauses I
can't seem to locate that clause in ether
manual.
Dan Brunner gave me this to go on:
$query = "SELECT uid, id, image, i
EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> The query should read as below, without the = after the LIKE:
>
> $query = "SELECT uid, id, image, iname, quantity, type FROM
> {$config["prefix"]}_shop WHERE iname LIKE '
#x27;quantity'];
$type = $row['type'];
$price = $row['price'];
}
if($searchword == $iname)
{
echo "";
echo "$user";
echo "$iname";
echo "$q";
echo "$price";
echo "";
}
}else{
echo "";
echo &q
'ABC';
> -> 1
> mysql> SELECT 'abc' LIKE BINARY 'ABC';
> -> 0
>
> I am not sure why it is showing case sensitivity, unless as it states, one
of
> the operands is a binary string.
>
> HTH
>
> Maureen
>
> Jen
want it to.
What I needed to do is have it where it isn't == to anything in otherwords a
null value.
So if $searchword = $iname then it will work as it is suppose to.
Thanks everyone for your time, effort and help.
Jennifer
"Jennifer Downey" <[EMAIL PROTECTED]> wrote i
As many people have told me and I have just now got it through my thick head
try either echoing the query or use
$result = mysql_query($sql) or die(mysql_error());
You will find out what is being passed (or not passed) through your
variables or find out what error you are getting.
HTH
Jennife
do a search for something in upper case that is in the database in
> lower case. If this works, then it looks like the situation above. I
think
> previously, you were searching using all lower case for a word that was in
> the database with an upper case letter in it.
>
> HTH
&
Hi all,
I am wondering how to keep something from beind displayed if a price is set
to 0?
I have a store where the user looks up items, but it shows all items even if
the price is 0. Is there a way to prevent the items set at 0 from being
displayed?
Thanks
Jennifer
--
The sleeper has awaken
15C0A1D311BF0D0004AC4C4B0C024AC071@SSIMSEXCHNG...
> Are you looking it up in a database? If so you'd want to do something
like
> where price > 0. Then it wouldn't return those results.
>
> -Natalie
>
> -Original Message-
> From: Jennifer Downey [mailto:[E
Hi all,
It's Monday, it's probably something stupid, but I have poured over this all
day and cannot find the problem.
This is a simple search engine based on one table. It is suppose to return
the results of the search word. Instead it returns ALL records in the mysql
table. If I type the letter
include 'phpstudy/constant.inc';
$link=mysql_pconnect(HOST,USER,PASSWD);
mysql_select_db(DBNAME,$link) or die(mysql_error());
This will give you the errors if any.
HTH
Jennifer
"Jack" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Dear all
> I had a problem
I don't know if this is what you are looking for but it will open a new
browser window. You may have to play with it to get it the way you want.
Your Link
HTH
Jennifer
"Bob Parker" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I'm working on an intranet ac
Thanks all for your help.
I knew it was somathing stupid and I knew it was because it was Monday.
Now that it is Tues I have found the problem and it was somethin very
stupid.
I forgot
echo "";
Now it work as it should.
Again thanks
Jennifer.
"Jennifer Downey" <[EMA
Hi all,
Wondering if you could help or point me to a tut where I can use a link to
get the next record in the db?
Like Previous recordNext record
How do I go about doing this.
Thanks
Jennifer
--
The sleeper has awaken
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus sys
uery something like
>
> SELECT * FROM table LIMIT $record, 1
>
> rather than
>
> SELECT * FROM table WHERE id='$record'
>
> Since that takes them in whatever order, but only SELECTs from $record and
> gets 1 record.
>
> HTH
>
> Beau
>
>
&g
This line sets $row["rv_space"]
echo"Search Record by Space Number ";
"Beau Lebens" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> How are you setting the value for $row["rv_space"] ?
>
> /
71 matches
Mail list logo