Keyword as prefix in title
4 posters
Page 1 of 1
Keyword as prefix in title
Hi! First of all thanks for your help and tutorials, they're very helpful.
Now my question is:
I followed the tutorial to use keyword as prefix, the one to write #TUTORIAL and make it show as a plate, i can'd find the tutorial on this forum, but i'll try to explain myself if u can't understand.
Anyway, my problem with that system is that users can insert a title like this "#TUTORIAL #TUTORIAL #TUTORIAL how to blablabla" to have 3 plates and the title.
Like u see, if I manually add "#TUTORIAL"
i'll get more plates
I wanna know how can limit the "plate option" to work only on the first "#", so the title in that case will be: "(plate) #TUTORIAL #TUTORIAL how to blablabla"
This is the code I used:
Javascript:
and CSS:
Now my question is:
I followed the tutorial to use keyword as prefix, the one to write #TUTORIAL and make it show as a plate, i can'd find the tutorial on this forum, but i'll try to explain myself if u can't understand.
Anyway, my problem with that system is that users can insert a title like this "#TUTORIAL #TUTORIAL #TUTORIAL how to blablabla" to have 3 plates and the title.
Like u see, if I manually add "#TUTORIAL"
i'll get more plates
I wanna know how can limit the "plate option" to work only on the first "#", so the title in that case will be: "(plate) #TUTORIAL #TUTORIAL how to blablabla"
This is the code I used:
Javascript:
- Code:
$(function() {
var c = document.querySelectorAll('h2.topic-title, h1.page-title');
for (i=0; i<c.length; i++) {
c[i].innerHTML = c[i].innerHTML.replace(/#TUTORIAL/g,'<span id="TUTORIAL">TUTORIAL</span>');
}
});
and CSS:
- Code:
#TUTORIAL {
background: #FFF;
padding: 0px 5px 1px 4px;
border-radius: 6px !important;
font-size: 11px;
float: left;
margin-right: 4px;
border: 1px solid #CCC;
box-shadow: 0px 1px 1px #FAFAFA;
}
Re: Keyword as prefix in title
Hello again @Simone Boi!
Read this tutorial: Topic prefix this code is better and the prefix only work once per topic title
Read this tutorial: Topic prefix this code is better and the prefix only work once per topic title
TonnyKamper and Simone Boi like this post
Re: Keyword as prefix in title
pedxz wrote:Helloagain@Simone Boi!
Read this tutorial: Topic prefix this code is better and the prefix only work once per topic title
Hi! Thanks for the tips, i could try that, but i was looking for a "scroll-choice", the tutorial u linked me is a little ugly, still helpful, but i don't know how to change to a scroll choice.
Anyway thanks again!
_____________________________________
And I have this bug with that
Re: Keyword as prefix in title
as i said already
https://aiuto.forumattivo.it/t20562-problema-prefissi-topic-keyword
this topic will be locked
Please do not open similar threads to multiple support forums.
|
https://aiuto.forumattivo.it/t20562-problema-prefissi-topic-keyword
this topic will be locked
Re: Keyword as prefix in title
@Simone Boi This is your last warning you must NOT make the same topic / Thread on multiple forums you must only use one support forum for your help and support.
If you have a problem with this warning then please PM me.
Regards.
Ape
If you have a problem with this warning then please PM me.
Regards.
Ape
Similar topics
» Keyword in widget
» Javascript for wikimized keyword
» Keyword problem not working..
» Problem creating keyword tags...
» prefix to usernames
» Javascript for wikimized keyword
» Keyword problem not working..
» Problem creating keyword tags...
» prefix to usernames
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum