Results 1 to 3 of 3

Thread: GoogleCheckout form start-date (need 14 days into future)

  1. #1
    Join Date
    May 2007
    Thanked 0 Times in 0 Posts

    Question GoogleCheckout form start-date (need 14 days into future)

    What I'm trying to accomplish is not to start the first payment on a subscription until 14 days after they process.
    This is for a free trial. How do I format the start-date to be 14 days into the future.
    I have read for hours and hours... and hours. Please help.
    It's on the 8th line at the end.
    I know it's possible but I just don't know how to format it.

    <form method="POST" action="" accept-charset="utf-8">
    <input type="hidden" name="shopping-cart.items.item-1.item-name" value="5lbs Baked Goods"/>
    <input type="hidden" name="shopping-cart.items.item-1.item-description" value="TBD"/>
    <input type="hidden" name="shopping-cart.items.item-1.unit-price.currency" value="USD"/>
    <input type="hidden" name="shopping-cart.items.item-1.unit-price" value="30.00"/>
    <input type="hidden" name="shopping-cart.items.item-1.quantity" value="1"/>
    <input type="hidden" name="shopping-cart.items.item-1.subscription.type" value="google"/>
    <input type="hidden" name="shopping-cart.items.item-1.subscription.period" value="MONTHLY" start-date="2012-04-01T07:55:55.952-08:00">
    <input type="hidden" name="shopping-cart.items.item-1.subscription.payments.subscription-payment-1.times" value="12">
    <input type="hidden" name="shopping-cart.items.item-1.subscription.payments.subscription-payment-1.maximum-charge" value="30.00">
    <input type="hidden" name="shopping-cart.items.item-1.subscription.payments.subscription-payment-1.maximum-charge.currency" value="USD">
    <input type="hidden" name="shopping-cart.items.item-1.subscription.recurrent-item.item-name" value="Recurring Baked Goods">
    <input type="hidden" name="shopping-cart.items.item-1.subscription.recurrent-item.item-description" value="Item Description TBD">
    <input type="hidden" name="shopping-cart.items.item-1.subscription.recurrent-item.quantity" value="1">
    <input type="hidden" name="shopping-cart.items.item-1.subscription.recurrent-item.unit-price" value="0">
    <input type="hidden" name="shopping-cart.items.item-1.subscription.recurrent-item.unit-price.currency" value="USD">
    <input type="hidden" name="" value="OPTIMISTIC">
    <input type="hidden" name="" value="OPTIMISTIC">
    <input type="hidden" name="" value="">
    <input type="hidden" name="" value="Filler text">
    <input type="hidden" name="" value="Thank you!">
    <input type="hidden" name="_charset_"/>
    <input type="image" name="Google Checkout" alt="" src="" height="46" width="180"/>
    Last edited by nycguurl; 04-17-2013 at 12:52 AM.

  2. #2
    Join Date
    Jul 2008
    Derbyshire, UK
    Thanked 599 Times in 575 Posts
    Blog Entries


    I've never used Google checkout but for a 'normal' form there would be 2 ways to tackle it.

    The first is to manipulate the start date during form generation/page load. I don't know how the form is generated though or how the start date is being inserted into the form markup. Is the form html hard coded on the page by you and does the form use php or some other server side language to echo the current date into the start date attribute? If so, you could add 14 days to the current date and then echo the revised date into the form. Here are some examples of adding days to the current date: and
    This idea could cause skewed results though because in theory a person could have the form open for a few days before submitting it which would cause the initially loaded start date to be 'out'. Its unlikely that anyone would have a page open that long but it might cause problems if somebody was completing a longer form past midnight. That's why it's better to process the date from the time of form submission and do it via the server. Which leads to option two...

    The second way would be to manipulate the start date on form submission. I think this would be harder as you'd need access to the processing scripts, which I don't think is possible as this is handled by a 3rd party.

    I think the first option sounds more plausible but it depends how much control you have over the form and if you can envisage too many problems with a potential time difference between page load and form submission. Like I said, I've never used Google checkout.
    Last edited by Beverleyh; 04-17-2013 at 05:40 AM.
    Focus on Function Web Design
    Fast Edit (A flat file, PHP web page editor & CMS. Small, FREE, no database!) | Fast Edit BE (Snippet Manager) (Web content editor for multiple editable regions!) | Fast Apps

  3. The Following User Says Thank You to Beverleyh For This Useful Post:

    nycguurl (05-07-2013)

  4. #3
    Join Date
    May 2007
    Thanked 0 Times in 0 Posts


    Hi Beverley, I forgot to come back and say thank you.

Similar Threads

  1. strtotime, too future date?
    By city_coder in forum PHP
    Replies: 7
    Last Post: 09-10-2008, 03:22 PM
  2. Setting A Future Date
    By Titan85 in forum PHP
    Replies: 2
    Last Post: 07-17-2007, 02:16 PM
  3. Add Days to a date
    By fastrobby in forum JavaScript
    Replies: 0
    Last Post: 07-10-2007, 10:33 PM
  4. to introduce future date in an edit
    By stephen64_14 in forum PHP
    Replies: 0
    Last Post: 02-06-2007, 05:42 PM
  5. Adding days to a date
    By johnnyi in forum JavaScript
    Replies: 1
    Last Post: 07-22-2005, 03:29 PM


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts