Simple Machines Community Forum

SMF Support => SMF 1.1.x Support => Aiheen aloitti: JF3000 - tammikuu 02, 2010, 02:42:44 IP

Otsikko: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 02, 2010, 02:42:44 IP
I am getting the following error and its only just happened since coming into 2010, previously I was not getting this error, can someone assist please?

8: Undefined index: action
File: /home/domain/public_html/software/Themes/default/PortalArticles.template.php (main_above sub template - eval?)
Line: 499


I am unable to access the admin menu or anything, if I try to load other pages I just get that message or some other link relating to a main_above sub template - eval error.

Using the following version: (1.1.10)

Please assist. Thank you.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 02, 2010, 11:13:42 IP
Can anyone assist me here please?
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 03, 2010, 12:41:30 AP
Have you installed any mods recently? Do you have the Ajaxchat mod installed?
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 03, 2010, 04:24:24 AP
No mods have been installed recently, the trouble only started when we went into 2010.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 03, 2010, 04:33:25 AP
Hi Tyrsson, I found another post you assisted with and was successful, I found it using Google:

http://www.simplemachines.org/community/index.php?topic=328562.0

Is there anything from there I can do to start and assist?
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 03, 2010, 07:11:19 IP
If I remember correctly the problem is going to be in the index.php file. I notice the file listed is not a default smf file. Can you please attach the top level index.php file from your site.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 04, 2010, 06:39:31 AP
Here is the main index file for the forum.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 04, 2010, 06:36:01 IP
Please BACK UP the original file and try the one that is attached.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 05, 2010, 08:12:20 AP
Get the following msg after replacing the file:

8: Undefined index: action
File: /home/domain/public_html/software/Themes/default/PortalArticles.template.php (main_above sub template - eval?)
Line: 499
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 07, 2010, 04:24:13 AP
any more news on this error please?
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 07, 2010, 05:41:38 IP
Please install this mod to disable temp eval (Please read the documentation on the mod page for how to use the mod).

Clear the error log and reload the page and then post the new errors here.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 12:21:12 AP
Errr which mod?
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 08, 2010, 02:46:38 AP
Sorry was replying to several topics at the same time and thought I included the link.

Disable Temp Eval (http://custom.simplemachines.org/mods/index.php?mod=2054)
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 09:08:34 AP
Im a bit confused on what to do with the xml files, plus I red the docs on the mod site and editing the files but im still lost.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 08, 2010, 09:23:52 AP
Just install the package via the package manager like any other mod. Should be no reason as to why you would need to do anything with the xml files.

admincp>packages>upload a package> click install. If all test pass then click apply now.

Leave the file zipped ;)

Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 09:32:14 AP
hmmm I dont have access to the site, I get the error msg no matter where I go, I cant access the admin menu at all, I get the error then the page stops loading.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 09:33:30 AP
Whatever page I load I get the message (main_above sub template - eval?)
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 08, 2010, 09:35:24 AP
Is this on the default theme or a custom theme?
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 09:37:02 AP
default theme
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 08, 2010, 09:39:23 AP


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';
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 09:42:42 AP
Added sql and it says:


8: Undefined index: action
File: /home/domain/public_html/software/Themes/default/index.template.php
Line: 499
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 09:44:04 AP
Line 499 and 500:

if ($_POST["action"] == "affiliateadmin")
$context['current_action'] = $_POST["action"];
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 08, 2010, 09:45:38 AP
Please attach that file to your next post and a link to the last mod you were trying to install when this error showed up.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 09:50:08 AP
link to the mod huh? The error showed up when I simply tried to logon to the site, I can login to the site, buit then I get the error and everything stops loading, I cant access anything.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Tyrsson - tammikuu 08, 2010, 09:53:58 AP
Try this file and see if your still getting the error.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 10:01:26 AP
Excellent that worked, what was the problem?
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 10:06:24 AP
There is a message that says: This patch file will update your forum to SMF 1.1.11., should I upgrade?
Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 10:16:03 AP
Error:


512: parseModification(): The filename './index.php' is not a full path!
File: /home/domain/public_html/software/Sources/Subs-Package.php
Line: 1339


Thats trying to remove the current mods I have which is only 5 mods.

1.     Hack's Park Shoutbox     2.0.1     [ Uninstall ]
2.    Affiliate System    1.1    [ Uninstall ]
3.    SimplePortal    2.3    [ Uninstall ]
4.    PaypalDonations    2.0    [ Uninstall ]
5.    DisableTemplateEval    1.2    [ Uninstall ]


Otsikko: Re: main_above sub template - eval?
Kirjoitti: JF3000 - tammikuu 08, 2010, 12:15:03 IP
Okay just an update, ive killed off the affiliate mod which I had on there from the beginning, ive gone through the files and removed everything. In the installed packages area though when I try to uninstall a mod I get this message:


Type  Action  Description
1. Execute Modification ./index.php Test failed
2. Execute Modification ./Sources/Subs.php Test successful
3. Execute Modification ./Sources/ManagePermissions.php Test failed
4. Execute Modification ./Themes/default/index.template.php Test successful
5. Execute Modification ./Themes/default/languages/Modifications.english.php Test successful


Why are those files failing?

The above happens on any mod, except the affiliate mod, if I try to uninstall the mod which I know isnt there I get this message:


512: parseModification(): The filename './index.php' is not a full path!
File: /home/domain/public_html/software/Sources/Subs-Package.php
Line: 1339


Line 1339 says this:


trigger_error('parseModification(): The filename \'' . $working_file . '\' is not a full path!', E_USER_WARNING);


Any help to understand this is appreciated. Thank you.
Otsikko: Re: main_above sub template - eval?
Kirjoitti: Kar.ma - marraskuu 24, 2010, 12:12:44 IP
Hi. I had a similar problem and couldn't understand which "Line: 603" my forum was talking about. You made me find out it was the index.template.php file, and I could get it fixed. I'm writing now just to share and thank you.