The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

{username} wont work

+3
brandon_g
mpelmmc
IdaTR
7 posters

Go down

In progress {username} wont work

Post by IdaTR December 29th 2017, 1:32 pm

I'm about to redesign my webpage: www.vielamort.net with my own code.
I noticed that the code: {username}

doesn't work anymore.

Why and are there other options?

It has to work as an welcome guest/username
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by mpelmmc December 29th 2017, 1:36 pm

Hi @IdaTR

It needs to be in capital letters.
Guest
Code:
{USERNAME}

Greetings.
mpelmmc
mpelmmc
Helper
Helper

Male Posts : 1092
Reputation : 170
Language : English and Spanish

https://help.forumotion.com/

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR December 29th 2017, 2:19 pm

It is, so i dont understand why it doesn't work :s
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by brandon_g December 29th 2017, 2:24 pm

Hello,

Can you provide us a link that has
Code:
{USERNAME}
in it so we can see the issue ourselves?

-Brandon


{username} wont work Brando10
Remember to mark your topic {username} wont work Solved15 when a solution is found.
General Rules | Tips & Tricks | FAQ | Forgot Founder Password?

{username} wont work Scre1476
Team Leader
Review Section Rules | Request A Review | Sticker Points
brandon_g
brandon_g
Manager
Manager

Male Posts : 10106
Reputation : 923
Language : English
Location : USA

https://www.broadcastingduo.com

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR December 29th 2017, 2:34 pm

www.vielamort.net

In the menu to the far left where it says: Velkommen
There should be an
Code:
{USERNAME}
after that, but there is nothing..
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by brandon_g December 29th 2017, 3:46 pm

It almost looks to me like toolbar is covering it. Try removing the toolbar and see if that fixes it.

Edit: Never mind I see what you mean, when it first appears the username should appear next to it, but there is nothing. That is strange, unfortunatelly code isn't my strong suite so you may have to wait for @Draxion or @Ape to help you. Wink

-Brandon


{username} wont work Brando10
Remember to mark your topic {username} wont work Solved15 when a solution is found.
General Rules | Tips & Tricks | FAQ | Forgot Founder Password?

{username} wont work Scre1476
Team Leader
Review Section Rules | Request A Review | Sticker Points
brandon_g
brandon_g
Manager
Manager

Male Posts : 10106
Reputation : 923
Language : English
Location : USA

https://www.broadcastingduo.com

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR December 29th 2017, 6:20 pm

brandon_g wrote:It almost looks to me like toolbar is covering it. Try removing the toolbar and see if that fixes it.

Edit: Never mind I see what you mean, when it first appears the username should appear next to it, but there is nothing. That is strange, unfortunatelly code isn't my strong suite so you may have to wait for @Draxion or @Ape to help you. Wink

-Brandon

Thanks for the help, and yea i will ^^ it a little strange xD
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by SLGray December 29th 2017, 7:56 pm

Did you check to make sure there is no spaces in the code?
{ USERNAME }


{username} wont work Slgray10

When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
SLGray
SLGray
Administrator
Administrator

Male Posts : 51464
Reputation : 3519
Language : English
Location : United States

https://forumsclub.com/gc/128-link-directory/

Back to top Go down

In progress Re: {username} wont work

Post by Ape December 30th 2017, 4:50 pm

Hmm Guest is not working ? it works here on this forum as you can see i used it here


{username} wont work Left1212{username} wont work Center11{username} wont work Right112
{username} wont work Ape_b110
{username} wont work Ape1010
Ape
Ape
Administrator
Administrator

Male Posts : 19084
Reputation : 1988
Language : fluent in dork / mumbojumbo & English haha

http://chatworld.forumotion.co.uk/

Back to top Go down

In progress Re: {username} wont work

Post by brandon_g December 30th 2017, 5:23 pm

APE wrote:Hmm Guest is not working ? it works here on this forum as you can see i used it here

I think it is an issue specific to her forum or maybe even just the one spot she is using it. Her design is heavily coded it seems Ape. Do you know if heavy use of code could interfere with it working properly?


Last edited by brandon_g on December 31st 2017, 2:03 am; edited 1 time in total


{username} wont work Brando10
Remember to mark your topic {username} wont work Solved15 when a solution is found.
General Rules | Tips & Tricks | FAQ | Forgot Founder Password?

{username} wont work Scre1476
Team Leader
Review Section Rules | Request A Review | Sticker Points
brandon_g
brandon_g
Manager
Manager

Male Posts : 10106
Reputation : 923
Language : English
Location : USA

https://www.broadcastingduo.com

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR December 30th 2017, 6:04 pm

The design is not done yet, ofc.. but yea it is kinda odd.

The code is my own, and its not done yet, so yea... :s

Ape; It works fine in the PM, but not in the Overall_header
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by SLGray December 30th 2017, 8:08 pm

So you added it in the templates?
If yes, please post the template.


{username} wont work Slgray10

When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
SLGray
SLGray
Administrator
Administrator

Male Posts : 51464
Reputation : 3519
Language : English
Location : United States

https://forumsclub.com/gc/128-link-directory/

Back to top Go down

In progress Re: {username} wont work

Post by SarkZKalie December 31st 2017, 8:07 pm

Have you try to add this script to overall_header template? This is Forumotion variables js
Code:
function treatvar(nom) {
   var trouve = xhr.responseText.replace(RegExp("^.+<li style="margin-bottom:5px;direction:ltr;text-align:left;"><strong>{" + nom + "}<\/strong>&nbsp;:&nbsp;(.*?)&nbsp;<span style='direction:ltr'>\(.*?\)<\/span><br \/><\/li>.+$"), '$1');
   if (xhr.responseText == trouve) return;
   var children = document.getElementsByTagName('*') || document.all;
   var v = new Array();
   var i = -1;
   while (++i < children.length) {
      var child = children[i];
      var classNames = child.className.split(' ');
      for (var j = 0; j < classNames.length; j++) {
         if (classNames[j] == nom) {
            v.push(child);
            break;
         }
      }
   }
   i = -1;
   while (++i != v.length)
      if (v[i].tagName == 'INPUT' || v[i].tagName == 'TEXTAREA') v[i].value += trouve;
      else v[i].innerHTML += trouve;
};
if (window.ActiveXObject) {
   var xhr = new ActiveXObject("Microsoft.XMLHTTP");
} else if (window.XMLHttpRequest) {
   var xhr = new XMLHttpRequest();
}
if (xhr != null) {
   xhr.onreadystatechange = function() {
      if (xhr.readyState == 4) {
         treatvar('FORUMURL');
         treatvar('FORUMURLINK');
         treatvar('FORUMNAME');
         treatvar('FORUMNAMELINK');
         treatvar('FORUMDESC');
         treatvar('FORUMBIRTHDAY');
         treatvar('FORUMAGE');
         treatvar('FORUMCOUNTFORUM');
         treatvar('FORUMCOUNTOPIC');
         treatvar('FORUMCOUNTPOST');
         treatvar('FORUMCOUNTUSER');
         treatvar('FORUMONLINEUSER');
         treatvar('FORUMONLINEDATE');
         treatvar('FORUMLASTUSER');
         treatvar('FORUMLASTUSERLINK');
         treatvar('USERNAME');
         treatvar('USERLINK');
         treatvar('USERBIRTHDAY');
         treatvar('USERAGE');
         treatvar('USERREGDATE');
         treatvar('USERLASTVISIT');
         treatvar('USERCOUNTPOST');
      }
   };
   xhr.open("GET", "/popup_help.forum?l=miscvars", true);
   xhr.send(null);
}
For more information https://help.forumotion.com/popup_help.forum?l=miscvars
SarkZKalie
SarkZKalie
Support Moderator
Support Moderator

Male Posts : 1407
Reputation : 218
Language : English

https://rotavn.forumotion.com/

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR January 2nd 2018, 6:51 pm

