![]() |
Please help. Bad error.
I was told by one of my php coders that this error means that a chunk of code is missing and I didn't delete a chunk of code. Here is the error.
Code:
Fatal error: Call to undefined function: gettemplate() in /web/dark/public_html/testvb/member.php on line 1297 Dark Shogun Ps. I get this error when I click on the name of my newest member on the forum homepage. http://www.thatfinalfantasysite.com/testvb |
Wow, your PHP coder friend sure was a lot of help with that advice :p
Anyway, it's too hard to tell exactly what could be the problem with just the information you've provided, but I recommend if your member.php is barely modified with hacks, then just to replace it with the original. If it is modified to an extent you don't feel like replacing, then I would try comparing the unmodified member.php and your version. But first, let's try to help you ....can you post a chunk of the code around line 1297, but NOT the entire member.php (as that's against rules). ;) |
Ok. I will get the code around that line. I have used beyond compare and could see a chuck of code missing.
Dark SHogun |
Code:
// ############################### start get info ############################### |
Try a quick execution test, to see if the page loads without line 1297. In other words, find:
PHP Code:
|
When I do that I get this error:
Code:
Parse error: parse error, unexpected $ in /web/dark/public_html/testvb/member.php on line 1690 Code:
eval("\$sendmessage = \"".gettemplate("email_usermessage",1,0)."\";"); |
My bad, I accidentally told you to remove a neccessary bracket. In this code which I told you to remove:
PHP Code:
PHP Code:
|
Ok doing that I get this error:
Code:
Fatal error: Call to undefined function: checkwarnlink() in /web/dark/public_html/testvb/member.php on line 1302 Code:
} |
Is the hack you are trying to install (or did recently) a hack by g-force2k2? Just curious.
I noticed this a bit above: PHP Code:
So replace the above with: PHP Code:
|
Now I get this error.
Code:
Fatal error: Call to undefined function: checkwarnlink() in /web/dark/public_html/testvb/member.php on line 1300 Code:
} |
Ok just to let you know this happens everytime I try to view a persons profile.
Dark Shogun |
Even after the fix you continue to recieve the errors, hmm.
Well, I'm not sure what to say, since the line references aren't helping. If I were you I'd replace my member.php with the original. Either that, or work back from the last hacks you installed and figure out what's missing. Try backing up your member.php, then replacing it with the original unmodified. See if the page will load without errors, and if it does then you know it's an error in member.php. If it doesn't, then it could be external like in functions.php. But if it does load, then you'll have to figure it out somehow. Regards, Velocd |
Ok I just check when I replace it with the original it works BUT when I check both the hacked and original side by side in Beyond compare I don't see any code missing at all. Then I add the hacks to the member.php file and it goes back to the orginal error:
PHP Code:
Dark Shogun |
In your member.php, this line is incomplete:
PHP Code:
Quote:
|
PHP Code:
Dark Shogun |
I was referring to your post here:
https://vborg.vbsupport.ru/showthrea...330#post311330 12th line in the code you posted. |
Oh I am sorry. For some reason when I posted it, it didn't come out on one line like it was supposed to.
Dark Shogun PS. Post number 15 is the right line. http://www.thatfinalfantasysite.com/...tinfo&userid=6 |
Try this:
Change this: PHP Code:
PHP Code:
|
Didn't work. I tried that.
Dark Shogun |
Are you sure? The error is telling you that what is between the gettemplate() brackets are in error - make sure that template exists, and you use ' instead of " because using " confuses the code with the other " in that line.
|
Ok I made sure the templates are there and they are. I changed that line to:
PHP Code:
If I change it to: PHP Code:
Dark Shogun |
The error I see now is this one:
Quote:
|
What is between the checkwarnlink() brackets?
|
Btw, the 2 codes in your post above are the same - which one is which?
|
Here is the template.
Dark Shogun |
One has " and the other has '
Dark Shogun |
Look at this post of yours:
https://vborg.vbsupport.ru/showthrea...095#post312095 They both have ' :) Use ', don't use ". We can then look at the next error and figure out why... |
Tell me what is on line 1286?
|
I see what you did... don't change the " that is outside the brackets - as long as the variable in the bracket is ' then you are fine. Change the ' back to " OUTSIDE the brackets - use the code I posted in my previous post.
|
In your post, use the SECOND example you posted. The first one will give an error.
|
Line 1286:
PHP Code:
|
Now we are back to the original error:
Fatal error: Call to undefined function: gettemplate() in /web/dark/public_html/testvb/member.php on line 1282 Dark Shogun |
If I send you both member.php files (modded and original) do you think that will help?
Dark Shogun |
Makes no sense to me. :) Something is very wrong in the way you installed the warning's hack. I suggest you remove it, and reinstall it. You are missing something essential in your members.php. Try posting in that thread itself to see if you get a response.
|
Okay, just PM me your members.php and I will have a look at them.
|
You completely installed the warning hack wrong in your member.php - next time read the installation text for the hack properly. You put the code in the wrong place and as a result had 2 occurences of the line that calls the same template.
I have PMed you the member.php that I fixed. |
Ok I uploaded that member.php and now I get this error:
Quote:
|
OMEG. I got it up. :) Thanks Erwin. After I put up the member.php file you gave me it didn't work but then I changed the " to ' and added another }
Dark Shogun |
Ok. You misread gforce2k's instruction - the 2 chunks of code for member.php is in 2 separate places. I just copied your code to where it's supposed to be. Obviously the code you had was not completely original. :) Good to hear it works now. If you look at your original member.php you can see how your code is located too high up - it should have been at the end - as a result you had to lines with the same code - one at the top, the other at the end. You were meant to add code BELOW the template line, not add the whole thing below the templatesused line. :)
|
All times are GMT. The time now is 02:22 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|