Customizing SMF > Modifications and Packages

BoardHover Mod

<< < (2/48) > >>

S3NTYN3L:

--- Quote from: butchs on January 28, 2008, 10:17:09 PM ---I would keep the color as you want and make a filter image with PhotoShop or something like that.  The code will look something like:

.??_hover:hover, .??_hoverHover
{
background-color: #color;
background-image: url(./images/filter.jpg);

--- End quote ---

You don't need both entries in there...

Just use  background: url(images/image_name.extension) #hex repeat-x;

Notice that both the #hex AND image is in there...

Fallen Angel:
NICE MOD!

BUT how do I get it to work under a other theme than default?

I'm using DilberMC..

I accached the 3 files i need to change in my theme to get it to work? Can any give the codes and where to put it?? I'm a lil bit newbie in this.. Thanx...

S3NTYN3L:
This mod makes changes to the following files:
index.template.php
MessageIndex.template.php
BoardIndex.template.php
PersonalMessage.template.php
style.css

The above files SHOULD be found in the custom theme's folder.
I say this because some themes are pretty basic and, if they DO NOT have the files mentioned, rely on those contained in the default theme folder. (basically, as I understand it, they call/link to them)...


This mod was written for the default theme but you can edit it for use with any theme you like.
Just follow the instructions below...

First, UNDO any and all changes this mod may have made while trying to install previously...
Download the mod package to your computer to edit...

Open the file entitled "Profile-Info" in your PHP code editor.

On line 12, edit the following to point to your theme:
<require-file name="pseudo-hover.htc" destination="$boarddir/Themes/default" />
Example:
<require-file name="pseudo-hover.htc" destination="$boarddir/Themes/YOUR_THEMES_NAME" />

Do the same for path found on line 18...


Next, open the file entitled "Modification".

On line 24, you'll find:
<file name="$themedir/index.template.php">

Edit it to point to your theme, like so:
<file name="Themes/YOUR_THEMES_NAME/index.template.php">

Do the same for lines 46, 148, 198 & 208...

Line 046: <file name="$themedir/MessageIndex.template.php">
Line 148: <file name="$themedir/BoardIndex.template.php">
Line 198: <file name="$themedir/PersonalMessage.template.php">
Line 208: <file name="$themedir/style.css">

...would become...

Line 046: <file name="Themes/YOUR_THEMES_NAME/MessageIndex.template.php">
Line 148: <file name="Themes/YOUR_THEMES_NAME/BoardIndex.template.php">
Line 198: <file name="Themes/YOUR_THEMES_NAME/PersonalMessage.template.php">
Line 208: <file name="Themes/YOUR_THEMES_NAME/style.css">

Next, you'll need to edit the colors on lines 214, 215, 227, 228, 240 & 241 to MATCH what your theme's stylesheet is using...
(NOTE: you must look at your themes stylesheet to find this data)...

.windowbg
Lines 214 & 215

.windowbg2
Lines 227 & 228

.windowbg3
Lines 240 & 241

Lines 220, 233, 246 & 250 should be set to whichever color you'd like to use for the "hover" color.


Once that's all done, simply zip the package and install as normal...


IF you get errors regarding the changes this mod makes to your stylesheet, edit the modification file as follows...

On line 212, you should see this:

 <search position="

REPLACE IT, AND EVERYTHING AFTER, WITH THIS, (editing the parts in blue to suit your theme):

 <search position="after"><![CDATA[/* The AJAX notifier */
]]></search>
<add><![CDATA[.windowbg_hover:hover,.windowbg_hoverHover
{
   background: #505050;
}

.windowbg2_hover:hover,.windowbg2_hoverHover
{
   background: #505050;
}

.windowbg_hover3:hover,.windowbg3_hoverHover
{
   background: #505050;
}
.mail_hover:hover,.mail_hoverHover
{
   background: #505050;
}
]]></add>   </operation>
</file>

</modification>



If you feel all this is too much for you, kindly attach the files mentioned at the beginning of this post and I'll make the changes for you.
Also tell me what you want the hover color to be. (In HEX format; #xxxxxx)...

lookang:
Type     Action     Description
1.    Execute Modification    ./Themes/default/index.template.php    Test successful
2.    Execute Modification    ./Themes/default/MessageIndex.template.php    Test failed
3.    Execute Modification    ./Themes/default/BoardIndex.template.php    Test failed
4.    Execute Modification    ./Themes/default/PersonalMessage.template.php    Test successful
5.    Execute Modification    ./Themes/default/style.css    Test successful
6.    Extract File    ./Themes/default/pseudo-hover.htc

help !

butchs:
If you have version 1.1.4 of SMF then you have a another mod that is interfering with this mod.  For example, a mod like "stickyFirstPost" modifies "MessageIndex.template.php" and works if installed after "BoardHover" mod but not before.

The easy thing would be to find out which mod is interfering and remove it.  Install BoardHover mod and try to reinstall the interfering mod afterwards.  Chances are it will install like  "stickyFirstPost" did.

Or you can try a manual install.

last but not least, if you list the mods you have I can look at them next weekend.  I will not have access to this site until next Saturday.   O:)

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version