Overall header:

Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="{S_CONTENT_DIRECTION}" id="min-width" lang="{L_LANG_HTML}" xml:lang="{L_LANG_HTML}" {NAMESPACE_FB_LIKE} {NAMESPACE_FB} {NAMESPACE_BBCODE}>
<head>
  <link href="https://fonts.googleapis.com/css?family=Old+Standard+TT|Rajdhani" rel="stylesheet">
  <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
   <title>{SITENAME_TITLE}{PAGE_TITLE}</title>
   <meta http-equiv="content-type" content="text/html; charset={S_CONTENT_ENCODING}" />
   <meta http-equiv="content-script-type" content="text/javascript" />
   <meta http-equiv="content-style-type" content="text/css" />
   <!-- BEGIN switch_compat_meta -->
   <meta http-equiv="X-UA-Compatible" content="IE={switch_compat_meta.VERSION}" />
   <!-- END switch_compat_meta -->
   <!-- BEGIN switch_canonical_url -->
   <link rel="canonical" href="{switch_canonical_url.CANONICAL_URL}" />
   <!-- END switch_canonical_url -->
   {META_FAVICO}
   {META}
   {META_FB_LIKE}
   <meta name="title" content="{SITENAME_TITLE}{PAGE_TITLE}" />
   {T_HEAD_STYLESHEET}
   {CSS}
   <link rel="search" type="application/opensearchdescription+xml" href="/improvedsearch.xml" title="{SITENAME}" />
   <link rel="search" type="application/opensearchdescription+xml" href="{URL_BOARD_DIRECTORY}/search/improvedsearch.xml" title="{SEARCH_FORUMS}" />
   <script src="{JQUERY_PATH}" type="text/javascript"></script>
    <!-- BEGIN switch_recent_jquery -->
    <script src="{JS_DIR}jquery1.9/jquery-migrate-1.4.1.js" type="text/javascript"></script>
    <script src="{JQUERY_DIR}browser/v1.0/jquery.browser.min.js" type="text/javascript"></script>
    <script src="{JQUERY_DIR}support/jquery.support.js" type="text/javascript"></script>
    <!-- END switch_recent_jquery -->
   <script src="{JS_DIR}{L_LANG}.js" type="text/javascript"></script>
    {RICH_SNIPPET_GOOGLE}

   <!-- BEGIN switch_fb_login -->
   <script src="https://connect.facebook.net/{switch_fb_login.FB_LOCAL}/all.js" type="text/javascript"></script>
   <script src="{switch_fb_login.JS_FB_LOGIN}" type="text/javascript"></script>
   <!-- END switch_fb_login -->

   <!-- BEGIN switch_ticker -->
   <link type="text/css" rel="stylesheet" href="{JQUERY_DIR}ticker/ticker.css" />
   <script src="{JQUERY_DIR}ticker/ticker.js" type="text/javascript"></script>
   <!-- END switch_ticker -->

   <!-- BEGIN switch_ticker_new -->
   <script src="{JQUERY_DIR}jcarousel/jquery.jcarousel.js" type="text/javascript"></script>
   <script type="text/javascript">//<![CDATA[
      /* Definir le sens de direction en fonction du panneau admin */
      var tickerDirParam = "{switch_ticker.DIRECTION}";
      var slid_vert = false;
      var auto_dir = 'next';
      var h_perso = parseInt({switch_ticker.HEIGHT});

      switch( tickerDirParam )
      {
         case 'top' :
            slid_vert = true;
            break;

         case 'left':
            break;

         case 'bottom':
            slid_vert = true;
            auto_dir = 'prev';
            break;

         case 'right':
            auto_dir = 'prev';
            break;

         default:
            slid_vert = true;
      }

      $(document).ready(function() {

         $('#fa_ticker_content').css('display','block');

         var width_max = $('ul#fa_ticker_content').width();
         var width_item = Math.floor(width_max / {switch_ticker.SIZE});

         if (width_max > 0)
         {
            $('ul#fa_ticker_content li').css('float','left').css('list-style','none').width(width_item).find('img').each(function () {
               if ($(this).width() > width_item)
               {
               var ratio      = $(this).width() / width_item;
               var new_height = Math.round($(this).height() / ratio);
               $(this).height(new_height).width(width_item);
               }
            });

            if (slid_vert)
            {
               var height_max = h_perso;

               $('ul#fa_ticker_content li').each( function () {
                  if ($(this).height() > height_max)
                  {
                     height_max = $(this).height();
                  }
               } );

               $('ul#fa_ticker_content').width(width_item).height(height_max).css('marginLeft','auto').css('marginRight','auto');
               $('ul#fa_ticker_content li').height(height_max);
            }


            $('#fa_ticker_content').jcarousel({
                  vertical: slid_vert,
               wrap: 'circular',
               auto: {switch_ticker.STOP_TIME},
               auto_direction: auto_dir,
            scroll: 1,
            size: {switch_ticker.SIZE},
            height_max: height_max,
            animation: {switch_ticker.SPEED}
            });
         }
         else
         {
            $('ul#fa_ticker_content li:not(:first)').css('display','none');
            $('ul#fa_ticker_content li:first').css('list-style','none').css('text-align','center');
         }
      });
   //]]>
   </script>
   <!-- END switch_ticker_new -->

   <script type="text/javascript">//<![CDATA[
   $(document).ready(function(){
      <!-- BEGIN switch_enable_pm_popup -->
         pm = window.open('{U_PRIVATEMSGS_POPUP}', '_faprivmsg', 'HEIGHT=225,resizable=yes,WIDTH=400');
         if(pm != null) { pm.focus(); }
      <!-- END switch_enable_pm_popup -->
      <!-- BEGIN switch_report_popup -->
         report = window.open('{switch_report_popup.U_REPORT_POPUP}', '_phpbbreport', 'HEIGHT={switch_report_popup.S_HEIGHT},resizable=yes,scrollbars=no,WIDTH={switch_report_popup.S_WIDTH}');
         if(report != null) { report.focus(); }
      <!-- END switch_report_popup -->
      <!-- BEGIN switch_ticker -->
         $(document).ready(function() {
            Ticker.start({
               height : {switch_ticker.HEIGHT},
               spacing : {switch_ticker.SPACING},
               speed : {switch_ticker.SPEED},
               direction : '{switch_ticker.DIRECTION}',
               pause : {switch_ticker.STOP_TIME}
            });
         });
      <!-- END switch_ticker -->
   });

   <!-- BEGIN switch_login_popup -->
      var logInPopUpLeft, logInPopUpTop, logInPopUpWidth = {LOGIN_POPUP_WIDTH}, logInPopUpHeight = {LOGIN_POPUP_HEIGHT}, logInBackgroundResize = true, logInBackgroundClass = false;
   <!-- END switch_login_popup -->

   <!-- BEGIN switch_login_popup -->
   $(document).ready( function() {
      $(window).resize(function() {
         var windowWidth = document.documentElement.clientWidth;
         var popupWidth = $("#login_popup").width();
         var mypopup = $("#login_popup");

         $("#login_popup").css({
         "left": windowWidth/2 - popupWidth/2
            });
      });
   });
   <!-- END switch_login_popup -->
   //]]>
   </script>
   {GREETING_POPUP}
   <style type="text/css">
   #page-footer, div.navbar, div.navbar ul.linklist {
   display: block !important;
   }
   ul.linklist li.rightside, ul.linklist li.rightside a.copyright {
   display: inline !important;
   }

   <!-- BEGIN switch_ticker_new -->
   .jcarousel-skin-tango .jcarousel-item {
      text-align:center;
      width: 10px;
   }

   .jcarousel-skin-tango .jcarousel-item-horizontal {
      margin-right: {switch_ticker.SPACING}px;
   }

   .jcarousel-skin-tango .jcarousel-item-vertical {
      margin-bottom: {switch_ticker.SPACING}px;
   }
   <!-- END switch_ticker_new -->
   </style>
   {HOSTING_JS}
    <!-- BEGIN google_analytics_code -->
    <script type="text/javascript">
        //<![CDATA[
        var _gaq = _gaq || [];
        _gaq.push(["_setAccount", "{G_ANALYTICS_ID}"]);
        _gaq.push(["_trackPageview"]);
        _gaq.push(['_trackPageLoadTime']);

        <!-- BEGIN google_analytics_code_bis -->
        _gaq.push(['b._setAccount', '{G_ANALYTICS_ID_BIS}']);
        _gaq.push(['b._trackPageview']);
        <!-- END google_analytics_code_bis -->

        (function() {
            var ga = document.createElement("script"); ga.type = "text/javascript"; ga.async = true;
            ga.src = ("https:" == document.location.protocol ? "https://ssl" : "http://www") + ".google-analytics.com/ga.js";
            var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(ga, s);
        })();
        //]]>
    </script>
    <!-- END google_analytics_code -->
