General discussion
Ubuntu codoforum error

So ive just installed this forum on ubuntu i get this error after installing Parse error: syntax error, unexpected '[' in /var/www/forum/sys/vendor/illuminate/database/Illuminate/Database/Query/Builder.php on line 979

But i can still access the admin panel

I've installed 5.6 and still get the error i've also reinstalled the forum!!!
Server version: Apache/2.2.22 (Ubuntu)
Server built: Jul 22 2014 14:37:02

PHP 5.6.1 (cli) (built: Oct 13 2014 19:43:45)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2014 Zend Technologies

So ive just installed this forum on ubuntu i get this error after installing Parse error: syntax error, unexpected '[' in /var/www/forum/sys/vendor/illuminate/database/Illuminate/Database/Query/Builder.php on line 979 But i can still access the admin panel I've installed 5.6 and still get the error i've also reinstalled the forum!!! Server version: Apache/2.2.22 (Ubuntu) Server built: Jul 22 2014 14:37:02 PHP 5.6.1 (cli) (built: Oct 13 2014 19:43:45) Copyright (c) 1997-2014 The PHP Group Zend Engine v2.6.0, Copyright (c) 1998-2014 Zend Technologies

for a quick fix, open file

/var/www/forum/sys/vendor/illuminate/database/Illuminate/Database/Query/Builder.php

replace line 979 with the following code:

$this->groups = array_merge((array) $this->groups, is_array($arg) ? $arg : array($arg));

what I did was changed the syntax to an older format.

PHP 5.6.1 (cli) (built: Oct 13 2014 19:43:45)

you have the Latest PHP-CLI but the PHP module running on the Apache is still old.

to confirm the PHP version, just create a file named test.php with the following code

<?php
   phpinfo();
?>

and execute it in the browser, check if you have, atleast PHP 5.4

for a quick fix, open file ``` /var/www/forum/sys/vendor/illuminate/database/Illuminate/Database/Query/Builder.php ``` replace line 979 with the following code: ``` $this-&amp;gt;groups = array_merge((array) $this-&amp;gt;groups, is_array($arg) ? $arg : array($arg)); ``` what I did was changed the syntax to an older format. &amp;gt;PHP 5.6.1 (cli) (built: Oct 13 2014 19:43:45) you have the Latest PHP-CLI but the PHP module running on the Apache is still old. to confirm the PHP version, just create a file named `test.php` with the following code ``` &amp;lt;?php phpinfo(); ?&amp;gt; ``` and execute it in the browser, check if you have, atleast PHP 5.4

Just to make sure that in future also all scripts work well, update php and all before u move forward with launch of the site. Its always good to have the latest version of php node.js and all.

Just to make sure that in future also all scripts work well, update php and all before u move forward with launch of the site. Its always good to have the latest version of php node.js and all.

I did the PHP-CLI update and it messed up my apache smile cant start my apache now

!! avinash have you got skype or steam?
ok sent my functions to this like you said
{
$type = 'basic';

    $this->groups = array_merge((array) $this->groups, is_array($arg) ? $arg : array($arg));

    $this->havings[] = compact('type', 'column', 'operator', 'value', 'boolean');

    $this->addBinding($value, 'having');

    return $this;
}

this is how it should be? gonna test it now smile

I did the PHP-CLI update and it messed up my apache :( cant start my apache now !! avinash have you got skype or steam? ok sent my functions to this like you said { $type = &#039;basic&#039;; $this-&amp;gt;groups = array_merge((array) $this-&amp;gt;groups, is_array($arg) ? $arg : array($arg)); $this-&amp;gt;havings[] = compact(&#039;type&#039;, &#039;column&#039;, &#039;operator&#039;, &#039;value&#039;, &#039;boolean&#039;); $this-&amp;gt;addBinding($value, &#039;having&#039;); return $this; } this is how it should be? gonna test it now :)
205
3
0
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft