Trying to get property of non-object

I am trying to access my businesses in the admin screen. When I click Update, i get the following error:
Trying to get property of non-object
PHP Error
Description

Trying to get property of non-object
Source File

/home1/roadtri1/public_html/yii-admin/protected/views/businessAcct/_form.php(2)

00001:


00002: data<?php print $model->BusStatus->text ?>
00003:
00004: <?php echo CHtml::beginForm(); ?>
00005:
00006:

Fields with are required.


00007:
00008: <?php echo CHtml::errorSummary($model); ?>
00009:
00010: <?php
00011: /
00012:

00013: <?php echo CHtml::activeLabelEx($model,'BusWordZxPass'); ?>
00014: <?php echo CHtml::activeTextField($model,'BusWordZxPass',array('size'=>50,'maxlength'=>50)); ?>

Please do not double-post. I removed the other duplicate post. Now, the error message you showed us is
missing the rest of it. It should tell you which line the error is in. What line was the error on?

Since we can not see all of your code, I will guess you are not loading the object in some other code. If you
look line this error tell you, and work backwards to locate where that object is loaded, most likely the code
in the area where it is loaded is incorrect. Hmmm, not sure if that helps. Which line was the error on?

Also, in line #2, you use print instead of echo which is okay, but confusing and you are missing the ending ; …
( All PHP code even if inline needs to be terminated… <?PHP echo "xyz"; ?> )

Sponsor our Newsletter | Privacy Policy | Terms of Service