Page 1 of 2 12 LastLast
Results 1 to 10 of 15
  1. #1
    Join Date
    Sep 2010
    Posts
    263
    Plugin Contributions
    0

    red flag Trying to add extra data to look up from shipping module

    Does anyone know what PHP file adds the items to the shopping cart ?
    Thanks,
    007

  2. #2
    Join Date
    Jun 2003
    Posts
    33,715
    Plugin Contributions
    0

    Default Re: What PHP file adds the items to the shopping cart ?

    What are you wanting to do?
    Please do not PM for support issues: a private solution doesn't benefit the community.

    Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

  3. #3
    Join Date
    Sep 2010
    Posts
    263
    Plugin Contributions
    0

    red flag Re: What PHP file adds the items to the shopping cart ?

    I want to see how the items are added to the shopping cart in PHP. I want to add extra data. i.e. manufacturers_id so I can access it in the shipping module and then look up the manufacturers table using it as the key.
    Thanks,
    007

  4. #4
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    10,303
    Plugin Contributions
    125

    Default Re: What PHP file adds the items to the shopping cart ?

    You can look up a product's manufacturer's id in your shipping module - no need to change the add to cart behavior. The function zen_get_products_manufacturers_id($prid) will get the manufacturer for product id $prid.
    That Software Guy. My Store: Zen Cart Support
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  5. #5
    Join Date
    Sep 2010
    Posts
    263
    Plugin Contributions
    0

    red flag Re: What PHP file adds the items to the shopping cart ?

    Hey that function zen_get_products_manufacturers_id($prid) to get the manufacturer for product id $prid actually worked.

    Thanks for that. One more step along the long and winding road.

    Having solved that problem, I now want to be able to query the manufacturers table using that manufacturers_id as the key.

    I need a custom query to do this, as I have added an extra field called Man_PostCode in the manufacturers table that I want to extract into a variable. Thus I don't think any standard function will exist to extract that. Any ideas on how to do that ?

    Thanks.
    Thanks,
    007

  6. #6
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    10,303
    Plugin Contributions
    125

    Default Re: What PHP file adds the items to the shopping cart ?

    The directory includes/functions/extra_functions exists so you can add custom functions like the one you're describing. Use the function I pointed you to as a model for your new function.
    That Software Guy. My Store: Zen Cart Support
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  7. #7
    Join Date
    Sep 2010
    Posts
    263
    Plugin Contributions
    0

    red flag Re: What PHP file adds the items to the shopping cart ?

    OK Thanks. I will give it a try.
    Thanks,
    007

  8. #8
    Join Date
    Sep 2010
    Posts
    263
    Plugin Contributions
    0

    red flag Re: What PHP file adds the items to the shopping cart ?

    I don't really know PHP very well. So what PHP file name do I put this extra function in and how do I inlcude it to be called from the shipping module ?

    i.e. in directory includes/functions/extra_functions
    Thanks,
    007

  9. #9
    Join Date
    Sep 2010
    Posts
    263
    Plugin Contributions
    0

    red flag Re: What PHP file adds the items to the shopping cart ?

    I've got it working, but in the main functions module until I can work out how to apply it in the extra_functions directory. Apart from that, its working.
    Thanks,
    007

  10. #10
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: What PHP file adds the items to the shopping cart ?

    The filename for files in the /extra_functions/ folder is irrelevant; it only serves to be able to locate the right file if you want to edit it. All files there are autoloaded.

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. v150 USPS shipping module...trying to restrict shipping options programmatically
    By ecclescake in forum Addon Shipping Modules
    Replies: 11
    Last Post: 13 Dec 2024, 05:24 AM
  2. v154 Look for help about ajax paging to display extra data
    By sfgl in forum General Questions
    Replies: 5
    Last Post: 26 Apr 2016, 04:11 PM
  3. migrating from ShopSite, trying to copy product data.....
    By tcarden in forum General Questions
    Replies: 1
    Last Post: 10 Sep 2013, 10:12 AM
  4. Replies: 0
    Last Post: 28 Jan 2011, 12:44 PM
  5. Trying to add left navigation bar/ match ZenCart to the look of my site
    By NavPublishing in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 28 Oct 2008, 09:08 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR