How to use looping in this case for a newbie

Discussion in 'PHP' started by theITvideos, Aug 29, 2010.

  1. #1
    Hi there,

    This is my first time post on digitalpoint. And this seems to be a great place. :)

    Now I am working on the product shipping module.

    The scenario is that when a customer selects a product for purchase, the shipping charges is calculated based on the 'shipping charges' specified in the 'shipping profile' which is set by the product's supplier while listing the product.

    Now I need to somehow see what countries are under those shipping profiles as shown in the screenshots attached.

    I am just maybe new on how to use looping in this scenario.

    Note: I have all the info including product id, countries and shipping charges in the variables.

    But Just need to somehow use proper Looping through the list of shipping profiles attached to a product to see what country the product has shipping charges from.

    Please see the screenshots.

    Your feedback/comments is always welcomed.

    Thank you!
     

    Attached Files:

    theITvideos, Aug 29, 2010 IP
  2. xcool101Man

    xcool101Man Guest

    Messages:
    48
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Here is how you use looping in php

    for ( $counter = 10; $counter <= 100; $counter += 1) {
    //do whatever you wish here
    }
     
    xcool101Man, Aug 30, 2010 IP