</head>

<body id="phpbb">
<!-- BEGIN hitskin_preview -->
<div id="hitskin_preview" style="display: block;">
   <h1><img src="https://2img.net/i/fa/hitskin/hitskin_logo.png" alt="" /> <em>Hit</em>skin.com</h1>
   <div class="content">
      <p>
         {hitskin_preview.L_THEME_SITE_PREVIEW}
         <br />
         <span>{hitskin_preview.U_INSTALL_THEME}<a href="https://{hitskin_preview.U_RETURN_THEME}">{hitskin_preview.L_RETURN_THEME}</a></span>
      </p>

   </div>
</div>
<!-- END hitskin_preview -->

<!-- BEGIN switch_login_popup -->
<div id="login_popup" style="z-index: 10000 !important;">
   <div class="h3">{SITENAME}</div>
   {LOGIN_POPUP_MSG}
   <div id="login_popup_buttons">
      <form action="{S_LOGIN_ACTION}" method="get">
         <input type="submit" class="button1" value="{L_LOGIN}" />
         <input type="button" class="button1" value="{L_REGISTER}" onclick="parent.location='{U_REGISTER}';" />
         <input id="login_popup_close" type="button" class="button2" value="{L_DONT_DISPLAY_AGAIN}" />
      </form>
   </div>
</div>
<!-- END switch_login_popup -->

<div class="conteneur_minwidth_IE">
<div class="conteneur_layout_IE">
<div class="conteneur_container_IE">
<div id="wrap">
   <a id="top" name="top" accesskey="t"></a>
   {JAVASCRIPT}

   <div id="page-header">
      <div class="headerbar">
         <div class="inner"><span class="corners-top"><span></span></span>
<!-- Banner Begin -->
        <div id="banner">
            <h1><a href="index.html">Vie La Mort</a></h1>
            <h2>Dette er et dansk fantasy board - This is a danish fantasy board</h2>
        </div>
        <!-- End: Banner -->
      </div>

      <header>
      <!-- Login / registrer Begin -->
        <div id="loginheader">
            <div id="profilbilled"></div>
            <h1>Velkommen {USERNAME} </h1> <a href="" id="login"><i class="fa fa-sign-in" aria-hidden="true"></i> Login</a> , <a href="" id="regi"><i class="fa fa-plus" aria-hidden="true"></i> Registrer</a>
        </div>
        <!-- End: Login / registrer -->
        <!-- Menu Begin -->
        <nav>
            <ul>
              <li><a href="/">Forside</a></li>
                <li><a href="">Brugeren</a>
                    <ul>
                      <li><a href="/members">Tilmeldte</a></li>
                        <li><a href="http://www.vielamort.net/t14943-face-claim">Face Claim</a></li>
                        <li><a href="http://www.vielamort.net/f118-character-sheet-face-claims">Sheets</a></li>
                    </ul>
                </li>
              <li><a href="/groups">Tilmeld Race</a></li>
                <li><a href="http://www.vielamort.net/f65-sprgsmal-og-ideer">Spørgsmål</a></li>
                <li><a href="https://www4.cbox.ws/box/?boxid=4327805&boxtag=JEf9AW" target="_blank">Chatboks</a></li>
                <li id="admins"><a href="">Admins</a>
                    <ul>
                        <li><a href="">Thomas</a></li>
                        <li><a href="">Aria</a></li>
                        <li><a href="">David</a></li>
                        <li><a href="">Evelyn</a></li>
                    </ul>
                </li>
            </ul>
        </nav>
        <!-- End: Menu -->
    </header>
       

      <!-- BEGIN switch_ticker_new -->
      <div id="fa_ticker_blockD" style="margin-top:4px;">
                             
         <div class="module">
            <div class="inner">
               <span class="corners-top"><span></span></span>
                  <div id="fa_ticker_container">
                     <ul id="fa_ticker_content" class="jcarousel-skin-tango" style="display:none">
                        <!-- BEGIN ticker_row -->
                        <li>{switch_ticker.ticker_row.ELEMENT}</li>
                        <!-- END ticker_row -->
                     </ul>
                  </div>
               <span class="corners-bottom"><span></span></span>
            </div>
         </div>
      </div>
      <!-- END switch_ticker_new -->

      <!-- BEGIN switch_ticker -->
      <div id="fa_ticker_block" style="margin-top:4px;">
         <div class="module">
            <div class="inner">
               <span class="corners-top"><span></span></span>
                  <div id="fa_ticker_container">
                     <div id="fa_ticker" style="height:{switch_ticker.HEIGHT}px;">
                        <div class="fa_ticker_content">
                           <!-- BEGIN ticker_row -->
                           <div>{switch_ticker.ticker_row.ELEMENT}</div>
                           <!-- END ticker_row -->
                        </div>
                     </div>
                  </div>
               <span class="corners-bottom"><span></span></span>
            </div>
         </div>
      </div>
      <!-- END switch_ticker -->
   </div>

   <div id="page-body">

   <div id="{ID_CONTENT_CONTAINER}"{CLASS_CONTENT_CONTAINER}>
      <div id="outer-wrapper">
         <div id="wrapper">
            <div id="container">
               <div id="content">

                  <div id="{ID_LEFT}">
                     <!-- BEGIN giefmod_index1 -->
                     {giefmod_index1.MODVAR}
                     <!-- BEGIN saut -->
                     <div style="height:{SPACE_ROW}px"></div>
                     <!-- END saut -->
                     <!-- END giefmod_index1 -->
                  </div>

                  <div id="main">
                     <div id="main-content">

