Skip to main content
added 5 characters in body; edited title
Source Link
FFrewin
  • 19.8k
  • 10
  • 48
  • 101

language Language condition and editing index.php

iI am trying to edit my index.php for languages and just trying to put my logo on right could.

Could you please show me what am iI doing wrong?

iI want to put my logo on the left when language is arabic aa-AA and logo on the right when language is english en-GB

Thanks,

<?php
  $lang = JFactory::getLanguage();
  $result = $lang->getTag();
  if ($result=="en-GB") { 
  
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>

      <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
  } 
  else { 
       <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
      
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>
  }
?> 

language condition and editing index.php

i am trying to edit my index.php for languages and just trying to put my logo on right could you please show me what am i doing wrong?

i want to put my logo on the left when language is arabic aa-AA and logo on the right when language is english en-GB

Thanks,

<?php
  $lang = JFactory::getLanguage();
  $result = $lang->getTag();
  if ($result=="en-GB") { 
  
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>

      <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
  } 
  else { 
       <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
      
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>
  }
?> 

Language condition and editing index.php

I am trying to edit my index.php for languages and just trying to put my logo on right.

Could you please show me what am I doing wrong?

I want to put my logo on the left when language is arabic aa-AA and logo on the right when language is english en-GB

Thanks,

<?php
  $lang = JFactory::getLanguage();
  $result = $lang->getTag();
  if ($result=="en-GB") { 
  
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>

      <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
  } 
  else { 
       <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
      
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>
  }
?> 
added 125 characters in body
Source Link
burc
  • 1
  • 1

i am trying to edit my index.php for languages and just trying to put my logo on right could you please show me what am i doing wrong?

i want to put my logo on the left when language is arabic aa-AA and logo on the right when language is english en-GB

Thanks,

<?php
  $lang = JFactory::getLanguage();
  $result = $lang->getTag();
  if ($result=="en-GB") { 
  
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>

      <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
  } 
  else { 
       <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
      
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>
  }
?> 

i am trying to edit my index.php for languages and just trying to put my logo on right could you please show me what am i doing wrong?

Thanks,

<?php
  $lang = JFactory::getLanguage();
  $result = $lang->getTag();
  if ($result=="en-GB") { 
  
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>

      <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
  } 
  else { 
       <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
      
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>
  }
?> 

i am trying to edit my index.php for languages and just trying to put my logo on right could you please show me what am i doing wrong?

i want to put my logo on the left when language is arabic aa-AA and logo on the right when language is english en-GB

Thanks,

<?php
  $lang = JFactory::getLanguage();
  $result = $lang->getTag();
  if ($result=="en-GB") { 
  
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>

      <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
  } 
  else { 
       <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
      
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>
  }
?> 
Source Link
burc
  • 1
  • 1

language condition and editing index.php

i am trying to edit my index.php for languages and just trying to put my logo on right could you please show me what am i doing wrong?

Thanks,

<?php
  $lang = JFactory::getLanguage();
  $result = $lang->getTag();
  if ($result=="en-GB") { 
  
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>

      <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
  } 
  else { 
       <!-- Main menu module -->

      <div id="jf-mainmenu">

        <?php if($this->countModules('mainmenu')) : ?>

          

           <jdoc:include type="modules" name="mainmenu" />

          

        <?php endif; ?>

        <div id="jf-submenu"><jdoc:include type="modules" name="submenu" /></div>

      </div>
      
       <div id="jf-logo">

        <a href="index.php"><img src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/images/logo.png" alt="JF Texturia"/></a>

      </div>
  }
?>