unexpected T_VARIABLE error


Posted on 16th Feb 2014 07:03 pm by admin

Hey all! I'm getting an unexpected T_VARIABLE with the following function:

function getHighestParentName($id = $this->cid){
$cat = mysql_fetch_assoc(fsquery('getParentCategories', $id));
if ($cat['pid']!=0){getHighestParentName($cat['id']);}
return $cat['name'];
}

fsquery is a function defined in another file, which I know is correctly defined and correctly referenced. pid, id, and name are column names in a mysql table. Can someone please help me find what's wrong? Thanks

No comments posted yet

Your Answer:

Login to answer
333 Like 18 Dislike
Previous forums Next forums
Other forums

passing data from one page to another
hey guys
i have the follwoing code to get information from one page and place on another:

Need help with a mail notify function
I was tasked with setting up a site that's been prewritten. The site is basically a form that captur

Insert Failing.
Hey,
I am making a Sign up page for a website, but the insert query into the Database does not se

IP Logger for Voting Script
Can anybody help me place an IP logger into my voting script?
I know that maybe it is not as secu

error checking breaking my code
Hi there, OK first of all, big apologies for what I assume is really fundamental errors in the struc

help finding hacking loopholes
i was attacked by a redirect php injection

my pc is clean of viruses

so i figure that

Update Database
Hi All,


I have a problem with this:

Code: [Select]<?php
session_start();

error with opendir
when i do this

if ($handle = opendir($dir)) {
while (false !== ($file = readdir($han

PHP and XML image gallery variable issue
I'm trying to display the large image on the same page as the thumbnails, to do that I'm passing a v

Price in PR
Dear Experts,
Why we have to enter the price in the PR, and why there is no free goods indicato

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash