News:

Welcome to the Unofficial Help Forum



Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Illori

Pages: [1]
1
Modifications / download system download permission
« on: September 06, 2013, 10:56:28 AM »
all edits have to be done manually. no support will be provided.
Themes/Default/Download2.template.php
Code: (find) [Select]
$g_report = allowedTo('downloads_report');
Code: (add after) [Select]
$g_dl = allowedTo('downloads_dl');
Code: (find) [Select]
// Show the main download
Code: (replace) [Select]
if($g_dl){
// Show the main download

Code: (find) [Select]
echo '
</td>
</tr>';
Code: (add after) [Select]
}
Code: (find) [Select]
// Show linking codes
Code: (replace) [Select]
if($g_dl){
// Show linking codes

Code: (find) [Select]
echo '</table>';
Code: (add after) [Select]
}
Sources/Downloads2.php

Code: (find) [Select]
function Downloads_DownloadFile()
{
global $modSettings, $txt, $context, $smcFunc, $user_info;

// Check Permission
isAllowedTo('downloads_view');

Code: (replace) [Select]
function Downloads_DownloadFile()
{
global $modSettings, $txt, $context, $smcFunc, $user_info;

// Check Permission
isAllowedTo('downloads_dl');

Sources/ManagePermissions.php
Code: (find) [Select]
'downloads_view',
Code: (add after) [Select]
'downloads_dl',
Themes/Default/Languages/Modifications.<your language>.php
Code: (find) [Select]
$txt['permissionname_downloads_view'] = 'View Downloads';
$txt['permissionhelp_downloads_view'] = 'Allows the user to view the Downloads';
$txt['cannot_downloads_view'] = 'You are not allowed to view the Downloads';
Code: (add after) [Select]
$txt['permissionname_downloads_dl'] = 'Download';
$txt['permissionhelp_downloads_dl'] = 'Allows the user to download.';
$txt['cannot_downloads_dl'] = 'You are not allowed to download.';

after applying the edits each groups permissions need to be modified to allow downloading of files in the download system.

also please DO NOT post a link to this on simplemachines.org

2
Modifications / SMF Likes Plus
« on: February 28, 2013, 09:33:41 PM »
We now have a Likes mod.





You can Like or Unlike each post but a post that you make.

If more then 5 people have liked a post it will not show the names to save space.

Be sure after the mod is installed to set the permissions for which groups can like the posts. If you want a board to not have likes you would need to create a Permissions Profile to deny/disallow the liking in that board.



This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License.

3
Modifications / Custom Admin Panel
« on: February 11, 2013, 12:58:18 PM »
Our first modification, Custom Admin Panel.
This mod will show a more graphic admin panel along with the default panel.
This mod supports all default features of smf. This mod does not come with images to support menu options from mods, they can be added easily though. To find the name of the images needed, it is easiest to use Firebug, or Dragonfly or similar applications.


This modification modifies:

$sourcedir/Admin.php
$themedir/Admin.template.php
$themedir/css/admin.css


This modification also adds several images to the newly created folder
$themedir/images/admin/cap


It is fairly easy to add additional links to this mod to show more admin pages, the hard part is finding an image that can represent that action.

4
News & Announcements / minor server move
« on: May 15, 2012, 01:52:50 PM »
sometime tomorrow 5/16 the forum will move again to another server with the same provider. the nameservers will change so you may need to wait a few hours to reconnect once the forum moves. this will provide better performance for the forum.

5
FAQ / FAQ license
« on: April 17, 2012, 04:16:42 PM »
the FAQ's in this board are under the
license

Creative Commons Attribution-ShareAlike 3.0 Unported License.

6
FAQ / Permissions per board
« on: April 17, 2012, 03:56:19 PM »
In SMF you can have permissions for each board, so different groups can do different things. this can be useful for a board that you want users to be able to reply but not post new topics.

You would first need to enable local permissions for the board, if using 1.1.1* or in 2.0
Admin -> Permissions -> Edit Profiles -> add new name and create the profile then edit it, and then assign to a board when you edit the board.

In 1.1.1* you need to enable local permissions
admin -> permissions -> settings enable advanced by-board permissions

Then you can set the board to use local permissions under the permissions by board tab. Then you can click on the board name to add/change the permissions for each group, these permissions would only apply to this one board. for each board that requires custom permissions you would need to set them manually for each board. In 2.0 you can reuse a permission profile in multiple boards.


There are some pre-made profiles available which you can see in 1.1.1* when you edit the boards permissions in the drop down "apply pre-defined permission profile" and in 2.0 they are shown when you go to admin -> permissions -> edit profiles, those you cant change permissions are the default profiles. These pre-made profiles do not include permissions for any mods that you may have installed, so you should verify that the permissions are correct, it may be easier to create the custom profile instead of using the pre-made so you are sure what permissions are given to your users.



The following links may be useful to read as a follow up to this:
Permission Profiles
Understanding Permissions

7
FAQ / Post Count Groups and their Permissions
« on: April 17, 2012, 03:49:59 PM »
In both 2.0 and 1.1.1* you can have permissions for each of the post count based groups. They can be enabled by Admin -> Permissions -> Settings -> Enable permissions for post count based groups

Once you have done this you need to remember the post count groups also inherit permissions from their main group, which for many users would be the regular members group even if you dont see that the user is in a primary membergroup. 

8
FAQ / Errors in the error log ending with EVAL
« on: April 17, 2012, 03:47:43 PM »
For error messages that end in EVAL you need to disable template evaluation. In 2.0 this is a default feature

Admin -> Server Settings -> Disable evaluation of templates
Then post any new error messages without eval in them

In 1.1.1* you need to install a mod first then you can disable the evaluation

You would need this mod installed http://custom.simplemachines.org/mods/index.php?mod=2054 then to disable the template evaluation, admin -> server settings -> feature configuration -> Disable evaluation of templates?

Once you have disabled the template evaluation you will be able to view the exact file and line number that is causing the error the next time you do the action that was causing the issue. Once you get the new error message without eval in it, you can post that and we can try to help you resolve the problem.

If you can not access your forum due to the eval error, you can run this query in phpmyadmin to disable template eval and get the full error message

Code: [Select]
REPLACE INTO smf_settings VALUES ('disableTemplateEval', 1);
Or you can use the following script, or the attachment, to disable template eval, put the script in the same folder as your settings.php file, this script works for both 1.1.1* and 2.0.*

Code: [Select]
<?php
/**
 * Disable Template Evaluation
 *
 * @file ./disable_eval.php
 * @author Matthew Kerle <lab360@simplemachines.org>
 * @copyright Matthew Kerle, 2012
 * @license http://www.mozilla.org/MPL/MPL-1.1.html
 *
 * @version 1.1.0
 */
$disable_eval = new DisableTemplateEval;
class 
DisableTemplateEval
{
protected $db$settings;
public function __construct()
{
$this->smfSettings();
$this->connectDatabase();
$this->setEval();
$this->closeDatabase();
}
protected function smfSettings()
{
global $db_type$db_server$db_user;
global $db_passwd$db_prefix;
if (!file_exists('Settings.php')) {
if (file_exists('../Settings.php'))
$path '../Settings.php';
else
exit('Sorry, you must place this file in the same directory as SMF\'s Setting.php file.');
}
else
$path 'Settings.php';
require($path);
if (isset($db_type) && $db_type != 'mysql')
exit('Sorry, this script currently only supports MySQL.');
$this->settings = array(
'db_server' => $db_server,
'db_name' => $db_name,
'db_user' => $db_user,
'db_pass' => $db_passwd,
'db_prefix' => $db_prefix
);
return true;
}
protected function connectDatabase()
{
$this->db mysql_connect($this->settings['db_server'], $this->settings['db_user'], $this->settings['db_pass']);
if (!$this->db)
exit('Sorry, we were unable to connect to your database via the SMF Configuration Settings.');
mysql_select_db($this->settings['db_name'], $this->db);
}
protected function setEval()
{
mysql_query('REPLACE INTO ' $this->settings['db_prefix'] . 'settings (variable, value) VALUES("disableTemplateEval", 1)'$this->db);
exit ('Template Eval Successfully Disabled!');
}
protected function closeDatabase()
{
mysql_close($this->db);
}
}

9
FAQ / How do I set default options for my users?
« on: April 17, 2012, 03:45:01 PM »
In 2.0 and similar in 1.1.1* you can set some default options for users based on the options in their profile -> look and layout (preferences)

You can set these in the admin panel under
Admin -> Current Theme -> Member Options -> Change current options for all members using this theme
Admin -> Current Theme -> Member Options -> Configure guest and new user options for this theme

And for 1.1.1* it is under

Admin -> Current Theme -> Reset Options -> Reset default (guest) options for this theme
Admin -> Current Theme -> Reset Options -> Reset all members' current options for this theme

Keep in mind if you use more then one theme on your forum, you will need to set these options for each theme.

10
FAQ / a table is marked as crashed and should be repaired
« on: April 17, 2012, 03:42:34 PM »
You would need to repair said table. This can be done using phpmyadmin or similar database management application.

this shows you how to repair the table using phpmyadmin.

Pages: [1]
anything