SarkZKaile: no i havent, does the code make it so that the login / registrer and so on, changes into the profile pic with some user information?
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by SarkZKalie January 2nd 2018, 7:43 pm

Have you try to add { USERLINK } instead of { USERNAME} ?

Edit: Replace these line
Code:
<h1>Velkommen {USERNAME} </h1>
by this one
Code:
<h1>Velkommen <span id="abc">{LOGGED_AS}</span> </h1>
Add this to your CSS
Code:
span#abc {font-size:0}
span#abc strong {font-size:16px!important;color:red;}
SarkZKalie
SarkZKalie
Support Moderator
Support Moderator

Male Posts : 1407
Reputation : 218
Language : English

https://rotavn.forumotion.com/

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR January 2nd 2018, 8:06 pm

SarkZKalie wrote:Have you try to add { USERLINK } instead of { USERNAME} ?

Edit: Replace these line
Code:
<h1>Velkommen {USERNAME} </h1>
by this one
Code:
<h1>Velkommen <span id="abc">{LOGGED_AS}</span> </h1>
Add this to your CSS
Code:
span#abc {font-size:0}
span#abc strong {font-size:16px!important;color:red;}

That worked :o

Now i have other questions.. xD Is it possible to make it say guest when you arent logged in?
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by SarkZKalie January 2nd 2018, 8:20 pm

A replace text javascript will help but it's not my skill. Sorry, but I'll focus on these tag
Code:
<!-- BEGIN switch_user_logged_in -->
<!-- END switch_user_logged_in -->
<!-- BEGIN switch_user_logged_out -->
<!-- END switch_user_logged_out -->
So if user login on, return
Code:
<!-- BEGIN switch_user_logged_in -->
<h1>Velkommen <span id="abc">{LOGGED_AS}</span></h1>
<!-- END switch_user_logged_in -->
And login out, return
Code:
<!-- BEGIN switch_user_logged_out -->
<h1>Velkommen Guest / Gæst</h1>
<!-- END switch_user_logged_out -->
You have to add manually one by one.

P/S: Læs aldrig denne linje, det er bare en oversat tekst til Dansk
SarkZKalie
SarkZKalie
Support Moderator
Support Moderator

Male Posts : 1407
Reputation : 218
Language : English

https://rotavn.forumotion.com/

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR January 2nd 2018, 11:54 pm

SarkZKalie wrote:A replace text javascript will help but it's not my skill. Sorry, but I'll focus on these tag
Code:
<!-- BEGIN switch_user_logged_in -->
<!-- END switch_user_logged_in -->
<!-- BEGIN switch_user_logged_out -->
<!-- END switch_user_logged_out -->
So if user login on, return
Code:
<!-- BEGIN switch_user_logged_in -->
<h1>Velkommen <span id="abc">{LOGGED_AS}</span></h1>
<!-- END switch_user_logged_in -->
And login out, return
Code:
<!-- BEGIN switch_user_logged_out -->
<h1>Velkommen Guest / Gæst</h1>
<!-- END switch_user_logged_out -->
You have to add manually one by one.

P/S: Læs aldrig denne linje, det er bare en oversat tekst til Dansk

I try it out tomorrow ^^ Thanks!

And lol xDD
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by Draxion January 3rd 2018, 12:00 am

For your question regarding if you can make it say something when someone isn't logged in, the answer is yes. You can use this part of javascript.

Code:
if (_userdata["session_logged_in"] == 1) {
}

1 meaning they are, 0 meaning they aren't.

If you need further help regarding how to add this to your other code, please let me know. Smile
Draxion
Draxion
Helper
Helper

Male Posts : 2518
Reputation : 321
Language : English
Location : USA

https://www.talesoftellene.com/

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR January 4th 2018, 8:57 am

Draxion wrote:For your question regarding if you can make it say something when someone isn't logged in, the answer is yes. You can use this part of javascript.

Code:
if (_userdata["session_logged_in"] == 1) {
}

1 meaning they are, 0 meaning they aren't.

If you need further help regarding how to add this to your other code, please let me know. Smile

where should this be put in? (:
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR January 5th 2018, 4:49 pm

bumb
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by SarkZKalie January 8th 2018, 3:37 pm

Could you please provide your current index_body template with a code tag here?


{username} wont work Sarkzk10
SarkZKalie
SarkZKalie
Support Moderator
Support Moderator

Male Posts : 1407
Reputation : 218
Language : English

https://rotavn.forumotion.com/

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR January 9th 2018, 9:26 pm

SarkZKalie wrote:Could you please provide your current index_body template with a code tag here?

Code:
{JAVASCRIPT}
<!-- BEGIN switch_user_logged_in --><p class="right rightside">{LAST_VISIT_DATE}</p><!-- END switch_user_logged_in -->
<p>{CURRENT_TIME}</p>
<br class="clear" />

<!-- BEGIN switch_user_login_form_header -->
<div class="panel">
   <div class="inner"><span class="corners-top"><span></span></span>
      <form action="{S_LOGIN_ACTION}" method="post" name="form_login">
         <div class="user_login_form center">
            <label>{L_USERNAME} : <input class="post" type="text" size="10" name="username" /></label>&nbsp;
            <label>{L_PASSWORD} : <input class="post" type="password" size="10" name="password" /></label>&nbsp;
            <label>{L_AUTO_LOGIN} : <input class="radio" type="checkbox" name="autologin" {AUTOLOGIN_CHECKED} /></label>&nbsp;
            {S_HIDDEN_FIELDS}<input class="mainoption button1" type="submit" name="login" value="{L_LOGIN}" />

                <!-- BEGIN switch_social_login -->
                <div class="social_btn">
                    <!-- BEGIN fb_connect -->
                    <div class="fb-login-button"></div>
                    <!-- END fb_connect -->
                    <!-- BEGIN topicit_connect -->
                    <div class="ti-connect"></div>
                    <!-- END topicit_connect -->
                </div>
                <!-- END switch_social_login -->
         </div>
      </form>
   <span class="corners-bottom"><span></span></span></div>
</div>
<!-- END switch_user_login_form_header -->

<!-- BEGIN message_admin_index -->
   <div class="panel introduction">
      <div class="inner"><span class="corners-top"><span></span></span>
   <!-- BEGIN message_admin_titre -->
      <div class="h3">{message_admin_index.message_admin_titre.MES_TITRE}</div>
   <!-- END message_admin_titre -->

   <!-- BEGIN message_admin_txt -->
      <div class="mes-txt">{message_admin_index.message_admin_txt.MES_TXT}</div>
   <!-- END message_admin_txt -->
      <span class="corners-bottom"><span></span></span></div>
   </div>
<!-- END message_admin_index -->

{CHATBOX_TOP}
{BOARD_INDEX}

<!-- BEGIN disable_viewonline -->

   <!-- BEGIN switch_viewonline_link -->
   <div class="h3"><a href="{U_VIEWONLINE}" rel="nofollow">{L_WHO_IS_ONLINE}</a></div>
   <!-- END switch_viewonline_link -->

   <!-- BEGIN switch_viewonline_nolink -->
   <div class="h3">{L_WHO_IS_ONLINE}</div>
   <!-- END switch_viewonline_nolink -->

<img src="{L_ONLINE_IMG}" id="i_whosonline" alt="{L_WHO_IS_ONLINE}" class="img-whois" />
<p>{TOTAL_USERS_ONLINE}<br />
{RECORD_USERS}

<br />
{LOGGED_IN_USER_LIST}

{L_ONLINE_USERS}
{L_CONNECTED_MEMBERS}<br />
{L_WHOSBIRTHDAY_TODAY}{L_WHOSBIRTHDAY_WEEK}

<br />
<em>{LEGEND}&nbsp;:&nbsp;{GROUP_LEGEND}</em>

</p>
<div class="clear"></div>

   <!-- BEGIN switch_statistics_link -->
   <div class="h3"><a href="{U_STATISTICS}" rel="nofollow">{L_STATISTICS}</a></div>
   <!-- END switch_statistics_link -->

   <!-- BEGIN switch_statistics_nolink -->
   <div class="h3">{L_STATISTICS}</div>
   <!-- END switch_statistics_nolink -->

<p class="page-bottom">
{TOTAL_POSTS}
</p>
<p class="page-bottom">
{TOTAL_USERS}
</p>
<p class="page-bottom">
{NEWEST_USER}
</p>
   <!-- BEGIN switch_chatbox_activate -->
   <div class="h3"><a href="{S_JOIN_CHAT}" target="ChatBox">{CHATBOX_NAME}</a></div>
   <div class="page-bottom">
   {TOTAL_CHATTERS_ONLINE}&nbsp;:&nbsp;
   {CHATTERS_LIST}<br />
   </div>
      <!-- BEGIN switch_chatbox_popup -->
      <div id="chatbox_popup"></div>
      <script type="text/javascript">
      insertChatBoxPopup('{disable_viewonline.switch_chatbox_activate.switch_chatbox_popup.U_FRAME_CHATBOX}', '{L_CLICK_TO_JOIN_CHAT}');
      </script>
      <!-- END switch_chatbox_popup -->
   <!-- END switch_chatbox_activate -->
<!-- END disable_viewonline -->

{CHATBOX_BOTTOM}

<!-- BEGIN switch_user_login_form_footer -->
<div class="panel">
   <div class="inner"><span class="corners-top"><span></span></span>
      <form action="{S_LOGIN_ACTION}" method="post" name="form_login">
         <div class="user_login_form center">
            <label>{L_USERNAME} : <input class="post" type="text" size="10" name="username" /></label>&nbsp;
            <label>{L_PASSWORD} : <input class="post" type="password" size="10" name="password" /></label>&nbsp;
            <label>{L_AUTO_LOGIN} : <input class="radio" type="checkbox" name="autologin" {AUTOLOGIN_CHECKED} /></label>&nbsp;
            {S_HIDDEN_FIELDS}<input class="mainoption button1" type="submit" name="login" value="{L_LOGIN}" />

                <!-- BEGIN switch_social_login -->
                <div class="social_btn">
                    <!-- BEGIN fb_connect -->
                    <div class="fb-login-button"></div>
                    <!-- END fb_connect -->
                    <!-- BEGIN topicit_connect -->
                    <div class="ti-connect"></div>
                    <!-- END topicit_connect -->
                </div>
                <!-- END switch_social_login -->
         </div>
      </form>
   <span class="corners-bottom"><span></span></span></div>
</div>
<!-- END switch_user_login_form_footer -->

<br style="clear:both" />

<!-- BEGIN switch_legend -->
<ul id="picture_legend">
   <li><img src="{FORUM_NEW_IMG}" alt="{L_NEW_POSTS}" />{L_NEW_POSTS}</li>
   <li><img src="{FORUM_IMG}" alt="{L_NO_NEW_POSTS}" />{L_NO_NEW_POSTS}</li>
   <li><img src="{FORUM_LOCKED_IMG}" alt="{L_FORUM_LOCKED}" />{L_FORUM_LOCKED}</li>
</ul>
<!-- END switch_legend -->

{AUTO_DST}
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by SarkZKalie January 10th 2018, 3:20 am

Search and replace this one
Code:

<!-- BEGIN switch_user_logged_in -->
<p class="right rightside">{LAST_VISIT_DATE}</p>
<!-- END switch_user_logged_in -->
by
Code:
<!-- BEGIN switch_user_logged_in -->
<p>Velkommen <span id="abc">{LOGGED_AS}</span></p>
<!-- END switch_user_logged_in -->
<!-- BEGIN switch_user_logged_out -->
<p>Velkommen Guest / Gæst</p>
<!-- END switch_user_logged_out -->
In case you want it show in all pages, just do the same with overall_header template.


{username} wont work Sarkzk10
SarkZKalie
SarkZKalie
Support Moderator
Support Moderator

Male Posts : 1407
Reputation : 218
Language : English

https://rotavn.forumotion.com/

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR January 10th 2018, 10:32 am

SarkZKalie wrote:Search and replace this one
Code:

<!-- BEGIN switch_user_logged_in -->
<p class="right rightside">{LAST_VISIT_DATE}</p>
<!-- END switch_user_logged_in -->
by
Code:
<!-- BEGIN switch_user_logged_in -->
<p>Velkommen <span id="abc">{LOGGED_AS}</span></p>
<!-- END switch_user_logged_in -->
<!-- BEGIN switch_user_logged_out -->
<p>Velkommen Guest / Gæst</p>
<!-- END switch_user_logged_out -->
In case you want it show in all pages, just do the same with overall_header template.

but what about information as: Private messages, profile and log out in the header when you are logged in?
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

In progress Re: {username} wont work

Post by SarkZKalie January 10th 2018, 11:03 am

They're completely separate. I didn't touch any content in {GENERATED_NAV_BAR}. My solution is only leave a text in a certain position.


{username} wont work Sarkzk10
SarkZKalie
SarkZKalie
Support Moderator
Support Moderator

Male Posts : 1407
Reputation : 218
Language : English

https://rotavn.forumotion.com/

Back to top Go down

In progress Re: {username} wont work

Post by IdaTR January 10th 2018, 1:10 pm

oh, but how do you do the thing that i asked for then? (:
IdaTR
IdaTR
Forumember

Female Posts : 547
Reputation : 1
Language : Danish, english
Location : Denmark

http://www.vielamort.net

Back to top Go down

Back to top


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