SMF can be customise as shown in this forum.

Usually all the files are kept in the “Forum” folder. In that select “Themes” folder will be exixting. By default the theme used is “default”. So any changes to be made in the SMF forum, the files to be modified are kept inside this folder only.

Here in this article I tried to give certain points to customize the SMF forum. I tried to express the problems we faced in the customization and also the solutions for that problems.

1. In the title bar the default image of the SMF will be displayed.
To remove that open the file inside the “default” folder, “index.template.php” file.
search for the below line.

Code:
<img src=” ‘ ,$settings[‘images_url’] , ‘/smflogo.gif” style=”margin”: 2px; ” alt=”” />

remove that line or give the image url of your desired one instead of the default image.

2. To add the top banner and footer of your site to the SMF forum.
open the file inside the “default” folder, “index.template.php” file.
There exist a function called “template_main_above()”. In that you can find the links for the script and css files in the head tag area of the html file. Add the link and script of the website inside the head tag.
Inside the body tag the header and footer can be added.

3. To hide the email from the public for all the members by default, change the following code in the “register.template.php” file,

Code:
<label for=”hideEmail”><input type=”checkbox” name=”hideEmail” id=”hideEmail” class=”check” /> ‘, $txt[721], ‘</label>’;
as

Code:
<label for=”hideEmail”><input type=”checkbox” name=”hideEmail” id=”hideEmail” class=”check” checked /> ‘, $txt[721], ‘</label>’;

By changing like the above the check box is selected default.
Another option to set the email from the public can be done by changing the default column value of the “hideEmail” in the table “smf_members” to be set to “1”.

4. The best way to hide the email address from others and to be displayed only for admin is to add a below coding in the two place.
One is, while clicking the article submitted there will be displaying a email button. To remove that
Edit the Display.template.php file
change the coding below as

Code:
// Don’t show the email address if they want it hidden.
if (empty($message[‘member’][‘hide_email’]))
echo ‘
‘, ($settings[‘use_image_buttons’] ? ‘' . $txt[69] . '‘ : $txt[69]), ‘‘;
as

Code:
// Don’t show the email address if they want it hidden.
if (empty($message[‘member’][‘hide_email’]))
if ($context[‘user’][‘is_admin’])
{
echo ‘
‘, ($settings[‘use_image_buttons’] ? ‘' . $txt[69] . '‘ : $txt[69]), ‘‘;
}
[/li]
This will hide the email in the article display area.
The second area in which the email address will be displayed is while “the profile name is clicked “.
for this you have to change the coding in the

admin

Back to top