• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
A PHP Error was encountered

#1
Hello Friends,

Please Help me to solve the errors.

Thank You.
Pankaj Kumar.

A PHP Error was encountered
Severity: Notice
Message: Undefined variable: property
Filename: admin/edit_property.php
Line Number: 24
Backtrace:
File: C:\wamp64\www\ci-project\application\views\admin\edit_property.php
Line: 24
Function: _error_handler

File: C:\wamp64\www\ci-project\application\controllers\admin.php
Line: 69
Function: view

File: C:\wamp64\www\ci-project\index.php
Line: 315
Function: require_once


Attached Files
.php   edit_property.php (Size: 3.83 KB / Downloads: 64)
.php   propertymodel.php (Size: 813 bytes / Downloads: 75)
.php   admin.php (Size: 2.52 KB / Downloads: 116)
Reply

#2
it can't find $property->pname in edit_property.php


$property was passed to the view, so you'll need to access it as $pname


If you want it to be $property->pname you need to do this in your controller:

PHP Code:
$data['property'] = $this->property->find_property($properties_id);
   
$this->load->view('admin/edit_property',$data); 


see the docs: https://codeigniter.com/user_guide/gener...o-the-view
Reply

#3
A PHP Error was encountered
Severity: Notice

Message: Undefined variable: property

Filename: admin/edit_property.php

Line Number: 4

Backtrace:

File: C:\wamp64\www\ci-project\application\views\admin\edit_property.php
Line: 4
Function: _error_handler

File: C:\wamp64\www\ci-project\application\controllers\admin.php
Line: 67
Function: view

File: C:\wamp64\www\ci-project\index.php
Line: 315
Function: require_once

A PHP Error was encountered
Severity: Notice

Message: Trying to get property of non-object

Filename: admin/edit_property.php

Line Number: 4

Backtrace:

File: C:\wamp64\www\ci-project\application\views\admin\edit_property.php
Line: 4
Function: _error_handler

File: C:\wamp64\www\ci-project\application\controllers\admin.php
Line: 67
Function: view

File: C:\wamp64\www\ci-project\index.php
Line: 315
Function: require_once


Dear Friends Please help me to solve the error I am beginner
Reply

#4
Dear Friends please guide me to solve this error I am beginner and I try to solve it but I can't so please help me.

A PHP Error was encountered
Severity: Notice
Message: Undefined variable: property
Filename: admin/edit_property.php
Line Number: 5
Backtrace:
File: C:\wamp64\www\ci-project\application\views\admin\edit_property.php
Line: 5
Function: _error_handler

File: C:\wamp64\www\ci-project\application\controllers\admin.php
Line: 67
Function: view

File: C:\wamp64\www\ci-project\index.php
Line: 315
Function: require_once


A PHP Error was encountered
Severity: Notice
Message: Trying to get property of non-object
Filename: admin/edit_property.php
Line Number: 5
Backtrace:
File: C:\wamp64\www\ci-project\application\views\admin\edit_property.php
Line: 5
Function: _error_handler

File: C:\wamp64\www\ci-project\application\controllers\admin.php
Line: 67
Function: view

File: C:\wamp64\www\ci-project\index.php
Line: 315
Function: require_once


Attached Files
.php   admin.php (Size: 2.55 KB / Downloads: 110)
.php   propertymodel.php (Size: 874 bytes / Downloads: 101)
.php   edit_property.php (Size: 3.88 KB / Downloads: 94)
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.