nders of open source.
Are sessions required for a shopping basket? I don't want people to login,
just order and go.
"Matt Stewart" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> i'd imagine there'll be a decent on
at
seemed to do the trick.
Any help on php shopping carts would be great!
Thanks
"Matt Stewart" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> sent the session_start(); before any output, that should do it...
>
> -Original Me
sent the session_start(); before any output, that should do it...
-Original Message-
From: James Kupernik [mailto:[EMAIL PROTECTED]]
Sent: 23 May 2002 15:38
To: [EMAIL PROTECTED]
Subject: [PHP-DB] sessions
I get this error when I try to start a session (I'm trying to create a
shopping c
at first glance i'd assume that the variable $category is not being passed
through to the second page - you're using it to get the first query, but not
keeping it (either in the url or hiddenform variable for your next page
link).
-Original Message-
From: Natividad Castro [mailto:[EMAIL P
bit cynical maybe craig???
i think he actually made an honest mistake and is trying to rectify the
situation...
don't think there's any harm done, just a couple more emails to delete from
the inbox!
-Original Message-
From: Craig Vincent [mailto:[EMAIL PROTECTED]]
Sent: 16 May 2002 11:51
DON'T!!
this file is on everyones machine, and is not a virus!!
-Original Message-
From: Trond Erling Hundal [mailto:[EMAIL PROTECTED]]
Sent: 16 May 2002 10:26
To: ,; -=* Alf Marius *=-; Abonnement; Alf Halsen; Alf Lange De;
Amajonaz . . .; Andreas Nordenstam; Andrey Hristov; 'And
N_VARS['sess_address']=$address;
see if that makes any difference?
-Original Message-
From: Terry Romine [mailto:[EMAIL PROTECTED]]
Sent: 15 May 2002 16:40
To: matt stewart
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP-DB] session variables across several pages
This is freaky.
You need to look up $HTTP_SESSION_VARS['name'] - that's how to change the
variables when they are already set..
i think most people have this problem when they first use sessions!
-Original Message-
From: Terry Romine [mailto:[EMAIL PROTECTED]]
Sent: 15 May 2002 15:49
To: [EMAIL PROT
tion_Membership WHERE organisation LIKE
'%$SearchBox'";
if this is the wrong anser, and you were trying to do something different,
let me know!
Matt Stewart
[EMAIL PROTECTED]
-Original Message-
From: Robin S McKenzie [mailto:[EMAIL PROTECTED]]
Sent: 02 May 2002 15:11
To:
can you post some code, and an exmaple of an input, the current output, and
what the desired output would be?
-Original Message-
From: jas [mailto:[EMAIL PROTECTED]]
Sent: 22 March 2002 04:57
To: [EMAIL PROTECTED]
Subject: [PHP-DB] calculations based on checkbox value
Ok here is my prob
you can't pass a literal "&" in a url - it makes it think that it's the next
variable.
-Original Message-
From: its me [mailto:[EMAIL PROTECTED]]
Sent: 14 March 2002 11:21
To: [EMAIL PROTECTED]
Subject: [PHP-DB] need help guys
i have this
Antiques & Arts
then i pass this to next page:
Not entirely sure what you're trying to do, but would it be sensible to
use...
$sql="SELECT * FROM Customers ORDER BY zip ASC";
.
.
and then when you've got the results...
if ($myrow = mysql_fetch_array($result)) {
$zip=0;
$zipcount=0;
do {
if ($zip!=$myrow[
either
if (($var <= 3)&&($var >= 1)){
}
if you want it to just be somewhere between one and 3,
or
$my_array = array ("1", "2", "3");
if (in_array($variable, $my_array)) {
}
if you want it to be just one of those exact values.
-Original Message-
From: Dave Carrera [mailto:[EMAIL
yeah, i would go with Rick on this.
however, the reason i think it's not working is because it's comparing the
contents alphabetically ie. "2" is greater than "1" but is also greater than
"10", "19" etc etc alphabetically, just as anything beginning with "b"
is greater than "a" and also "aazzx
Forgot to post to the whole list! sorry
-Original Message-
From: matt stewart
Sent: 01 February 2002 09:22
To: 'Jose Maria Sala'
Subject: RE: [PHP-DB] renaming uploaded files
Hi Jose - this has a bit of error checking with it too.
this just uploads one file with the na
Agreed, i think you'll find aan easy way of doing this is to name each image
after the primary key to your table (ie 1.jpg, 2.jpg, 3.jpg etc if the
primary key is an autonumber. and store them all in a certain file, then
when you fetch the record from the table, you can run a simple check to see
i
by the way, what are you actually trying to do with the code? there may be a
different way of doing it which isn't so confusing?
-Original Message-
From: tomhilton [mailto:[EMAIL PROTECTED]]
Sent: 17 January 2002 15:20
To: [EMAIL PROTECTED]
Subject: [PHP-DB] string compare function
Hi,
take it you've tried having exactly the same value for each to test if the
return is 0?
it shouldn't be comparing literals, but it looks like it could well be!
try putting "" round the variables, and various things like that?
-Original Message-
From: tomhilton [mailto:[EMAIL PROTECTED]]
post the entire line of code, (and the surrounding couple of lines??
and we'll get more of an idea.
-Original Message-
From: tomhilton [mailto:[EMAIL PROTECTED]]
Sent: 17 January 2002 14:56
To: [EMAIL PROTECTED]
Subject: [PHP-DB] string compare function
Hi, I'm having a problem with the
It's not anything to do with the special regular expression characters again
is it?
-Original Message-
From: Beau Lebens [mailto:[EMAIL PROTECTED]]
Sent: 17 January 2002 01:38
To: 'Markus Lervik'; [EMAIL PROTECTED]
Subject: RE: [PHP-DB] What is REG_BADRPT, and why do I get it?
on a gue
finished University nearly two years ago, but back then, this book was the
one we used too - very in depth introduction to general database theory,
well worth investing in if you need very well designed databases for large
volume applications.
all the best,
Matt
-Original Message-
From:
P-DB] Replacing * with %
The following works fine for me:
$currentword = ereg_replace("\*","%",$currentword);
Chris
}:)
> -----Original Message-
> From: matt stewart [SMTP:[EMAIL PROTECTED]]
> Sent: Tuesday, January 15, 2002 9:57 AM
> To: [EMAIL PROTECTED
just checked it out, and * is a special character unless enclosed in class
brackets.
so using "[*]" should hopefully work!
give it a go and see.
cheers,
Matt
-Original Message-----
From: matt stewart [mailto:[EMAIL PROTECTED]]
Sent: 15 January 2002 09:54
To: [EMAIL PROTECTED]
S
/* sorry markus, forgot to post this to the list, so here it is again! */
don't know if this is the solution without doing some reading, so i'll tell
you what i think it might be and you can read up on it!
is either (or both?) * and % special characters in regular expressions? if
so, it may be p
straight after you do the insert command, use the call:
$ID = mysql_insert_id();
The $ID is now the primary key for the record you just inserted.
-Original Message-
From: George Pitcher [mailto:[EMAIL PROTECTED]]
Sent: 14 January 2002 14:56
To: Ireneusz Piasecki; [EMAIL PROTECTED]
Subje
yep, it returns 20.
-Original Message-
From: DL Neil [mailto:[EMAIL PROTECTED]]
Sent: 14 January 2002 14:17
To: matt stewart; [EMAIL PROTECTED]
Subject: Re: [PHP-DB] RE: LIMIT and get_num_rows
Have you (original post-er) tested performing a SELECT ... LIMIT 0, 20 and
then calling
you've assumed correctly - so it's definitely faster to do the two queries?
okey dokey, then that's the method i shall use.
thanks to everyone who's added their thoughts!
-Original Message-
From: Peter Westergaard [mailto:[EMAIL PROTECTED]]
Sent: 14 January 2002 14:01
To: [EMAIL PROTECTED
g a get_num_rows and then only using the first 20?
-Original Message-
From: Jonatan Bagge [mailto:[EMAIL PROTECTED]]
Sent: 14 January 2002 11:00
To: matt stewart
Subject: Re: [PHP-DB] LIMIT and get_num_rows
First do a SELECT count(*) from tablename;
This will get the number of entries.
hi guys, just looking for verification on this, as i don't think there's any
way to do it
Basically, i want to return the results for a search, but only return the
first 20 results from the start number given
LIMIT $start, 20
BUT... i'd like to have a page 1-whatever so if there are 65 re
shouldn't it be PASSWORD('madonna') ??
-Original Message-
From: Necro [mailto:[EMAIL PROTECTED]]
Sent: 11 January 2002 04:39
To: [EMAIL PROTECTED]
Subject: RE: [PHP-DB] MySQL Result Resource
http://www.hotscripts.com/Detailed/4219.html <<--- that is the script
But I cannot use crypt()
not tried it, but according to the manual, it should be something like..
SELECT * FROM Bands WHERE Name REGEXP "^[0-9]";
check out the relevant page and see what you think:
http://www.mysql.com/doc/S/t/String_comparison_functions.html
regards,
Matt
-Original Message-
From: Barry Rums
don't know if this makes a difference, but i've always used WHERE bookid =
'$bookid'"; - single quote round the $bookid variable - not sure if that's
the problem, or if it's just good practice?
-Original Message-
From: Ford, Mike [LSS] [mailto:[EMAIL PROTECTED]]
Sent: 08 January 2002 14:0
well, i'm sure there are lots out there, but i am very happy with...
"PHP and MySQL Web Development" By Luke Welling and Laura Thomson, published
by SAMS
First printed in March 2001, so it's still not out of date.
there are probably lots of other good books out there too though.
-Original Me
without code it's hard to know, but i'd have thought a simple html tag
around the entry should work.
ie...
printf "%s",$myrow[Lyrics];
-Original Message-
From: Barry Rumsey [mailto:[EMAIL PROTECTED]]
Sent: 07 January 2002 12:20
To: [EMAIL PROTECTED]
Subject: [PHP-DB] Formated Results
H
No! don't get them started again! my inbox won't take it
any more.
-Original Message-
From: Boaz Yahav [mailto:[EMAIL PROTECTED]]
Sent: 05 January 2002 08:07
To: Bogdan Stancescu; Jonathan Hilgeman
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP-DB] Fixed Quote Marks in Inputs
I jus
e admin.php url
in the browser and they get admin access even if they are not admins.
Fred
Matt Stewart <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Can't find the right instructions on php.net, basically, i want a page
where
> so
Can't find the right instructions on php.net, basically, i want a page where
someone logs in, and then according to the database entry for them, either
they are an admin user or a normal user, and it should then send them to a
page depending on which they are.
I've accessed the db ok, and checked
the value doesn't determine whether it's checked or not - it determines the
value passed WHEN it's checked.
try the lines below:
echo"";
}else{
echo">";
}
or something along these lines.
-Original Message-
From: SpyProductions Support Team [mailto:[EMAIL PROTECTED]]
Sent: 20 Decem
good point well made.
this system has pretty much everything we need - thanks!
-Original Message-
From: Ryan Marrs [mailto:[EMAIL PROTECTED]]
Sent: 20 December 2001 16:17
To: 'Zach Curtis'; matt stewart
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP-DB] Decrypting PASSWORD() from
I would go for the "generate new random password" approach - email the new
random password to the registered email address, then they can log in using
it and reset it to whatever they want. probably easier than using lots of
code encrypting and decrypting things?
Let me know what you decide on, an
and i always thought the best tactic was to go ugly early.
seriously, this isn't really that ugly a solution, most textbooks tend to
tell you to use this method to start with as its a bit simpler to understand
for beginners - an if...else statement to see if an initial row is returned,
then you c
yep, that's basically what i use for this sort of thing - it's a nice short
simple function, and works a treat. Obviously if you'd rather be passing the
actual colour name to the next step, you use printf("%s", $myrow["colorname"], $myrow["colorname"]);
I also prefer to use printf(" so it has the
the way to start this is to just add a couple of letters to the message and
see if you're still getting an error -
try (on line 357)...
$message .=">no\nHello world";
keep it all on one line, and then see if you're still getting an error - if
you are then i don't think this line is the one you h
you're only printing stuff while i=0, i=1,i=6.
therefore only 7 things come out.
either make the loop for($i=0;$i<=7;$i++), or for($i=0;$i<8;$i++).
-Original Message-
From: +markus lervik [mailto:[EMAIL PROTECTED]]
Sent: 13 December 2001 09:37
To: php-db
Subject: [PHP-DB] Problem with
we could even give an "i love linux" t-shirt to the winner of the contest!
-Original Message-
From: Daniel Barton [mailto:[EMAIL PROTECTED]]
Sent: 03 December 2001 17:00
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: Re: [PHP-DB] WAS: Use php to plot graph. NOW: ASCII GRAPH
CONTEST
yes, it is possible - read up on the .PNG image format, as it is possible to
create graphs ind images dynamically to suit the data and figures youve
extracted from the database
-Original Message-
From: Denny Ow [mailto:[EMAIL PROTECTED]]
Sent: 03 December 2001 16:14
To: [EMAIL PROTECTED]
$last_add = mysql_insert_id();
- thanks to Bruno Gimenes Pereti who answered this very same question when i
asked it a couple of weeks ago ;)
all the best,
Matt
-Original Message-
From: LeTortorec, Jean-Louis [mailto:[EMAIL PROTECTED]]
Sent: 26 November 2001 22:22
To: '[EMAIL PROTECTE
never tried this before, but do you need some single quote's around the
whole "(select user_id.)"?
then of course there'd need to be some escape character for the single
quotes in the "user_name = 'herbert01'" bit...
let me know if that is the problem, as this is just a guess!
cheers,
Matt
i'd advise not using something like ultradev until you can write some nice
little scripts in notepad! it's always easier to debug if you start learning
the code properly, then move onto something like ultradev just to speed it
up a bit when you're competent.
firstly, the actual extraction of code
always make sure you restrict what can be uploaded though! only allow file
extensions that you know are safe! otherwise people might do nasty things to
your server!
-Original Message-
From: Jonathan Hilgeman [mailto:[EMAIL PROTECTED]]
Sent: 16 November 2001 16:29
To: 'Lilian Salazar'; [EM
put them into an array
$date_stuff[0] = $date_year;
$date_stuff[1] = $date_month;
$date_stuff[2] = "01";
$date_to_enter = join('-',$date_stuff);
then whack $date_to_enter into your database - obviously if the input to
$date_month is "
VALUES(NULL,"Bread",1,"each",1.49);
INSERT INTO styles VALUES( "White",LAST_INSERT_ID() );
INSERT INTO styles VALUES( "Black",LAST_INSERT_ID() );
INSERT INTO styles VALUES( "Wheat",LAST_INSERT_ID() );
INSERT INTO styles VALUES( "Hawaiian",LAST_INS
class
$name
$type
ACTIVE SIM\n";
}
};
}
"Matt Stewart" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> if you post a bit of the offending code then i'll have a look
not really sure how to do this, other than planning for as much as you can
in your original tables, then have a spare table with four columns - Row_ID,
Characteristic_Name, Characteristic_Value, and Product_Refer_ID.
so then if you get a new characteristic (eg colour) then you could have
values 1,
if you post a bit of the offending code then i'll have a look - sounds
strange though
-Original Message-
From: Kevin Schaaps [mailto:[EMAIL PROTECTED]]
Sent: 16 November 2001 11:44
To: [EMAIL PROTECTED]
Subject: [PHP-DB] PHP results bold in HTML
Hi everyone,
I've noticed something stra
27;t mySQL 4 therefore be slower?
-Original Message-
From: Lars B. Jensen [mailto:[EMAIL PROTECTED]]
Sent: 15 November 2001 12:19
To: matt stewart
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP-DB] Why use MySQL with PHP
Stored procedures is missing in mySQL correct but is scheduled with the
exit
The main reasons are possibly later on its drawbacks - basically, its main
attraction is the ease of use, as it's so simple!
MySQL and PHP fit together so well and for people just learning scripting
with databases, there's not much that's as easy to pick up quickly and
produce basic database drive
That sounds the likely answer to me too - you don't generally try to send a
parameter to something you're including.
if you're just trying to go to that page after executing some code, do a
print "Location:yadayadayada...?id=KnChooseBoots"
-Original Message-
From: Bruno Gimenes Pereti [ma
think the most likely is there is not a temporary upload directory set in
PHP on your server?
I'd check the relevant PHP settings first, also check the final destination
folder has relevant write permissions.
-Original Message-
From: Ivo [mailto:[EMAIL PROTECTED]]
Sent: 09 November 2001 1
wboys (American Football team) and
Manchester United (Funny Football team), the win goes to the Cowboys.
yee...haaa...
-Original Message-
From: Russ Michell [mailto:[EMAIL PROTECTED]]
Sent: Friday, November 09, 2001 8:27 AM
To: matt stewart
Cc: [EMAIL PROTECTED]
Subject: Re: RE: [P
Was that line in the movie? If so, wisely said.
-Original Message-----
From: matt stewart [mailto:[EMAIL PROTECTED]]
Sent: Friday, November 09, 2001 8:22 AM
To: 'Rick Emery'; [EMAIL PROTECTED]
Subject: RE: [PHP-DB] inserting array into mySQL
>>As we say here in Dallas: the
>>As we say here in Dallas: there are two kinds of people...those who live
in Texas...and those who wish they did.
Full Metal Jacket? ;)
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.295 / Virus Database: 159 - Release Date: 0
don't you need it to be SELECT login, password...
lowercase first letter? - if you're comparing the columns user.login and
user.password.
-Original Message-
From: DL Neil [mailto:[EMAIL PROTECTED]]
Sent: 09 November 2001 01:34
To: MPropre
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP-DB] No
What i'm after is getting the primary key for a record that's just been
added - I have an image file upload accompanying a database addition, and
the image gets renamed $unique_ID.jpeg
only problem is that the current method inserts the information, which auto
produces the primary key, but the onl
64 matches
Mail list logo