Try the Demo

Magento Forum

   
Cookie related…
 
streek
Jr. Member
 
Total Posts:  9
Joined:  2008-07-13
 

I need one of two things.

1) Make a cookie so I can call it from another page on the same domain not used by magento so I can list how many items in your cart… I have no idea where to place any code or anything.

2) Use the current cookie, make it’s sub-domain / instead of /magento AND find out how to read it’s gibberish in the value field.

all I need is to be able to display the cart total on my homepage not just in the magento cart.

Much thanks.

 
Magento Community Magento Community
Magento Community
Magento Community
 
streek
Jr. Member
 
Total Posts:  9
Joined:  2008-07-13
 

I’m guessing no one knows magento here?

 
Magento Community Magento Community
Magento Community
Magento Community
 
alistek
Sr. Member
 
Total Posts:  293
Joined:  2008-04-02
Normal, IL
 

You will have to include the Mage.php file and initialize the stack and then I believe you can access the current data via the registry objects.

-Adam

 
Magento Community Magento Community
Magento Community
Magento Community
 
streek
Jr. Member
 
Total Posts:  9
Joined:  2008-07-13
 

I’m new to Magento so im not sure how it works or it’s structure yet… can you be more specific?  I believe this should be a simple task… but it seems to not be.

 
Magento Community Magento Community
Magento Community
Magento Community
 
streek
Jr. Member
 
Total Posts:  9
Joined:  2008-07-13
 

Could use some help, still can’t find anything out on this.

 
Magento Community Magento Community
Magento Community
Magento Community
 
streek
Jr. Member
 
Total Posts:  9
Joined:  2008-07-13
 

Figured it out.

 
Magento Community Magento Community
Magento Community
Magento Community
 
vianetz
Guru
 
Avatar
Total Posts:  537
Joined:  2008-04-13
Munich, Germany
 

Just FYI, perhaps somebody finds it useful:
I created a module and wanted to store a cookie via the internal core/cookie->set method. The big problem was my development environment because ithe magento machine hadn’t a fully qualified domain name but a name like “vns07”. The PHP setcookie() method needs at minimum two depths of a domain name, e.g. example.com otherwise the domain parameter will be ignored.
And this was the reason why the cookie couldn’t be read from other sites in my case..

HTH

 Signature 

vianetz.com - Magento Development
Customizable layouts for invoices? Check out Advanced Invoice Layout For Magento.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top