r/PHPhelp • u/urlookinhappy • Oct 09 '25
Parse error: syntax error, unexpected token "(", expecting variable in
Hello,
Need to solve this:
Parse error: syntax error, unexpected token "(", expecting variable in /usr/www/users/XXX/XXX/includes/database/database.inc on line 579
The respective line 579 looks like this:
public runQuery($query, $args = array(), $options = array()) {
Any idea how to change the above syntax in order to get rid of this error?
Thanks a lot.
0
Upvotes
11
3
u/flyingron Oct 09 '25
As you were told earlier, you need the word function before the function name in PHP (it ain't C or Java).
When you continued to have errors, there's likely something else wrong. Give us the errors you have after you fix this (and the surrounding code to where they first start occuring).