Re: Quick Q about php.
| From: | Ben-Nes Michael | Date: | Thu, 25 May 2000 13:15:53 +0000 |
| Subject: | Re: Quick Q about php. | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-541@lists.php.net to get a copy of this message | ||
Hi & Thanks for the help.
i made session_register("session");
I want a class that will get item & quantity and will do what ever it need
against the database and then will put the variables in
$session[basket][name].
The problem is that I couldn't find any way to work against the session
variables within the class, what ever I tried in the last few day didn't
helped me :-(
I will happy to see example of class the accept one variable (lets say
"hello") and within its function it will register the "hello" to the current
user session.
Christopher Thompson wrote:
> I am also a Minivend user and have begun building sites using PHP because
> I also am tired of struggling with Minvend. There are a number of existing
> PHP shopping carts that you can use, unfortunately the mostly use PHP3 and
> PHPLIB. I am building my own system (taking the good ideas from Minivend)
> in PHP.
>
> You should be able to save an object in a session, but you probably would
> not do it in the Cart object. Instead, you would "new" a Cart object and
> then register it with the session.
>
> > -----Original Message-----
> > From: Ben-Nes Michael [mailto:miki@canaan.co.il]
> > Sent: Wednesday, May 24, 2000 10:28 AM
> > To: PHP-General
> > Subject: [PHP-GENERAL] Quick Q about php.
> >
> >
> > Hi
> >
> > Im building an commerce site using php after i had enough of the minived
> > stuff.
> > Now i want to adapt the using of class and sessions in the current task.
> >
> > I read the manuals, and few tutorials about classes and then:
> >
> > I copied the cart example in the php manual
> > http://www.php.net/manual/html/oop.html
> > The problem is that I don't know how to keep the items in the carts when
> > browsing to the next page.
> > I couldn't force the class function to register the items in a session.
> > Now what good is the cart example if it wont keep the information from
> > page to page ?
> >
> > Im sure there is the "right way" of doing such things.
> > Thanks in advance.
> >
> > --
> > --------------------------
> > Canaan Surfing Ltd.
> > Internet Service Providers
> > Ben-Nes Michael - Manager
> > Tel: 972-6-6925757
> > Fax: 972-6-6925858
> > http://www.canaan.co.il
> > --------------------------
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> > For additional commands, e-mail: php-general-help@lists.php.net
> > To contact the list administrators, e-mail: php-list-admin@lists.php.net
> >
> >
--
--------------------------
Canaan Surfing Ltd.
Internet Service Providers
Ben-Nes Michael - Manager
Tel: 972-6-6925757
Fax: 972-6-6925858
http://www.canaan.co.il
--------------------------