How can I add a template for my forum?
3 posters
Page 1 of 1
How can I add a template for my forum?
How can i add my own custom template for this: http://galacticda.forumotion.com/f1-test-results
like the template for a graphic request
like the template for a graphic request
Last edited by Xnomejx on January 1st 2014, 7:17 pm; edited 1 time in total
Re: How can I add a template for my forum?
Hello ,
It should be as simple as writing a field and wrapping it with bbcode.
example :
It should be as simple as writing a field and wrapping it with bbcode.
example :
- Code:
[color=#33cc33][b]Field 1[/b][/color]:
[color=#33cc33][b]Field 2[/b][/color]:
[color=#33cc33][b]Field 3[/b][/color]:
Re: How can I add a template for my forum?
i know its something like that but, how can i just add those instead of people copy and pasting?
Re: How can I add a template for my forum?
You would need to apply a script for a specific forum.
Example :
You must change the underlined value with the ID of your sub forum :
('/post?f=33&mode=newtopic')
You can see the ID of the sub forum from the address bar while viewing it.
Once you have done that you can edit the template.
Line breaks MUST NOT be used otherwise the code will not work. As seen above to apply a line break you must write \n after your field.
To apply your script :
Administration Panel > Modules > HTML & JAVASCRIPT > Javascript codes management > create a new script
The script must be ran 'in all the pages' for it to work.
On creation of a new topic in that forum the template should be added to the editor.
Example :
- Code:
jQuery(function() {
if (document.location.href.indexOf('/post?f=33&mode=newtopic') > -1) {
jQuery('#text_editor_textarea').text('[b]Website Name[/b]:\n[b]Web Address[/b]:\n[b]Language[/b]:\n[b]Description[/b]:');
}
});
You must change the underlined value with the ID of your sub forum :
('/post?f=33&mode=newtopic')
You can see the ID of the sub forum from the address bar while viewing it.
Once you have done that you can edit the template.
- Code:
[b]Website Name[/b]:\n[b]Web Address[/b]:\n[b]Language[/b]:\n[b]Description[/b]:
Line breaks MUST NOT be used otherwise the code will not work. As seen above to apply a line break you must write \n after your field.
To apply your script :
Administration Panel > Modules > HTML & JAVASCRIPT > Javascript codes management > create a new script
The script must be ran 'in all the pages' for it to work.
On creation of a new topic in that forum the template should be added to the editor.
Re: How can I add a template for my forum?
- Code:
jQuery(function() {
if (document.location.href.indexOf('post?f=1&mode=newtopic') > -1) {
jQuery('#text_editor_textarea').text('[color=#33ffff][b]Results:[/b][/color]
[color=#ffffff](Tester's name) vs (Testee's name)[/color]
[color=#ffffff](Tester's deck) vs (Testee's deck)[/color]
[b][color=#ffffff]Duel Result:[/color][/b][color=#ffffff] Testee [0/1/2] - [0/1/2] Tester[/color]
[color=#33ffff][b]Deck:[/b][/color]
[b][color=#ffffff]Deck Build:[/color][/b][color=#ffffff] x/10 (NOT judging originality, but judging how well the cards in the deck and eventual techs work together)[/color]
[b][color=#ffffff]Side Deck:[/color][/b][color=#ffffff] x/10 (again, NOT judging originality, but how the side deck works against the most played decks this format and whether it has good or bad cards to side)[/color]
[color=#33ffff][b]Gameplay & Concentration:[/b][/color]
[b][color=#ffffff]Use of cards:[/color][/b][color=#ffffff] x/5 (considering testee's opening hand. A screenshot of your starting hand may be asked at the start of the duel for a more accurate evaluation)[/color]
[b][color=#ffffff]Siding skills:[/color][/b][color=#ffffff] x/5 (how the cards that the testee sided work against the tester's deck. A screenshot may be asked during siding to better see which cards you sided. The screenshot has to be given at the end of the match)[/color]
[b][color=#ffffff]Performance:[/color][/b][color=#ffffff] x/10 (number of misplays that the tester caught, general playstyle of the testee, etc. This also includes concentration, meaning that the tester CAN make minor illegal plays and give the testee time to catch them, HOWEVER the tester WILL have to tell the testee about the illegal play and will have to fix it before the game proceeds. This is to avoid cheated wins by the tester)[/color]
[b][color=#ffffff]Ruling Test:[/color][/b][color=#ffffff] x/10 (1 for each correct answer)[/color]
[color=#ffffff]We have a ruling test that consists of 10 questions.[/color]
[color=#ffffff]The test is located here:[/color][url=https://testmoz.com/237936][color=#333333]https://testmoz.com/237936[/color][/url][url=https://testmoz.com/237936][/url]
[color=#ffffff]Your tester will give you the login information after your match. You will have 70 minutes to complete the test. All reports that exceed the 70 minute time limit will be considered null, and will be graded 0.[/color]
[color=#33ffff][b]Total Score:[/b][/color][color=#ffffff] x/50[/color]
[b][color=#ffffff]Welcome to [color=#ff3333]Slifer[/color]/[color=#ffcc33]Ra[/color]/[color=#3366ff]Obelisk[/color]![/color][/b]
[b][color=#ffffff][color=#ff3333]Slifer[/color][/color][/b][color=#ffffff]: 0-20 pts.[/color]
[b][color=#ffffff][color=#ffcc33]Ra[/color][/color][/b][color=#ffffff]: 21-40 pts.[/color]
[b][color=#ffffff][color=#3366ff]Obelisk[/color][/color][/b][color=#ffffff]: 41-50 pts.[/color]:');
}
});
Is that correct?
Re: How can I add a template for my forum?
Have tried adding it and see if it works?
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: How can I add a template for my forum?
Your code doe snot look like this:
- Code:
[b]Website Name[/b]:\n[b]Web Address[/b]:\n[b]Language[/b]:\n[b]Description[/b]:
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: How can I add a template for my forum?
Between each line break you have to use this: /n
The way you have them now, the code will treat it as one long line.
The way you have them now, the code will treat it as one long line.
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: How can I add a template for my forum?
The code will take along time to change because it is very long
Re: How can I add a template for my forum?
- Code:
jQuery(function() {
if (document.location.href.indexOf('post?f=1&mode=newtopic') > -1) {
jQuery('#text_editor_textarea').text('[color=#33ffff][b]Results:[/b][/color]\n[color=#ffffff](Tester's name) vs (Testee's name)[/color]\n
[color=#ffffff](Tester's deck) vs (Testee's deck)[/color]\n [b][color=#ffffff]Duel Result:[/color][/b]\n[color=#ffffff] Testee [0/1/2] - [0/1/2] Tester[/color]\n\n[color=#33ffff][b]Deck:[/b][/color]\n [b][color=#ffffff]Deck Build:[/color][/b]\n[color=#ffffff] x/10 (NOT judging originality, but judging how well the cards in the deck and eventual techs work together)[/color]\n[b][color=#ffffff]Side Deck:[/color][/b]\n[color=#ffffff] x/10 (again, NOT judging originality, but how the side deck works against the most played decks this format and whether it has good or bad cards to side)[/color]\n\n [color=#33ffff][b]Gameplay & Concentration:[/b][/color]\n [b][color=#ffffff]Use of cards:[/color][/b]\n[color=#ffffff] x/5 (considering testee's opening hand. A screenshot of your starting hand may be asked at the start of the duel for a more accurate evaluation)[/color]\n[b][color=#ffffff]Siding skills:[/color][/b]\n[color=#ffffff] x/5 (how the cards that the testee sided work against the tester's deck. A screenshot may be asked during siding to better see which cards you sided. The screenshot has to be given at the end of the match)[/color]\n[b][color=#ffffff]Performance:[/color][/b]\n[color=#ffffff] x/10 (number of misplays that the tester caught, general playstyle of the testee, etc. This also includes concentration, meaning that the tester CAN make minor illegal plays and give the testee time to catch them, HOWEVER the tester WILL have to tell the testee about the illegal play and will have to fix it before the game proceeds. This is to avoid cheated wins by the tester)[/color]\n\n[b][color=#ffffff]Ruling Test:[/color][/b]\n[color=#ffffff] x/10 (1 for each correct answer)[/color]\n[color=#ffffff]We have a ruling test that consists of 10 questions.[/color]\n[color=#ffffff]The test is located here:[/color][url=https://testmoz.com/237936][color=#333333]https://testmoz.com/237936[/color][/url][url=https://testmoz.com/237936][/url]\n [color=#ffffff]Your tester will give you the login information after your match. You will have 70 minutes to complete the test. All reports that exceed the 70 minute time limit will be considered null, and will be graded 0.[/color]\n\n[color=#33ffff][b]Total Score:[/b][/color][color=#ffffff] x/50[/color]\n\n[b][color=#ffffff]Welcome to [color=#ff3333]Slifer[/color]/[color=#ffcc33]Ra[/color]/[color=#3366ff]Obelisk[/color]![/color][/b]\n\n[b][color=#ffffff][color=#ff3333]Slifer[/color][/color][/b]\n[color=#ffffff]: 0-20 pts.[/color]\n[b][color=#ffffff][color=#ffcc33]Ra[/color][/color][/b][color=#ffffff]: 21-40 pts.[/color]\n[b][color=#ffffff][color=#3366ff]Obelisk[/color][/color][/b][color=#ffffff]: 41-50 pts.[/color]:');
}
});
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: How can I add a template for my forum?
I have tried this. Nothing happens on the post reply on the specific forum
Re: How can I add a template for my forum?
What did you check: in topics, in subforums, etc.?
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: How can I add a template for my forum?
Try in subforums?
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: How can I add a template for my forum?
In all pages
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: How can I add a template for my forum?
Try using your code that you created.
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: How can I add a template for my forum?
Hello ,
The reason the script is not working is because you written a single quote and our string is set between two single quotes. If you use a single quote and do not add a slash before it then it will be treated as if the string was closed. Additionally it will make the script inactive.
simply write it as :
don\'t it\'s \'
Name : what you wish
Placement : in all the pages
The reason the script is not working is because you written a single quote and our string is set between two single quotes. If you use a single quote and do not add a slash before it then it will be treated as if the string was closed. Additionally it will make the script inactive.
simply write it as :
don\'t it\'s \'
Name : what you wish
Placement : in all the pages
- Code:
jQuery(function() {
if (document.location.href.indexOf('post?f=1&mode=newtopic') > -1) {
jQuery('#text_editor_textarea').text('[color=#33ffff][b]Results:[/b][/color]\n[color=#ffffff](Tester\'s name) vs (Testee\'s name)[/color]\n[color=#ffffff](Tester\'s deck) vs (Testee\'s deck)[/color]\n[b][color=#ffffff]Duel Result:[/color][/b]\n[color=#ffffff] Testee [0/1/2] - [0/1/2] Tester[/color]\n\n[color=#33ffff][b]Deck:[/b][/color]\n[b][color=#ffffff]Deck Build:[/color][/b]\n[color=#ffffff] x/10 (NOT judging originality, but judging how well the cards in the deck and eventual techs work together)[/color]\n[b][color=#ffffff]Side Deck:[/color][/b]\n[color=#ffffff] x/10 (again, NOT judging originality, but how the side deck works against the most played decks this format and whether it has good or bad cards to side)[/color]\n\n[color=#33ffff][b]Gameplay & Concentration:[/b][/color]\n[b][color=#ffffff]Use of cards:[/color][/b]\n[color=#ffffff] x/5 (considering testee\'s opening hand. A screenshot of your starting hand may be asked at the start of the duel for a more accurate evaluation)[/color]\n[b][color=#ffffff]Siding skills:[/color][/b]\n[color=#ffffff] x/5 (how the cards that the testee sided work against the tester\'s deck. A screenshot may be asked during siding to better see which cards you sided. The screenshot has to be given at the end of the match)[/color]\n[b][color=#ffffff]Performance:[/color][/b]\n[color=#ffffff] x/10 (number of misplays that the tester caught, general playstyle of the testee, etc. This also includes concentration, meaning that the tester CAN make minor illegal plays and give the testee time to catch them, HOWEVER the tester WILL have to tell the testee about the illegal play and will have to fix it before the game proceeds. This is to avoid cheated wins by the tester)[/color]\n\n[b][color=#ffffff]Ruling Test:[/color][/b]\n[color=#ffffff] x/10 (1 for each correct answer)[/color]\n[color=#ffffff]We have a ruling test that consists of 10 questions.[/color]\n[color=#ffffff]The test is located here:[/color][url=https://testmoz.com/237936][color=#333333]https://testmoz.com/237936[/color][/url][url=https://testmoz.com/237936][/url]\n[color=#ffffff]Your tester will give you the login information after your match. You will have 70 minutes to complete the test. All reports that exceed the 70 minute time limit will be considered null, and will be graded 0.[/color]\n\n[color=#33ffff][b]Total Score:[/b][/color][color=#ffffff] x/50[/color]\n\n[b][color=#ffffff]Welcome to [color=#ff3333]Slifer[/color]/[color=#ffcc33]Ra[/color]/[color=#3366ff]Obelisk[/color]![/color][/b]\n\n[b][color=#ffffff][color=#ff3333]Slifer[/color][/color][/b]\n[color=#ffffff]: 0-20 pts.[/color]\n[b][color=#ffffff][color=#ffcc33]Ra[/color][/color][/b][color=#ffffff]: 21-40 pts.[/color]\n[b][color=#ffffff][color=#3366ff]Obelisk[/color][/color][/b][color=#ffffff]: 41-50 pts.[/color]:');
}
});
Re: How can I add a template for my forum?
Ange, I have tried the code that you provided me, but theres still a issue. Nothing showes up.
Re: How can I add a template for my forum?
Do you have other JavaScripts? If you do, remove the others and see if the code works.
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: How can I add a template for my forum?
Topic Solved & Locked
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Similar topics
» Template
» Name of template
» + Template why I was not there?
» How can I add "Add to favorites" in template?
» sidebar template
» Name of template
» + Template why I was not there?
» How can I add "Add to favorites" in template?
» sidebar template
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum