SMF 2 RC4 Help with certain things

Started by Valdes, January 23, 2011, 01:15:00 PM

Previous topic - Next topic

Valdes

Quote from: AngelinaBelle on April 01, 2011, 10:16:15 AM
OK. Is the replacement Subs.php working for you? Are you still getting the error that it cannot find Subs.php?
Can you check that you have a Subs.php in the Sources directory?
If it is there, and you still get the error, can you check and correct the permissions (CHMOD) on Sources/Subs.php?
No, the replacement Subs.php did not work, it gave me this:


Strict Standards: require_once() [function.require-once]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Chicago' for 'CDT/-5.0/DST' instead in /home/kionf/public_html/epk/Sources/Subs.php on line 8009

Parse error: syntax error, unexpected ',' in /home/kionf/public_html/epk/Sources/Subs.php on line 8009

I checked the file permissions, they are 0644, and it is in the sources folder.

I don't know what's wrong.

Angelina Belle

You have a syntax error on line 8009 of Subs.php.
The php parser did not expect a comma where it found it. This could mean something else (like a closing parenthesis) was missing before that point, perhaps even on an earlier line, if 8009 is part of a multi-line statement.

I don't know what line 8009 of your Subs.php looks like, so I cannot give you any more help than that.
Never attribute to malice that which is adequately explained by stupidity. -- Hanlon's Razor

Valdes

Is it possible that I can find line 8009? Im no expert, but is there a way?

Matthew K.

Open Subs.php in a text-editor such as Notepad++ which has a linecount on the left hand side.

Angelina Belle

Valdes, I highly recommend a half-decent editor with line numbers if you are going to do any kind of customization. Otherwise, I am afraid you will lose your mind!

Writing code always means making bugs. Better tools means an easier time finding them.
Never attribute to malice that which is adequately explained by stupidity. -- Hanlon's Razor

Matthew K.

Who makes bugs when they develop mods?  :o

Arantor

Quote from: Labradoodle-360 on April 05, 2011, 01:00:38 PM
Who makes bugs when they develop mods?  :o

Anyone who writes anything of complexity will make bugs.

Matthew K.

That was sarcasm, Arantor. I was joking.
Quote from: Arantor on April 05, 2011, 01:32:44 PM
Quote from: Labradoodle-360 on April 05, 2011, 01:00:38 PM
Who makes bugs when they develop mods?  :o

Anyone who writes anything of complexity will make bugs.

Valdes

This is what my line 8009 of my Subs.php


Matthew K.

The problem is that the Admin array is closed off before SimplePortals tab.

Remove the three ), that are right above the portal tab, and it'll fix it.

Valdes


Matthew K.

Subs.php
Code (Find) Select
'permissions' => array(
'title' => $txt['edit_permissions'],
'href' => $scripturl . '?action=admin;area=permissions',
'show' => allowedTo('manage_permissions'),
'is_last' => true,

'portal' => array(
'title' => $txt['sp-adminCatTitle'],
'href' => $scripturl . '?action=admin;area=portalconfig',
'show' => allowedTo(array('sp_admin', 'sp_manage_settings')),
'is_last' => true,
),
),
),

Code (Replace) Select
'permissions' => array(
'title' => $txt['edit_permissions'],
'href' => $scripturl . '?action=admin;area=permissions',
'show' => allowedTo('manage_permissions'),
'is_last' => true,
),
'portal' => array(
'title' => $txt['sp-adminCatTitle'],
'href' => $scripturl . '?action=admin;area=portalconfig',
'show' => allowedTo(array('sp_admin', 'sp_manage_settings')),
'is_last' => true,
),
),
),

Valdes


Matthew K.


Advertisement: