This is my error
8: Undefined index: viewer_text
File: /home/content/c/g/f/cgforums/html/forums/Themes/default/MessageIndex.template.php (main sub template - eval?)
Line: 69
its my only error and iw ish it would stop lol. does anyone know what to do? I installed the centering mod for child boards on MessageIndex.php
see attached.
That could be an added text by Board Viewers Mod do you have it installed?
If you have it installed, what version of it and do you have it enabled from the admin panel?
here are the mods im using...
see attached.
That code is being eval'ed so you will need to run this query in phpmyadmin What is phpMyAdmin? (http://www.simplemachines.org/community/index.php?topic=21919.0)
For 1.x
Go into phpMyAdmin ( What is phpMyAdmin? (http://www.simplemachines.org/community/index.php?topic=21919.0) ) and click on your database. Then click on the SQL tab and copy paste the following code and run it:
To Disable temp eval
INSERT INTO smf_settings VALUES ('disableTemplateEval', 1);
Use the forum a little and try to regenerate new errors. If any are found, post the new ones here. Then run this query to undo the change we made earlier:
To re-enable temp eval
DELETE FROM smf_settings WHERE variable = 'disableTemplateEval';
Im sorry Tyrsson im pretty new to all this but do have basic coding stuff. not sure how to use the phpadmin i was just looking over it too.
???
Well the trouble is that the error may not be in the file that is listed. The "context" for the MessageIndex.template.php is defined in the Messageindex.php file in the sources folder (for the most part) which means the error could actually be in that file or possible Load.php or several others so without knowing exactly where the error is its hard to fix it.
Which is the reason the eval needs turned off and the error regenerated.
ok no problem. hate to be a burden. Can you guide me through it real quick? I just downloaded phpmyadmin to my desktop where do i install/upload it to?
as far as the error eval i turn that off witha checkbox under my admin> ...? then where
ok i unchecked enable error logging
No you have to turn the error loggin back on and then disable the temp eval in Phpmyadmin.
Its not real hard. You login to phpmyadmin and then click on the database for the forum (left hand side from the home page in phpmyadmin) Then you will need to look across the top and there will be several options. One of them is SQL which you need to click on. This will open a new screen with a query window in the center. Copy the first section of code from my previous post and paste it into that window and run the query. After that clear the error log (not turn off error loggin) Then try to generate a new error so we can find out exactly where the error is occurring. Post the new error here in your next post.
ok im not understanding where do i install phpmyadmin at?
Most of the time you do not have to install phpmyadmin as it is provided by most hosting companies. You access if through the Cpanel of your hosting. You can contact your host and ask them if they provide this and they can give you instructions to login.
I use godaddy. i googled phpmyadmin on godaddy nothign came up? this sucks. i dont knwo what to do :(
If you use godaddy you will need to login into your hosting account.
Then from the left hand side click on "Hosting"
Next screen click on "Manage account"
Next screen click "DataBases"
Drop down opens click on "MySQL"
From the next screen choose the database that the forum is using and click on "Manage via phpMyAdmin".
After following these instructions (because they are from memory and its been awhile) if you still can not find how to login into phpmyadmin then you will need to call the Godaddy support line (its open 24/7).
ok i was on the phoen with them before i saw your post. i found it. awesome. i got all the way to where you told me to enter that first code and i get an error... screenshot below.
You have to paste this code:
INSERT INTO smf_settings VALUES ('disableTemplateEval', 1);
Into the window before you click go.
yes ive tried all ways. it already has a semi colon in it ive taken it out pasted it before and after all 3 same errors.
Leave the semicolon off.
ahhh ok i got it. i was putting it in the delimiter area lol. ok i did teh first part now what?
QuoteAfter that clear the error log (not turn off error loggin) Then try to generate a new error so we can find out exactly where the error is occurring. Post the new error here in your next post.
its the same error?...
not sure what i did wrong? Im getting frustrated im not normally this stupid when it comes to stuff like this. Thanks for being patient.
Please post the error so that I can see it. It may be the same error but I need to verify that it is not longer being eval'ed before I have you attach a template and start searching through 100's of lines of code.
8: Undefined index: viewer_text
File: /home/content/c/g/f/cgforums/html/forums/Themes/default/MessageIndex.template.php
Line: 69
$child['link'] = '<a href="' . $child['href'] . '" title="' . ($child['new'] ? $txt[333] : $txt[334]) . ' (' . $txt[330] . ': ' . $child['topics'] . ', ' . $txt[21] . ': ' . $child['posts']. $child['viewer_text'] . ')">' . $child['name'] . '</a>';
that is line 69. im using dreamweaver to open it.
Please attach a this file to your next post:
/Themes/default/MessageIndex.template.php
Also please post a list of all mods you have installed if you have not already done so.
file and mods.
Its most likely being caused by the Sub Board mod. Please look over the manual install instructions and verify that all edits were made by the mod.
http://www.simplemachines.org/community/index.php?topic=300777.20
i got the mod there and reply 34 is the guy that said i would have to manually add it to the messageindex area.
it works fine but throws up that error.
he said to add it manually for child of child boards to be aligned and centered. cause the original mod only does the index page.
Ok its not that mod. let me check a few things here and see if I can find which mod it may be caused by.
If that is the mod that is causing it then remove the mod.
well it was fine untill i manually edited that messageindex.template file. i had no errors prior?
maybe you can help me redo what i was supposed to do? i followed the manual intructions for that mod i showed you BUT i did them in the messageindex.template file not the boardindex.
the admin/mod did say they were similar.... so i dunno?
http://custom.simplemachines.org/mods/index.php?action=parse
that is what i did but in the messageindex.template file. there is no installed mod i did it manually i dont know how to redo it?
Can you please link me to the mod download page in the customize site for this mod.
http://custom.simplemachines.org/mods/index.php?mod=1704
1.1.8 manual instructions.
i did the manual instillation backwards and i get no errors now.. but how do i do it the right way to align my child of child boards.
I'm just guessing here now - but could it just be that the Aligned and Bilateral boards -mod has the $child['viewer_text'] by mistake. It is used in Board Viewers Mod, and I can't see any use for it in this mod...
Aligned and Bilateral Child Boards smf 1.1.x
(http://custom.simplemachines.org/mods/index.php?mod=1704)
Board Viewers (http://custom.simplemachines.org/mods/index.php?mod=295)
I will have to look into it later this evening as it is time for some $sleep.
Quote from: LexArma on April 02, 2009, 10:36:07 AM
I'm just guessing here now - but could it just be that the Aligned and Bilateral boards -mod has the $child['viewer_text'] by mistake. It is used in Board Viewers Mod, and I can't see any use for it in this mod...
Aligned and Bilateral Child Boards smf 1.1.x
(http://custom.simplemachines.org/mods/index.php?mod=1704)
Board Viewers (http://custom.simplemachines.org/mods/index.php?mod=295)
so what would i take out of that? that makes total sense... what do you suggest?
in ./Themes/default/BoardIndex.template.php I would try finding this
$txt[21] . ': ' . $child['posts']. $child['viewer_text'] . ')">' . $child['name']
and changing it to this
$txt[21] . ': ' . $child['posts']. ')">' . $child['name']
But I can't promise you it will work, so if you didn't backup already - then atleast take a copy of the file now, before trying.
wait. its messageIndex.template.php file that i was having the error with. because i wanted my child of CHILD boards aligned and centered with that mod. So i was told to manually do teh same as i would on board index but on messageindex.template.php.
so shoudl i still try that? Follow the manual instructions on the mod but instead of doing it on board index do it on messageindex? and then try tyhe change you suggested?
Oh yeah, if you did the edit in boardindex instead of messageindex, then yeah, try to take the same bit out of it.
YOU ARE A HERO! DAMN I LOVE YOU! lol.
that was correct.
you saved my life lol.
honestly thank you very much. where the hell were you earlier?! lol >:(
works perfect and its not giving any errors.
:)
Quote from: Amoreitalia on April 02, 2009, 11:19:21 AM
YOU ARE A HERO! DAMN I LOVE YOU! lol.
And you are very welcome :D
Quote from: LexArma on April 02, 2009, 11:20:21 AM
Quote from: Amoreitalia on April 02, 2009, 11:19:21 AM
YOU ARE A HERO! DAMN I LOVE YOU! lol.
And you are very welcome :D
For that im adding you to my will.. haha.
no but really. can i call on you when i have an issue again? lol. :P
I'll be around ;)
Just to add a little to this:
I went through all my theme files, and not a single hit when I searched for the $child['viewer_text'] in them, so I'm pretty confident it is not needed, nor does it belong to the default 1.1.8 code at all.
No that is not default code for the template files. The problem is that there is no value assigned to that in a source file most likely.
The problem was that it didn't belong there at all, wasn't intended to be there in the first place, had no relation to the functionality the mod had - and problem was solved by removing it :)
EDIT And I take it from Amoreitalia's comments, that this can be marked as solved ;)
:)
Marked