SitePoint Sponsor

User Tag List

Results 1 to 2 of 2

Thread: Parse error

Hybrid View

  1. #1
    SitePoint Member
    Join Date
    Jan 2012
    Location
    Savar, Dhaka.
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Thumbs up Parse error

    Hi,
    I am working on CodeIgniter Framework. When I visit this file it shows
    Parse error: parse error, expecting `T_STRING' or `T_VARIABLE' or `'{'' or `'$'' in F:\xampp\htdocs\ci\system\application\controllers\helloworld.php on line 5
    This is the file ....
    <?php
    class Helloworld extends Controller{
    function index() {
    $this->load->model('helloworld_model');
    $data['result'] = $this->helloworld_model-><span class="sql">getData</span>(); // line-5
    $data['page_title'] = "CI Hello World App!";
    $this->load->view('helloworld_view',$data);
    }
    }
    ?>

    can anyone help me to fix this problem?

  2. #2
    SitePoint Wizard silver trophybronze trophy Cups's Avatar
    Join Date
    Oct 2006
    Location
    France, deep rural.
    Posts
    6,869
    Mentioned
    17 Post(s)
    Tagged
    1 Thread(s)
    Other docs suggest you should be calling another method there, try this?
    PHP Code:
    $data['result'] = $this->helloworld_model->getData(); 


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
  •