Keyword as prefix in title

Go down

Tutorial - Keyword as prefix in title Empty Keyword as prefix in title

Post by Simone Boi November 28th 2020, 11:49 am

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"

Tutorial - Keyword as prefix in title TzP

i'll get more plates


Tutorial - Keyword as prefix in title TzJ

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;
}
avatar
Simone Boi
Forumember

Posts : 58
Reputation : 1
Language : Italian

View user profile https://gamespledge.forumattivo.com/

Back to top Go down

Tutorial - Keyword as prefix in title Empty Re: Keyword as prefix in title

Post by pedxz November 28th 2020, 12:54 pm

Hello again @Simone Boi!

Read this tutorial: Topic prefix this code is better Embarassed and the prefix only work once per topic title
pedxz
pedxz
Forumember

Posts : 428
Reputation : 110
Language : 🇵🇹

View user profile https://www.forumotion.com/create-forum/modernbb

TonnyKamper and Simone Boi like this post

Back to top Go down

Tutorial - Keyword as prefix in title Empty Re: Keyword as prefix in title

Post by Simone Boi November 28th 2020, 4:26 pm

@pedxz wrote:Hello again @Simone Boi!

Read this tutorial: Topic prefix this code is better Embarassed 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

Tutorial - Keyword as prefix in title Bgi8XJ7
avatar
Simone Boi
Forumember

Posts : 58
Reputation : 1
Language : Italian

View user profile https://gamespledge.forumattivo.com/

Back to top Go down

Tutorial - Keyword as prefix in title Empty Re: Keyword as prefix in title

Post by skouliki November 28th 2020, 6:35 pm

as i said already

Please do not open similar threads to multiple support forums.
Please read our forum rules: ESF General Rules

https://aiuto.forumattivo.it/t20562-problema-prefissi-topic-keyword

this topic will be locked
skouliki
skouliki
Manager
Manager

Female Posts : 10585
Reputation : 1343
Language : English,Greek
Location : Greece

View user profile http://iconskouliki.forumgreek.com

Back to top Go down

Tutorial - Keyword as prefix in title Empty Re: Keyword as prefix in title

Post by Ape November 28th 2020, 7:51 pm

@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


Tutorial - Keyword as prefix in title Left1212Tutorial - Keyword as prefix in title Center11Tutorial - Keyword as prefix in title Right112
Tutorial - Keyword as prefix in title Ape_b110
Tutorial - Keyword as prefix in title Keep_s10
Tutorial - Keyword as prefix in title Ape1010
Ape
Ape
Administrator
Administrator

Male Posts : 16328
Reputation : 1757
Language : fluent in dork / mumbojumbo & English haha

View user profile http://chatworld.forumotion.co.uk/

Back to top Go down

Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum