News:

Wondering if this will always be free?  See why free is better.

Main Menu

PageEar (Page peel)

Started by KiLLuMiNaTi-7-, August 07, 2008, 07:51:33 AM

Previous topic - Next topic

KiLLuMiNaTi-7-

Link to Mod



PageEar (Pagepeel)
By KiLLuMiNaTi-7- | Support



Introduction
This mod adds a Page peel to your forum.

Converted to work with SMF. Original author Christian Harz - Webpicasso Media converted with permission from the author.

Compatibility:
1.1.X - 2.0

Installation
Install the package to install on the default theme.

Features
Customize the look in the admin panel.

Custom Themes

All CUSTOM themes will require a custom edit.

Run the installer then do these edits make sure you do the right edit for your SMF version!

FOR 1.1.X

Code (Find) Select
<title>', $context['page_title'], '</title>';

Code (Add After) Select

//PageEar mod
if ($modSettings['pageear_enable'])
echo '
<script src="', $settings['default_theme_url'], '/pageear/AC_OETags.js"
language="javascript"></script>
<script src="', $settings['default_theme_url'], '/pageear/pageear.js"
type="text/javascript"></script>
<script language="JavaScript" type="text/javascript">
var pagearSmallImg = "', $modSettings['pageear_small_url'], '";
var pagearSmallSwf = "', $settings['default_theme_url'], '/pageear/pageear_s.swf";
var pagearBigImg = "', $modSettings['pageear_big_url'], '";
var pagearBigSwf = "', $settings['default_theme_url'], '/pageear/pageear_b.swf";
var speedSmall = "3";
var mirror = "', $modSettings['pageear_mirror'], '";
var pageearColor = "ffffff";
var jumpTo = "', $modSettings['pageear_jumpto'], '"
var openLink = "', $modSettings['pageear_opennew'], '";
var openOnLoad = "', $modSettings['pageear_onload'], '";
var closeOnLoad = "', $modSettings['pageear_pageear_closeonload'], '";
var setDirection = "', $modSettings['pageear_rtlt'], '";
var softFadeIn = "', $modSettings['pageear_softfade'], '";
var requiredMajorVersion = "6";
var requiredMinorVersion = "0";
var requiredRevision = "0";
var copyright = "Webpicasso Media, www.webpicasso.de";
var thumbWidth  = "100";
var thumbHeight = "100";
var bigWidth  = "500";
var bigHeight = "500";
var xPos = "right";
var queryParams = "pagearSmallImg="+escape(pagearSmallImg);
queryParams += "&pagearBigImg="+escape(pagearBigImg);
queryParams += "&pageearColor="+pageearColor;
queryParams += "&jumpTo="+escape(jumpTo);
queryParams += "&openLink="+escape(openLink);
queryParams += "&mirror="+escape(mirror);
queryParams += "&copyright="+escape(copyright);
queryParams += "&speedSmall="+escape(speedSmall);
queryParams += "&openOnLoad="+escape(openOnLoad);
queryParams += "&closeOnLoad="+escape(closeOnLoad);
queryParams += "&setDirection="+escape(setDirection);
queryParams += "&softFadeIn="+escape(softFadeIn);</script>


Code (Find) Select
</body></html>

Code (Replace) Select
';

if ($modSettings['pageear_enable'])
echo'
    <script type="text/javascript">
    writeObjects();
    </script>';
echo'
</body></html>



FOR 2.0

Code (Find) Select
// Output any remaining HTML headers. (from mods, maybe?)

Code (Add Before) Select
if($modSettings['pageear_enable'])
echo '
<script type="text/javascript" src="', $settings['default_theme_url'],'/scripts/pageear/AC_OETags.js"></script>
<script type="text/javascript" src="', $settings['default_theme_url'], '/scripts/pageear/pageear.js"></script>
<script type="text/javascript">
var pagearSmallImg = "', $modSettings['pageear_surl'], '";
var pagearSmallSwf = "', $settings['default_theme_url'], '/scripts/pageear/pageear_s.swf";
var pagearBigImg = "', $modSettings['pageear_burl'], '";
var pagearBigSwf = "', $settings['default_theme_url'], '/scripts/pageear/pageear_b.swf";
var speedSmall = "3";
var mirror = "', (empty($modSettings['pageear_mirror_effect']) ? 'false' : 'true'), '";
var pageearColor = "ffffff";
var jumpTo = "', $modSettings['pageear_jump_to'], '"
var openLink = "', $modSettings['pageear_open_new'], '";
var openOnLoad = "', (empty($modSettings['pageear_on_load']) ? 'false' : $modSettings['pageear_on_load']), '";
var closeOnLoad = "', $modSettings['pageear_close_onload'], '";
var setDirection = "', (empty($modSettings['pageear_lt']) ? 'rt' : 'lt' ), '";
var softFadeIn = "', $modSettings['pageear_soft_fade'], '";
var requiredMajorVersion = "6";
var requiredMinorVersion = "0";
var requiredRevision = "0";
var copyright = "Webpicasso Media, www.webpicasso.de";
var thumbWidth  = "100";
var thumbHeight = "100";
var bigWidth  = "500";
var bigHeight = "500";
var xPos = "right";
var queryParams = "pagearSmallImg="+escape(pagearSmallImg);
queryParams += "&pagearBigImg="+escape(pagearBigImg);
queryParams += "&pageearColor="+pageearColor;
queryParams += "&jumpTo="+escape(jumpTo);
queryParams += "&openLink="+escape(openLink);
queryParams += "&mirror="+escape(mirror);
queryParams += "&copyright="+escape(copyright);
queryParams += "&speedSmall="+escape(speedSmall);
queryParams += "&openOnLoad="+escape(openOnLoad);
queryParams += "&closeOnLoad="+escape(closeOnLoad);
queryParams += "&setDirection="+escape(setDirection);
queryParams += "&softFadeIn="+escape(softFadeIn);</script>';


Code (Find) Select
</body></html>

Code (Replace) Select

', ($modSettings['pageear_enable'] ? '<script type="text/javascript">
writeObjects();
</script>' : '') , '</body></html>


Change Log
1.0
- Initial release.
1.1
- Fixed a mistake when not showing in message index (Thanks mashby)
-  Added Enable/disable feature.
2.0
- Added 2.0 support.
2.1
- Fixed a bug that caused an 'Undefined index' error in the error log.
- Added UTF-8 support.

Angelotus

Except for advertising, what can it be used for?

KiLLuMiNaTi-7-

Display an announcement maybe  :)

Angelotus

Nice, will there be a version for smf 2.0 soon?

KiLLuMiNaTi-7-

I'm still learning the basics of 2.0. So in the near future maybe ;)

Angelotus

Good job! Thanks! Will wait for the 2.0 version!

TheDisturbedOne

Where are the edits (what template?)
Also I went on your website, and it doesn't seem to work for me (It is the same website as the one you took a screen shot of in the MOD)

Thanks

cerberos

#7
Hello my friend :)

Nice that u iplemented :) I will test it right away, and write any comments after.

Except of Advertisments, the pagepeel is ideal for Announcements or Special Articles from your Main Site in your forum !!

Ps

True, in what template do we have to do the edits?

djaca

I have SMF 1.1.5 and show me an error:

1.     Execute Modification     ./Themes/default/languages/Modifications.english.php     Test successful
2.    Execute Modification    ./Sources/ModSettings.php    Test failed
3.    Execute Modification    ./Themes/default/index.template.php    Test successful
4.    Extract Tree    ./pageear   
5.    Execute Code    install.php

TheDisturbedOne


KiLLuMiNaTi-7-

Quote from: willielwgg on August 07, 2008, 09:34:48 AM
Where are the edits (what template?)
Also I went on your website, and it doesn't seem to work for me (It is the same website as the one you took a screen shot of in the MOD)

Thanks

Sorry I forgot to include it.

Index.template.php

Quote from: djaca on August 07, 2008, 09:50:52 AM
I have SMF 1.1.5 and show me an error:

1.     Execute Modification     ./Themes/default/languages/Modifications.english.php     Test successful
2.    Execute Modification    ./Sources/ModSettings.php    Test failed
3.    Execute Modification    ./Themes/default/index.template.php    Test successful
4.    Extract Tree    ./pageear   
5.    Execute Code    install.php

I've uploaded a new version. Uninstall the old version or delete it if you haven't installed it yet. Then download and try the new one. Here

cerberos

Hello.

I did all the changes (yes the updated version, didnt have any error) but i cant see anything :(

http://mysamurai.eu/forum/index.php

djaca

Quote from: KiLLuMiNaTi-7- on August 07, 2008, 10:48:58 AM
Quote from: willielwgg on August 07, 2008, 09:34:48 AM
Where are the edits (what template?)
Also I went on your website, and it doesn't seem to work for me (It is the same website as the one you took a screen shot of in the MOD)

Thanks

Sorry I forgot to include it.

Index.template.php

Quote from: djaca on August 07, 2008, 09:50:52 AM
I have SMF 1.1.5 and show me an error:

1.     Execute Modification     ./Themes/default/languages/Modifications.english.php     Test successful
2.    Execute Modification    ./Sources/ModSettings.php    Test failed
3.    Execute Modification    ./Themes/default/index.template.php    Test successful
4.    Extract Tree    ./pageear   
5.    Execute Code    install.php

I've uploaded a new version. Uninstall the old version or delete it if you haven't installed it yet. Then download and try the new one. Here


It worked...

Thanks!!

evil-angelist

Naughty you ;)

Im getting this message:

SMF Version 1.1.5 here

The package you tried to upload either is not a valid package or has become corrupted.

Maybe its just me but if there is some problem could this be checked out.

Thanks ;)


KiLLuMiNaTi-7-

#14
Quote from: cerberos on August 07, 2008, 12:26:44 PM
Hello.

I did all the changes (yes the updated version, didnt have any error) but i cant see anything :(

http://mysamurai.eu/forum/index.php

Code (Find) Select
<script src="http://mysamurai.eu/forum/pageear/pageear.js" type="text/javascript"></script>  <script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[ var pagearSmallImg = "http://mysamurai.eu/forum/pageear/images/pageear_s.jpg"; var pagearSmallSwf = "pageear/pageear_s.swf"; var pagearBigImg = "http://mysamurai.eu/forum/pageear/images/pageear_b.jpg"; var pagearBigSwf = "pageear/pageear_b.swf"; var speedSmall = "3"; var mirror = "true"; var pageearColor = "ffffff"; var jumpTo = "http://mysamurai.eu/forum" var openLink = "new"; var openOnLoad = "0.1"; var closeOnLoad = "10"; var setDirection = "rt"; var softFadeIn = "1"; var requiredMajorVersion = "6"; var requiredMinorVersion = "0"; var requiredRevision = "0"; var copyright = "Webpicasso Media, www.webpicasso.de"; var thumbWidth = "100"; var thumbHeight = "100"; var bigWidth = "500"; var bigHeight = "500"; var xPos = "right"; var queryParams = "pagearSmallImg="+escape(pagearSmallImg); queryParams += "&pagearBigImg="+escape(pagearBigImg); queryParams += "&pageearColor="+pageearColor; queryParams += "&jumpTo="+escape(jumpTo); queryParams += "&openLink="+escape(openLink); queryParams += "&mirror="+escape(mirror); queryParams += "&copyright="+escape(copyright); queryParams += "&speedSmall="+escape(speedSmall); queryParams += "&openOnLoad="+escape(openOnLoad); queryParams += "&closeOnLoad="+escape(closeOnLoad); queryParams += "&setDirection="+escape(setDirection); queryParams += "&softFadeIn="+escape(softFadeIn); // ]]></script>

Code (Replace) Select


<script language="javascript" type="text/javascript" src="', $boardurl, '/pageear/AC_OETags.js"></script>
<script src="', $boardurl, '/pageear/pageear.js" type="text/javascript"></script>
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var pagearSmallImg = "', $modSettings['pageear_small_url'], '";
var pagearSmallSwf = "pageear/pageear_s.swf";
var pagearBigImg = "', $modSettings['pageear_big_url'], '";
var pagearBigSwf = "pageear/pageear_b.swf";
var speedSmall = "3"; var mirror = "', $modSettings['pageear_mirror'], '";
var pageearColor = "ffffff"; var jumpTo = "', $modSettings['pageear_jumpto'], '"
var openLink = "', $modSettings['pageear_opennew'], '";
var openOnLoad = "', $modSettings['pageear_onload'], '";
var closeOnLoad = "', $modSettings['pageear_pageear_closeonload'], '";
var setDirection = "', $modSettings['pageear_rtlt'], '";
var softFadeIn = "', $modSettings['pageear_softfade'], '";
var requiredMajorVersion = "6"; var requiredMinorVersion = "0";
var requiredRevision = "0";
var copyright = "Webpicasso Media, www.webpicasso.de";
var thumbWidth = "100"; var thumbHeight = "100";
var bigWidth = "500"; var bigHeight = "500";
var xPos = "right";
var queryParams = "pagearSmallImg="+escape(pagearSmallImg); queryParams += "&pagearBigImg="+escape(pagearBigImg); queryParams += "&pageearColor="+pageearColor; queryParams += "&jumpTo="+escape(jumpTo); queryParams += "&openLink="+escape(openLink); queryParams += "&mirror="+escape(mirror); queryParams += "&copyright="+escape(copyright); queryParams += "&speedSmall="+escape(speedSmall); queryParams += "&openOnLoad="+escape(openOnLoad); queryParams += "&closeOnLoad="+escape(closeOnLoad); queryParams += "&setDirection="+escape(setDirection); queryParams += "&softFadeIn="+escape(softFadeIn); // ]]></script>

KiLLuMiNaTi-7-

Quote from: evil-angelist on August 07, 2008, 01:54:57 PM
Naughty you ;)

Im getting this message:

SMF Version 1.1.5 here

The package you tried to upload either is not a valid package or has become corrupted.

Maybe its just me but if there is some problem could this be checked out.

Thanks ;)



Umm. Not sure what that could be...Have you tried downloading it again?


evil-angelist

#16
Quote from: KiLLuMiNaTi-7- on August 07, 2008, 02:12:50 PM
Quote from: evil-angelist on August 07, 2008, 01:54:57 PM
Naughty you ;)

Im getting this message:

SMF Version 1.1.5 here

The package you tried to upload either is not a valid package or has become corrupted.

Maybe its just me but if there is some problem could this be checked out.

Thanks ;)



Umm. Not sure what that could be...Have you tried downloading it again?


Yes I have, do you have a test site to try it again, if not or someone says that it is working fine later I will try the custom installer try the package parser to manually install.

Thanks anyway for the quick response 10/10.

cerberos

#17
Ok fixed :) Its worked like a charm --> www.mysamurai.eu/forum

Some Additions that i think will be good to have (dont know if they can implemented somehow)

a) I think an on / off action, will be handy :) So we can switch it off when we want

b) In the joomla version of it, it had an option to open the page (i mean the torn page) more. So to have a bigger picture (bigger small and bigger big one) in it. Dont know if this can be done.

c) Will be handy also, to be able to have more than one images. And load in every refresh, one of them. So to have many points of interest there, for your users if its articles or advertisments. I assume this can be done with Swf, but the user must know flash, and its prob:P)

Thats all i can think right now :)

Ty again !!

mashby

Absolutely fantastic mod!!! I concur with cerberos...an on/off feature would make this REALLY awesome! Thanks for this one!
Always be a little kinder than necessary.
- James M. Barrie

Sabre™

#19
Great mod!
I agree with the above two, that an on off switch would be a good addition.

Now...
Could someone pleeeaase tell me how to edit my own stuff in it!?? lol

An example to work from would be great!

Thank You in advance :)

P.s.
How could we make this ONLY visible, when user is logged?
Do NOT give admin and/or ftp details to just anybody, see if they are trust worthy first!!  Do your homework ;)


Advertisement: