Forum Support

Shape 5
March 28, 2024, 01:17:30 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Shape 5 Forum
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Change the page title hyphen to a pipe before site name  (Read 349 times)
jakexo
Jr. Member
**
Offline Offline

Posts: 42



« on: September 20, 2014, 11:40:48 AM »

I've google'd this plenty and tried some solutions but the s5_head_call seems to change the game.

Basically, in a browser page title with "Include site name in page titles" on in the Global config, all titles are shown as   Page Name - Site Name which is fine but I'd like to change it to "Page Name | Site Name"

I tried adding the following code to the index.php and vertex/cms_core_functions.php file but nothing changed. Any ideas where to find the " - " and change it to " | "?

<?php
      $exception_page = "Home";
         $app = JFactory::getApplication(); // optional line if it isn't already in file
 
      if (trim($this['system']->document->title)!=trim($exception_page)) { 
           $new_page_title = $this['system']->document->title . " | " . trim($app->getCfg('sitename')); 
           $this['system']->document->title = $new_page_title; 
      } else {
           $this['system']->document->title = trim($app->getCfg('sitename')); 
      }
 ?>
 <jdoc:include type="head" />
Logged
mikenicoll
Global Moderator
*****
Offline Offline

Posts: 20162



WWW
« Reply #1 on: September 22, 2014, 05:27:43 PM »

Hello,

I am not aware of a way to do that which doesn't involve modifying the database. I would create a post on Joomla.org to see if there is any more information regarding how to make this change. I did a quick search but most results say it isn't possible or are outdated from J1.5
Logged

Mike Nicoll
------------
Shape 5 Team

- Need a great host for your website? We highly recommend siteground.com!


- Put your trust in the hands of our extremely qualified staff to get your job done right!


- Firebug is the most powerful web development and debugging tool, and it will save you a lot of time, frustration and forum questions:
Install Firebug
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF | SMF © 2013, Simple Machines
Joomla Bridge by JoomlaHacks.com
Valid XHTML 1.0! Valid CSS!
Looking for the largest variety in template designs? Look no more. Never buy 1 theme again. Signups start at just $89 for access to all of our themes.
Send Us An Email
Please send us your questions and we will email you back as soon as we can. Product support questions should be posted in our support forums under the Help menu. Our staff will assist you from there.