• Chester –

    I’m still having trouble duplicating your example using the Restaurants Field Guide base, as I described [poorly] here. After installing v 1.1.37, part of my application broke. As I’d been running a patched version of 1.1.35, I knew the problem might be caused by calls to non-standard functionality, so I tested against your example code; it failed, as well.

    The error message in my Apache logs is the same as before:

    "AH01071: Got error 'PHP message: PHP Catchable fatal error: Object of class AirpressRecord could not be converted to string in /[...]/wp-content/plugins/airpress/lib/chetmac/AirpressCollection.php on line 231.'"

    This occurs when attempting to display a restaurant located in a district with more than one restaurant.

    Earlier, I’d been able to fix this error by adding an optional sortingtype of SORT_REGULAR to the call to array_unique() on line 231 of AirpressCollection.php, as so:

    $values = array_unique(array_merge($values, $record[$field]->getFieldValues($keys) ),SORT_REGULAR );

    This fix still works — both your sample code and my app work again once AirpressCollection is patched — but I’m still not conversant enough with your code to know whether it might screw something else up. (It’s part of that tripartite pull request I submitted a while back.)

The topic ‘Still problem duplicating Restaurant example’ is closed to new replies.