Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
New PM Popup Replacement Details »»
New PM Popup Replacement
Version: 2.5, by rossco_2005 rossco_2005 is offline
Developer Last Online: May 2013 Show Printable Version Email this Page

Version: 3.5.4 Rating:
Released: 07-25-2005 Last Update: 06-30-2006 Installs: 178
Uses Plugins Template Edits
Additional Files  
No support by the author.

[high]PLEASE CLICK INSTALL IF YOU INSTALL THIS[/high]

This mod changes the default New PM Popup to open a nice looking, closeable html popup within the page.

It tells you who sent the latest message as well as what the title is.

The window then gives you the option of viewing the message (in which case it opens another window and closes itself), viewing your inbox (again it will close the popup), or to just ignore the new message and close the New PM popup.

A screenshot is attached to show you what the popup will look like.

To install all you need to do is make 1 template edit to each of your skins, upload 1 XML plugin file, and upload 1 file with your ftp client.

[high]Installation[/high]

First go to your pm_popup_script template and replace it with this code:

HTML Code:
<script type="text/javascript" src="clientscript/fixed_position_ie.js"></script>
<script type='text/javascript'>
    var agtbrw=navigator.userAgent.toLowerCase();
    var operaaa=(agtbrw.indexOf('opera')!=-1);
    var head="display:''";
    var folder='';
    function expandit(curobj)
    {
        if(document.getElementById(curobj))
        {
            folder=document.getElementById(curobj).style;
        }
        else
        {
            if(ns6==1||operaaa==true)
            {
                folder=curobj.nextSibling.nextSibling.style;
            }
            else
            {
                folder=document.all[curobj.sourceIndex+1].style;
            }
        }
        if (folder.display=="none")
        {
            folder.display="";
        }
        else
        {
            folder.display="none";
        }
    }
</script>
<style type="text/css">
#pm_popup {
    position:fixed;
    top:250px;
    border:1px solid;
    width:64%;
    margin-right:18%;
    margin-left:18%;
}

</style>
<div id="pm_popup">
    <table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%">
        <tr>
            <td class="tcat">
                <span class="smallfont" style="float:$stylevar[right]">
                    <a href="#" onclick="expandit('pm_popup');">Close</a>
                </span>
                $vbphrase[new_private_msg]
            </td>
        </tr>
        <tr>
            <td class="panelsurround" align="center">
                <div class="panel">
                    <div align="center">
                        <table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
                            <tr>
                                <td>
                                    $vbphrase[newest_pm_from] <b>$newpm[fromusername]</b>, $vbphrase[titled]<b>'$newpm[title]'</b>
                                    <br />
                                </td>
                            </tr>
                            <if condition="$shownewpmpreview">
                            <tr>
                                <td class="smallfont" style="padding-top:20px;">
                                    $newpm[message]
                                </td>
                            </tr>
                            </if>
                            <tr>
                                <td align="center" style="padding-top:20px;">
                                    <a href="$vboptions[bburl]/private.php?do=showpm&pmid=$newpm[pmid]">$vbphrase[read_message]</a>
                                    (<a href="$vboptions[bburl]/private.php?do=showpm&pmid=$newpm[pmid]" target="_blank">
                                        <span class="smallfont">$vbphrase[open_new_window]</span>
                                    </a>)
                                    <br /><br />
                                    <a href="$vboptions[bburl]/private.php">$vbphrase[go_to_inbox]</a>
                                </td>
                            </tr>
                        </table>
                    </div>
                </div>
                <div style="margin-top:$stylevar[cellpadding]px">
                    <form>
                        <input type="button" class="button" value="$vbphrase[close_popup]" onclick="expandit('pm_popup');" />
                    </form>
                </div>
            </td>
        </tr>
    </table>
</div>
The above step will need to be done for each of your skins.

Next, go to the plugin manager:
Go to your admincp -> Expand Plugin System in the nav -> Click Manage Products -> Scroll to the bottom of the page and click Add/Import -> Browse to the xml file included in the zip -> upload

Now access your FTP and upload the attached 'fixed_position_ie.js' file to your clientscript/ folder. This js allows Internet Explorer to do fixed positioning meaning that the popup stays in place as you scroll the screen.

That's it, enjoy.

[high]How To Enable Preview[/high]
To enable the preview in the popup (view the screenshot to see what it looks like), just edit the plugin called "New PM Popup Window Preview" with the following instructions:
Go to your admincp -> Expand Plugin System in the nav -> Click Plugin Manager -> Click edit next to the "New PM Popup Window Preview" plugin

Now find, right at the top, this line:
$newpmoption['showpreview'] = false;

Change to:
$newpmoption['showpreview'] = true;


The preview is now enabled. To change how many characters are shown in the preview, go back to editing the plugin and change this line (near the top):
$newpmoption['maxcharacters'] = 100;


[high]To uninstall this hack just revert the pm_popup_script template then delete the uploaded file (/clientscript/fixed_position_ie.js) and the plugin.[/high]


Thanks to COBRAws for adding phrases.

Tested and works fully in the vB3.5 series (vb 3.5.0 ("Gold") up to 3.5.4).
Should work in vb3.6, the variables look to be the same.

This will probably work in vb3.0 series too but I don't remember if I've tested. I'm not promising.
If anyone wants to confirm that it fully works please PM me or post here.

Supporters / CoAuthors

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #212  
Old 03-14-2008, 02:55 PM
sbarbz sbarbz is offline
 
Join Date: Oct 2007
Location: israel
Posts: 80
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I installed the mod ..

But you will show where the window jump (image)

How it's possible to do that this will jump in middle of the page?
Reply With Quote
  #213  
Old 03-14-2008, 03:05 PM
MissKalunji's Avatar
MissKalunji MissKalunji is offline
 
Join Date: Aug 2003
Location: Canada
Posts: 2,845
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

in the code search for this

#pm_popup {
position:fixed;
top:250px;

and change where it says 250px to whatever you want higher the number lower it should be in the page
Reply With Quote
  #214  
Old 03-16-2008, 05:26 PM
sbarbz sbarbz is offline
 
Join Date: Oct 2007
Location: israel
Posts: 80
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by MissKalunji View Post
in the code search for this

#pm_popup {
position:fixed;
top:250px;

and change where it says 250px to whatever you want higher the number lower it should be in the page
There is there possibility are to change only you that are high that will appear the window, and there is not the width.
Quote:
#pm_popup {
position:fixed;
top:256px;
border:1px solid;
width:100%;
margin-right:18%;
margin-left:18%;
}
Reply With Quote
  #215  
Old 03-16-2008, 05:52 PM
MissKalunji's Avatar
MissKalunji MissKalunji is offline
 
Join Date: Aug 2003
Location: Canada
Posts: 2,845
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

arf? you don't want it to show in the middle of the page? sorry i didn't understand!?
Reply With Quote
  #216  
Old 03-17-2008, 03:15 AM
sbarbz sbarbz is offline
 
Join Date: Oct 2007
Location: israel
Posts: 80
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by MissKalunji View Post
arf? you don't want it to show in the middle of the page? sorry i didn't understand!?
I want, the problem is this appear at all of them!! Not in middle of.
Reply With Quote
  #217  
Old 03-17-2008, 06:48 PM
MissKalunji's Avatar
MissKalunji MissKalunji is offline
 
Join Date: Aug 2003
Location: Canada
Posts: 2,845
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by sbarbz View Post
I want, the problem is this appear at all of them!! Not in middle of.
It will Only appear One time in the page after that it will dissapear that's how it is with Vbulletin.

If you want it to show in every style : you have to do the same edit for every style

i've added this : https://vborg.vbsupport.ru/showthread.php?t=158527 cause people used to not notice they had pms
Reply With Quote
  #218  
Old 04-22-2008, 09:03 AM
Gooner Gooner is offline
 
Join Date: May 2007
Posts: 99
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

is this mod working with IE 7?
Reply With Quote
  #219  
Old 11-14-2008, 06:37 PM
powerful_rogue powerful_rogue is offline
 
Join Date: Jan 2007
Location: Kent
Posts: 603
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Has anyone tried this on 3.7 yet?
Reply With Quote
  #220  
Old 11-14-2008, 06:46 PM
powerful_rogue powerful_rogue is offline
 
Join Date: Jan 2007
Location: Kent
Posts: 603
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Seems to work on 3.7, however only with firefox.

It stretches the page with IE.

Such a shame
Reply With Quote
  #221  
Old 11-14-2008, 06:50 PM
MissKalunji's Avatar
MissKalunji MissKalunji is offline
 
Join Date: Aug 2003
Location: Canada
Posts: 2,845
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by MissKalunji View Post
The preview works!
im using this with Webforumz Template on 3.6.4
Thanks!

Now what would be cool is to have to kind of "reply"

Quick reply that pops a box and u can reply right there

and a full reply that sends you to private message would transform the whole private message to somewhat be like the vbpager but less server intensive no?
Quote:
Originally Posted by MissKalunji View Post
in the code search for this

#pm_popup {
position:fixed;
top:250px;

and change where it says 250px to whatever you want higher the number lower it should be in the page
<---

Quote:
Originally Posted by powerful_rogue View Post
Seems to work on 3.7, however only with firefox.

It stretches the page with IE.

Such a shame
I've been using it and i don't see it stretching up the page in IE?
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 11:10 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.09764 seconds
  • Memory Usage 2,333KB
  • Queries Executed 26 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_html
  • (7)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete