bencorlett/fuel-geocode

Error with Converting

Closed this issue · 4 comments

Hey,

I seem to be getting this issue. Do you have any idea how I can resolve this?

RuntimeException [ Error ]: Object class "Geocode\Geocode_Response_Result" could not be converted to string or sanitized as ArrayAccess. Whitelist it in security.whitelisted_classes in app/config/config.php to allow it to be passed unchecked.

I have this in my controller:

$geocode = \Geocode::address('19 Gateway Boulevarde, Morisset NSW 2264 Australia');

This in my View:
foreach ($geocode as $geoc)
{
echo $geoc->latitude() . ' ' . $geoc->longitude();

                    echo $geoc->component('street_number', 'short');

                }

Cheers,

Hey mate,

Have you tried adding te class to "whitelisted" classes in the config like it says?

Sent from my iPhone

On 21/07/2012, at 9:39 PM, Steven Church reply@reply.github.com wrote:

Hey,

I seem to be getting this issue. Do you have any idea how I can resolve this?

RuntimeException [ Error ]: Object class "Geocode\Geocode_Response_Result" could not be converted to string or sanitized as ArrayAccess. Whitelist it in security.whitelisted_classes in app/config/config.php to allow it to be passed unchecked.

I have this in my controller:

$geocode = \Geocode::address('19 Gateway Boulevarde, Morisset NSW 2264 Australia');

This in my View:
foreach ($geocode as $geoc)
{
echo $geoc->latitude() . ' ' . $geoc->longitude();

                   echo $geoc->component('street_number', 'short');

               }

Cheers,


Reply to this email directly or view it on GitHub:
#1

Hey buddy,

Yeah could seem to get it to ignore it..

Tried adding Geocode geocode Fuel\Packages\Geocode none of which worked..

Any ideas?

Steve,

On 21 Jul 2012, at 23:51, Ben Corlett wrote:

Hey mate,

Have you tried adding te class to "whitelisted" classes in the config like it says?

Sent from my iPhone

On 21/07/2012, at 9:39 PM, Steven Church reply@reply.github.com wrote:

Hey,

I seem to be getting this issue. Do you have any idea how I can resolve this?

RuntimeException [ Error ]: Object class "Geocode\Geocode_Response_Result" could not be converted to string or sanitized as ArrayAccess. Whitelist it in security.whitelisted_classes in app/config/config.php to allow it to be passed unchecked.

I have this in my controller:

$geocode = \Geocode::address('19 Gateway Boulevarde, Morisset NSW 2264 Australia');

This in my View:
foreach ($geocode as $geoc)
{
echo $geoc->latitude() . ' ' . $geoc->longitude();

                  echo $geoc->component('street_number', 'short');

              }

Cheers,


Reply to this email directly or view it on GitHub:
#1


Reply to this email directly or view it on GitHub:
#1 (comment)

Even with

Geocode\Geocode_Response_Result in there?

Try turning off filtering classes in the config see if that fixes the problem? Maybe ask @frenkynet about it, I haven't used fuel in like 6 months now sorry. I'll have a look in the morning (it's night here in Australia)

Sent from my iPhone

On 21/07/2012, at 9:53 PM, Steven Church reply@reply.github.com wrote:

Hey buddy,

Yeah could seem to get it to ignore it..

Tried adding Geocode geocode Fuel\Packages\Geocode none of which worked..

Any ideas?

Steve,

On 21 Jul 2012, at 23:51, Ben Corlett wrote:

Hey mate,

Have you tried adding te class to "whitelisted" classes in the config like it says?

Sent from my iPhone

On 21/07/2012, at 9:39 PM, Steven Church reply@reply.github.com wrote:

Hey,

I seem to be getting this issue. Do you have any idea how I can resolve this?

RuntimeException [ Error ]: Object class "Geocode\Geocode_Response_Result" could not be converted to string or sanitized as ArrayAccess. Whitelist it in security.whitelisted_classes in app/config/config.php to allow it to be passed unchecked.

I have this in my controller:

$geocode = \Geocode::address('19 Gateway Boulevarde, Morisset NSW 2264 Australia');

This in my View:
foreach ($geocode as $geoc)
{
echo $geoc->latitude() . ' ' . $geoc->longitude();

                 echo $geoc->component('street_number', 'short');

             }

Cheers,


Reply to this email directly or view it on GitHub:
#1


Reply to this email directly or view it on GitHub:
#1 (comment)


Reply to this email directly or view it on GitHub:
#1 (comment)

Hey buddy.

No worries, yeah same here in NZ.

That fixed it thank you mate. Not long stated using Fuel, its quite nice.

Cheers,

On 21 Jul 2012, at 23:56, Ben Corlett wrote:

Even with

Geocode\Geocode_Response_Result in there?

Try turning off filtering classes in the config see if that fixes the problem? Maybe ask @frenkynet about it, I haven't used fuel in like 6 months now sorry. I'll have a look in the morning (it's night here in Australia)

Sent from my iPhone

On 21/07/2012, at 9:53 PM, Steven Church reply@reply.github.com wrote:

Hey buddy,

Yeah could seem to get it to ignore it..

Tried adding Geocode geocode Fuel\Packages\Geocode none of which worked..

Any ideas?

Steve,

On 21 Jul 2012, at 23:51, Ben Corlett wrote:

Hey mate,

Have you tried adding te class to "whitelisted" classes in the config like it says?

Sent from my iPhone

On 21/07/2012, at 9:39 PM, Steven Church reply@reply.github.com wrote:

Hey,

I seem to be getting this issue. Do you have any idea how I can resolve this?

RuntimeException [ Error ]: Object class "Geocode\Geocode_Response_Result" could not be converted to string or sanitized as ArrayAccess. Whitelist it in security.whitelisted_classes in app/config/config.php to allow it to be passed unchecked.

I have this in my controller:

$geocode = \Geocode::address('19 Gateway Boulevarde, Morisset NSW 2264 Australia');

This in my View:
foreach ($geocode as $geoc)
{
echo $geoc->latitude() . ' ' . $geoc->longitude();

                echo $geoc->component('street_number', 'short');

            }

Cheers,


Reply to this email directly or view it on GitHub:
#1


Reply to this email directly or view it on GitHub:
#1 (comment)


Reply to this email directly or view it on GitHub:
#1 (comment)


Reply to this email directly or view it on GitHub:
#1 (comment)