Reply button
2 posters
Page 1 of 1
Reply button
Can I add another reply button over my quick reply box? Another, I don't want to move the one I have now. I want to add a big CLICK HERE TO REPLY at the bottom, anyone?
Re: Reply button
Hi @Wealh,
Yes, it should be possible. Go to Modules > JavaScript codes management and create a new script with the following settings.
Placement : In all the pages
Then, you can style the texts with this CSS :
For other stylistic changes, you may need to select the anchor instead. Like this :
Yes, it should be possible. Go to Modules > JavaScript codes management and create a new script with the following settings.
Placement : In all the pages
- Code:
$(function() {
var quick = document.anchors.quickreply,
container;
if (quick) {
container = document.createElement('DIV');
container.innerHTML = '<a href="/post?t=' + window.location.href.replace(/.*?\/t(\d+).*/, '$1') + '&mode=reply">CLICK HERE TO REPLY</a>';
container.id = 'topic_reply';
quick.parentNode.insertBefore(container, quick);
}
});
Then, you can style the texts with this CSS :
- Code:
#topic_reply {
text-align:center;
font-size:16px;
font-weight:bold;
}
For other stylistic changes, you may need to select the anchor instead. Like this :
|
Re: Reply button
Ange Tuteur wrote:Hi @Wealh,
Yes, it should be possible. Go to Modules > JavaScript codes management and create a new script with the following settings.
Placement : In all the pages
- Code:
$(function() {
var quick = document.anchors.quickreply,
container;
if (quick) {
container = document.createElement('DIV');
container.innerHTML = '<a href="/post?t=' + window.location.href.replace(/.*?\/t(\d+).*/, '$1') + '&mode=reply">CLICK HERE TO REPLY</a>';
container.id = 'topic_reply';
quick.parentNode.insertBefore(container, quick);
}
});
Then, you can style the texts with this CSS :
- Code:
#topic_reply {
text-align:center;
font-size:16px;
font-weight:bold;
}
For other stylistic changes, you may need to select the anchor instead. Like this :
- Code:
#topic_reply a
Thanks! I have another problem: it doesn't appear for the guests. I want only guests to see it.
Re: Reply button
Oh, we'll need to replace
since it doesn't show for guests. Do you have a link to the page that I can look at ?
|
Re: Reply button
Ange Tuteur wrote:Oh, we'll need to replacesince it doesn't show for guests. Do you have a link to the page that I can look at ?
- Code:
document.anchors.quickreply
What page?
Re: Reply button
A link to a topic on your forum. I don't know the forum version I'm working with, so I'm not sure what I'll need to modify in the code now.
Re: Reply button
Ange Tuteur wrote:A link to a topic on your forum. I don't know the forum version I'm working with, so I'm not sure what I'll need to modify in the code now.
http://boredom.iftopic.com/t3-suicide-mouse
Re: Reply button
Try this :
It should make it display for guests only.
- Code:
$(function() {
var quick = document.getElementById('pun-info'),
container;
if (quick && !_userdata.user_level) {
container = document.createElement('DIV');
container.innerHTML = '<a href="/post?t=' + window.location.href.replace(/.*?\/t(\d+).*/, '$1') + '&mode=reply">CLICK HERE TO REPLY</a>';
container.id = 'topic_reply';
quick.parentNode.insertBefore(container, quick.previousSibling);
}
});
It should make it display for guests only.
Re: Reply button
Ange Tuteur wrote:Try this :
- Code:
$(function() {
var quick = document.getElementById('pun-info'),
container;
if (quick && !_userdata.user_level) {
container = document.createElement('DIV');
container.innerHTML = '<a href="/post?t=' + window.location.href.replace(/.*?\/t(\d+).*/, '$1') + '&mode=reply">CLICK HERE TO REPLY</a>';
container.id = 'topic_reply';
quick.parentNode.insertBefore(container, quick.previousSibling);
}
});
It should make it display for guests only.
Awesome, thanks!
Re: Reply button
You're welcome ^^
Topic archived
If any problems feel free to open a new topic. Have a good day.
Topic archived
If any problems feel free to open a new topic. Have a good day.
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum