Any way to make custom macros?
2 posters
Page 1 of 1
Any way to make custom macros?
I'd like to make my own "shortcode". What I'm most interested in is a quick way to post a link to a specific user.
Ideally, I could write {u1234} and have it replaced by their name as a hyperlink to their profile, preferably in the same font style as it is normally displayed. For example, if I wrote a post that said
Any idea if such a modification to my forum is possible with jQuery? If not, do you think it's worth suggesting to Forumotion?
Ideally, I could write {u1234} and have it replaced by their name as a hyperlink to their profile, preferably in the same font style as it is normally displayed. For example, if I wrote a post that said
- Code:
Just send a message to {u79071}. He should be able to help.
Just send a message to SheepEffect. He should be able to help.
Any idea if such a modification to my forum is possible with jQuery? If not, do you think it's worth suggesting to Forumotion?
Re: Any way to make custom macros?
You could create a close effect, but it would be differcult to get the username to appear.
You could turn it into a link easily though.
You could turn it into a link easily though.
- Code:
$(function(){
$('.post').each(function() {
this.innerHTML = this.innerHTML.replace(/\b\{u(\d+)\}\b/g, '<a href="/u$1">User $1</a>');
});
});
LGforum- Hyperactive
- Posts : 2265
Reputation : 264
Language : English
Location : UK
Similar topics
» Macros?
» how do i make a custom favicon
» How to make a Custom Navbar
» How to make a custom theme
» How To Make Your Own Custom Page.
» how do i make a custom favicon
» How to make a Custom Navbar
» How to make a custom theme
» How To Make Your Own Custom Page.
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum