The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Ajax Reply to Visitor Message from your Own Profile Details »» | |||||||||||||||||||||||||||
Ajax Reply to Visitor Message from your Own Profile
Developer Last Online: Aug 2013
I will present you a modification I did to my own forum:
You can reply to your visitor messages from your own profile. I didnt create a plugin, so you will need to do 2 simple templates modifications and upload 2 files. Installation 1. Upload the files to a folder "visitorReply" (you must create it) inside your forum folder (there is a success message in the visitorReply.js file, that you should translate to your own language) 2. Edit the template MEMBERINFO: Find: Code:
</head> Code:
<!-- ccv modification --> <script type="text/javascript" src="visitorReply/visitorReply.js"></script> <!-- ccv modification --> 3. Edit the template memberinfo_visitormessage: Find: Code:
<ul class="list_no_decoration controls"> Code:
<!-- ccv modification --> <if condition="$bbuserinfo[userid] == $userinfo[userid] && THIS_SCRIPT == 'member'"> <li class="smallfont"><a name="#link$message[vmid]" id="#link$message[vmid]" href="#link$message[vmid]" title="Reply" onclick="openVisitorReply($message[vmid], $message[postuserid], $userinfo[userid], '$bbuserinfo[securitytoken]', $bbuserinfo[userid])">Reply</a></li> </if> <!-- ccv modification --> Code:
<!-- ccv modification --> <div id="$message[vmid]"></div> <!-- ccv modification --> I will try to support, you can find me at my forum too. I speak english (not very well, but i think its understandable ), french and portuguese. I have just started to use it on my forums now, so its beta (beta is the fashion word of the moment) And, because the template visitormessage has already an external form (inline moderation of the messages), i had to put the reply form into an inframe. And I dont know how to use the vbulletin ajax, so I made it from my own ajax mode regards Show Your Support
|
Благодарность от: | ||
caoducanh9x |
Comments |
#12
|
|||
|
|||
can you send a link to your board, so I can test?
ps: boa Leo, sabia q a torcida palmeirense ia gostar |
#13
|
|||
|
|||
Awesome!!!! Thanks, CCV.
MOTM! |
#14
|
|||
|
|||
good job pinto ^^
|
#15
|
||||
|
||||
let me test...
Thanks for this idea.. I wish.It should be built in with VB.. |
#16
|
||||
|
||||
Working perfect for me...
|
#17
|
||||
|
||||
So when can you have a product done? PLEASE!!!
|
#18
|
||||
|
||||
QUESTION:
How can we get the basic editor to display when making the replies? We need at least the basic editor buttons. It would be nice to also have a go advanced button as well. SUGGESTION: You need to make a cancel button that closes the ajax! If you decide not to type a reply and you want to make another reply you will get multiple opened message windows. You need to have the message background be a little gray. How can I change the background of the message text area? Great idea please keep developing this! |
#19
|
|||
|
|||
1 - the basic editor buttons would be a nice feature, I would have to investigate it a litle. The button to advanced mode i think is easy to implement (I would need just to copy the code from the template to my visitorReply.php)
2 - to create a cancel button, you can add this to the step 3 (inside the if, after the first li tag , I didnt test it, but its simple, it should work): Code:
<li class="smallfont"><a href="#link$message[vmid]" title="Close" onclick="document.getElementById($message[vmid]).style.display = 'none'">Close</a></li> Code:
function openVisitorReply(id, user, user2, securitytoken, userid) { if(document.getElementById(id) != null){ document.getElementById(id).innerHTML = "<iframe name=\"iframe"+id+"\" scrolling=\"no\" align='center' style=\"border: 0;\" id=\"iframe"+id+"\" src=\"./visitorReply/visitorReply.php?u="+user+"&u2="+user2+"&securitytoken="+securitytoken+"&userid="+userid+"&id="+id+"\" width=\"100%\" height=\"100\"></iframe>"; document.getElementById($message[vmid]).style.display = 'block'; } } style="background:#COLORHERE" If I have same time I will update this... but I think I wont make it a product, because it already took me a few hours trying it... |
#20
|
||||
|
||||
I am looking forward to the update!
I will try your suggested edits and report back. THANKS! |
#21
|
||||
|
||||
I tried your suggested edits to get the Close button. A few things:
|
Thread Tools | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|