Welcome,
Guest
.
Please
login
or
register
.
Did you miss your
activation email
?
News:
Bug reports and fixes
.
Home
Help
Login
Register
Elxis CMS Forum
»
Support
»
Elxis 4.x/5.x DEV
»
Separate page title for homepage and other pages
« previous
next »
Print
Pages: [
1
]
2
Author
Topic: Separate page title for homepage and other pages (Read 12557 times)
kyomar
Full Member
Posts: 158
Separate page title for homepage and other pages
«
on:
July 17, 2013, 11:11:17 »
Hi,
some of my page titles are getting a little bit too long and repetitive. Is it possible to have a unique title for the homepage and then different title constructions for all other pages with the possibility to add a prefix and/or appendix? An example:
Homepage title: best cms on the planet - elxis4
Other pages title w/ prefix: elxis4 (prefix) - read our wiki page (articles title)
As it works now the article's title is shown in front (prefix) of the homepage title (site name).
Example: read our wiki page - best cms on the planet - elxis4
I think this would give us more flexibility in creating more meaningful and seo friendly page titles.
Thank you!
«
Last Edit: July 24, 2013, 03:16:29 by kyomar
»
Logged
kyomar
Full Member
Posts: 158
Re: Separate page title for homepage and other pages
«
Reply #1 on:
July 24, 2013, 03:15:55 »
Hi, This seems to be of no interest or I didn't explain the matter clearly enough. Anyway, whenever I ask something seo related I am not getting any comments. For example I asked a while ago why site name is added to all meta descriptions which makes the descriptions sometimes very long.
I try to be a part of the elxis community and help to improve further an already very good product.
Thank you.
Logged
kyomar
Full Member
Posts: 158
Re: Separate page title for homepage and other pages
«
Reply #2 on:
July 26, 2013, 08:54:30 »
Hey guys, I really need help with this. I am stuck with the creation of the page titles. I had a look at isopensource.com and the page titles are exactly how I would like to have my page titles (see first post). Can please somebody have a look at my titles @ koyuki-hakuba.com.
Thanks a lot!
Logged
kyomar
Full Member
Posts: 158
Re: Separate page title for homepage and other pages
«
Reply #3 on:
July 30, 2013, 03:24:23 »
I am still working on this. It's a pitty nobody seems to be able to help how to build page titles seen in the web browsers title bar.
I guess the problem is that I don't have an article in my frontpage, only modules which are allocated to frontpage cells. I tried mod_articles instead of mod_content but it doesn't change anything as module titles are h2 whereas article titles are h1 and only h1 are used to build page titles. Or is there another way to build a frontpage title besides site name?
Any help would be really appreciated!
Thank you!
Logged
datahell
Elxis Team
Hero Member
Posts: 10356
Re: Separate page title for homepage and other pages
«
Reply #4 on:
July 30, 2013, 09:35:48 »
https://www.elxis.net/docs/developers/libraries/elxisdocument.html
Logged
Elxis Team
|
Is Open Source
|
IOS Rentals | IOS AERO
kyomar
Full Member
Posts: 158
Re: Separate page title for homepage and other pages
«
Reply #5 on:
July 31, 2013, 03:24:39 »
thank you very much datahell. The elxis documentation is excellent. I just didn't know where to look; didn't check developers :-(. Where do I have to insert $eDoc->setTitle('My custom title'); to change only frontpage title?
Logged
webgift
Elxis Team
Hero Member
Posts: 4193
Re: Separate page title for homepage and other pages
«
Reply #6 on:
August 01, 2013, 10:02:00 »
I think that the document title of the frontpage is your sitename. Site name can be changed from Administrator area -> Settings -> General -> Site name
«
Last Edit: August 01, 2013, 10:04:02 by webgift
»
Logged
Elxis Team •
Custom web design [EN]
-
[EL]
•
.GR Registrar
kyomar
Full Member
Posts: 158
Re: Separate page title for homepage and other pages
«
Reply #7 on:
August 01, 2013, 11:00:36 »
Thank you webgift!
I know that the site name is used for the frontpage title as well as for all other pages title (us appendix) which is exactly my problem. My page titles are getting too long and repetitive because of the site name being added. Unfortunately we don't have something like a prefix or/and appendix field which could be used for the creation of all other pages and the site name is only used for the frontpage title. Please read my first post as well.
«
Last Edit: August 01, 2013, 14:42:14 by webgift
»
Logged
webgift
Elxis Team
Hero Member
Posts: 4193
Re: Separate page title for homepage and other pages
«
Reply #8 on:
August 01, 2013, 12:38:59 »
Note: Below i am going to quote you some actions which are not recommended at all. You do that for your own responsibility ok?
Folder: components/com_content/controllers
PHP file: fpage
Search for : $eDoc->setTitle($elxis->getConfig('SITENAME'));
$elxis->getConfig('SITENAME') is your site name description.
- Depending the tasks you wish to change the document's title you have to edit the relative controller each time.
Logged
Elxis Team •
Custom web design [EN]
-
[EL]
•
.GR Registrar
datahell
Elxis Team
Hero Member
Posts: 10356
Re: Separate page title for homepage and other pages
«
Reply #9 on:
August 01, 2013, 12:39:46 »
Elxis uses the site name you have set in Elxis configuration as page title in frontpage,
this is the recommended option
for SEO.
If you want to change that open file:
components/com_content/controllers/fpage.php
Go to line 44:
$eDoc->setTitle($elxis->getConfig('SITENAME'));
and change it to what ever you like:
$eDoc->setTitle('Something very custom');
If you write non-latin characters make sure to save fpage.php file as UTF-8 without BOM.
«
Last Edit: August 01, 2013, 12:41:38 by datahell
»
Logged
Elxis Team
|
Is Open Source
|
IOS Rentals | IOS AERO
webgift
Elxis Team
Hero Member
Posts: 4193
Re: Separate page title for homepage and other pages
«
Reply #10 on:
August 01, 2013, 12:41:20 »
We wrote at the same time!
Logged
Elxis Team •
Custom web design [EN]
-
[EL]
•
.GR Registrar
kyomar
Full Member
Posts: 158
Re: Separate page title for homepage and other pages
«
Reply #11 on:
August 01, 2013, 13:45:25 »
Yeah, that's it. Many thanks webgift and datahell.
Now the site name is being used as appendix for all page titles and the front page title is "hard coded". I still believe it would be great if one could define a prefix and/or appendix for the page titles and the site name is only used for the front page title.
Have a nice day!
Logged
webgift
Elxis Team
Hero Member
Posts: 4193
Re: Separate page title for homepage and other pages
«
Reply #12 on:
August 01, 2013, 15:20:19 »
You are welcome, Kyomar.
The thread you've sent me above has been deleted in order avoid any misunderstanding for community members. Ok?
Have a nice day too.
Logged
Elxis Team •
Custom web design [EN]
-
[EL]
•
.GR Registrar
kyomar
Full Member
Posts: 158
Re: Separate page title for homepage and other pages
«
Reply #13 on:
January 25, 2014, 09:56:53 »
Hi, sorry I have to bring this topic up again. I have changed the title creation as suggested by datahell and it works great. But now suddenly google displays wrong page titles. The site name is displayed twice but slightly different on each page (except homepage, which is correct).
Example with site name "company name":
site title - company name - company name + town
Any ideas why? Did google mess up?
Thanks for any feedback,
Markus
Logged
datahell
Elxis Team
Hero Member
Posts: 10356
Re: Separate page title for homepage and other pages
«
Reply #14 on:
January 25, 2014, 10:17:57 »
Each page is a different case. The extensions controls each page separately to set proper title and meta tags.
I told you how to set the title, whether you set a good title or not, is an other discussion...
I advise you to set a proper site name in Elxis configuration and let everything else be handled by Elxis.
«
Last Edit: January 25, 2014, 10:19:43 by datahell
»
Logged
Elxis Team
|
Is Open Source
|
IOS Rentals | IOS AERO
Print
Pages: [
1
]
2
« previous
next »
Elxis CMS Forum
»
Support
»
Elxis 4.x/5.x DEV
»
Separate page title for homepage and other pages