Full service web hosting, great prices and support. Starts at $1.99/month!
Results 1 to 6 of 6

Thread: Address Format and Address Line 2

  1. #1
    osCMax Development Team

    Address Format and Address Line 2

    ridexbuilder's Avatar
    Join Date
    Jul 2008
    Location
    Haggisland
    Posts
    4,164
    Contribute If you enjoy reading the
    content here, click the below
    image to support our site.
    Click Here To Contribute To Our Site

    Total Contributions For

    ridexbuilder     $ 15.00
    Rep Power
    99


    Angry Address Format and Address Line 2

    Rant warning!!!

    Background.
    I've been putting together a 2.5 RC1 (well, SVN 1502 actually) development site in conjunction with a client. It's a "sister" site to currently running 2.0.25 and so many of the products and other settings were copied over from it.

    Contrary to my usual way of working the visuals (template) is near completion, if not completed and functional testing is underway. A couple of dummy orders are placed on the system...

    What's this? The suburb is now called Address Line 2 (can live with that) but is flamin' duplicated. Strange!
    Go check the database entries in Address Book and Orders - nope they're fine. Time to trace the code then...
    Literally, after hours, I finally discovered what's going on.

    [Now, I'm sure this has changed for some flimsy legitimate reason, like Google Checkout or Fedex shipping, or something.]

    Rather than the suburb line simply being checked for an entry, it is now concatenated, along with a "cr" or "br", to the end of the Street (Address Line 1). Loads of knock-on effect, including emails. Why did it rear its' ugly head in this particular situation? Well the address_format database table was already set for what was the correct UK format of ...$street$cr$suburb... so with an easy change using phpmyadmin it now reads ...$streets...
    Easy, when you know how & why.

    Go figure!

    Change for good is, well good; change for the sake of it, is well... ((insert suitable word)).
    Another couple of days wasted, when my few grey cells should be thinking about something else.

    EJ

    [Back to thinking about Multi-store (beta stage), YMM (RC stage) and T-shirt Designer (infancy stage)]

    Developers resource at bitbucket
    *** *** ***
    oscmax.co.uk / ejsolutions.co.uk
    Hosting plans with installation, configuration, contributions, support and maintenance.
    *** FREE osCmax hosting available ***
    oscmaxtemplates.com

  2. #2
    osCMax Development Team

    Address Format and Address Line 2

    pgmarshall's Avatar
    Join Date
    Feb 2009
    Location
    London
    Posts
    3,517
    Contribute If you enjoy reading the
    content here, click the below
    image to support our site.
    Click Here To Contribute To Our Site

    Total Contributions For

    pgmarshall     $ 35.00
    Rep Power
    80


    Default Re: Address Format and Address Line 2

    EJ - I don't see where this is ...

    Just turned on Suburb (Address Line 2) and it goes in the dbase fine ... where is it coming out wrong? In the address format or in other stuff?

    Hope it wasn't me that changed anything! Address Line 2 might be my fault (or is this UK/US Switch sensitive) ... goes off to check.

    Regards.

    Ps. The address line 2 is controlled by the UK/US/AUS switch.
    Last edited by pgmarshall; 11-11-2011 at 09:50 AM. Reason: Checked Address Line 2 change ...
    pgmarshall
    _______________________________

  3. #3
    osCMax Development Team

    Address Format and Address Line 2

    ridexbuilder's Avatar
    Join Date
    Jul 2008
    Location
    Haggisland
    Posts
    4,164
    Contribute If you enjoy reading the
    content here, click the below
    image to support our site.
    Click Here To Contribute To Our Site

    Total Contributions For

    ridexbuilder     $ 15.00
    Rep Power
    99


    Arrow Re: Address Format and Address Line 2

    One example; there may be others:
    Line 528 of general.php
    PHP Code:
        if ($suburb != ''$streets $street $cr $suburb

    Developers resource at bitbucket
    *** *** ***
    oscmax.co.uk / ejsolutions.co.uk
    Hosting plans with installation, configuration, contributions, support and maintenance.
    *** FREE osCmax hosting available ***
    oscmaxtemplates.com

  4. #4
    osCMax Development Team

    Address Format and Address Line 2

    pgmarshall's Avatar
    Join Date
    Feb 2009
    Location
    London
    Posts
    3,517
    Contribute If you enjoy reading the
    content here, click the below
    image to support our site.
    Click Here To Contribute To Our Site

    Total Contributions For

    pgmarshall     $ 35.00
    Rep Power
    80


    Default Re: Address Format and Address Line 2

    But that has been there since r143 (and probably before)! Doesn't look right I agree but it has been there for ever!!

    Diff of general.php r151 - oscmax2 - osCmax - osCommerce Maximized - Google Project Hosting

    Regards.
    pgmarshall
    _______________________________

  5. #5
    osCMax Development Team

    Address Format and Address Line 2

    ridexbuilder's Avatar
    Join Date
    Jul 2008
    Location
    Haggisland
    Posts
    4,164
    Contribute If you enjoy reading the
    content here, click the below
    image to support our site.
    Click Here To Contribute To Our Site

    Total Contributions For

    ridexbuilder     $ 15.00
    Rep Power
    99


    Default Re: Address Format and Address Line 2

    Only came to light due to upgrading data, from older releases. Another database table to ignore/convert during upgrades.

    Looks like you're off the hook, this time, PGM.

    Developers resource at bitbucket
    *** *** ***
    oscmax.co.uk / ejsolutions.co.uk
    Hosting plans with installation, configuration, contributions, support and maintenance.
    *** FREE osCmax hosting available ***
    oscmaxtemplates.com

  6. #6
    osCMax Development Team

    Address Format and Address Line 2

    pgmarshall's Avatar
    Join Date
    Feb 2009
    Location
    London
    Posts
    3,517
    Contribute If you enjoy reading the
    content here, click the below
    image to support our site.
    Click Here To Contribute To Our Site

    Total Contributions For

    pgmarshall     $ 35.00
    Rep Power
    80


    Default Re: Address Format and Address Line 2

    PHEW! Thats a relief ...
    pgmarshall
    _______________________________

Similar Threads

  1. Better Admin Format Address Drop Down(version FR)
    By michael_s in forum New osCommerce Contributions
    Replies: 1
    Last Post: 12-23-2010, 12:00 PM
  2. Second Address Line
    By michael_s in forum New osCommerce Contributions
    Replies: 0
    Last Post: 08-05-2008, 04:00 PM
  3. Address Format Change
    By michael_s in forum New osCommerce Contributions
    Replies: 0
    Last Post: 03-02-2007, 04:50 PM
  4. Address Format
    By cjm1956 in forum osCommerce 2.2 Installation Help
    Replies: 0
    Last Post: 10-25-2004, 10:36 AM
  5. Address book address line ordering
    By Anonymous in forum osCmax v1.7 Discussion
    Replies: 2
    Last Post: 11-29-2003, 05:54 PM

Bookmarks

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
  •