PcGeniusProductions Posted January 26, 2008 Share Posted January 26, 2008 Hi there. Please don't laugh when I ask for help on something this simple, but i really have no clue. I have tried, and kept recieving errors. This code Displays "Site Name: Page Name" I want it to display "Page Name | Site Name" Here is the code: <title>".SITENAME.(defined("e_PAGETITLE") ? ": ".e_PAGETITLE : (defined("PAGE_NAME") ? ": ".PAGE_NAME : ""))."</title>\n"; Can someone help me please? Thanks in Advance. Quote Link to comment Share on other sites More sharing options...
themistral Posted January 26, 2008 Share Posted January 26, 2008 Try <title>".SITENAME.(defined("PAGE_NAME") ? ": ".PAGE_NAME : (defined("e_PAGETITLE") ? ": ".e_PAGETITLE : ""))."</title>\n"; Let me know if that works! Quote Link to comment Share on other sites More sharing options...
PHP Monkeh Posted January 26, 2008 Share Posted January 26, 2008 Don't make 2 threads first of all, this looks really confusing (which CMS is this from?), anyway I'll give it a shot: <title>".(defined("e_PAGETITLE") ? e_PAGETITLE." | " : (defined("PAGE_NAME") ? PAGE_NAME." | ")).SITENAME."</title>\n"; Give that a try, but I'm not promising anything Quote Link to comment Share on other sites More sharing options...
PcGeniusProductions Posted January 26, 2008 Author Share Posted January 26, 2008 themistral: That code did not change anything. Thank for the reply however. PHP Monkeh: I got this error: Parse error: syntax error, unexpected ')' in /home/pcgenius/public_html/e107_themes/templates/header_default.php on line 89 I am using "e107" CMS. Any Ideas? Quote Link to comment Share on other sites More sharing options...
PHP Monkeh Posted January 26, 2008 Share Posted January 26, 2008 Oops was my bad, missed a bit, try this: <title>".(defined("e_PAGETITLE") ? e_PAGETITLE." | " : (defined("PAGE_NAME") ? PAGE_NAME." | " : "")).SITENAME."</title>\n"; Quote Link to comment Share on other sites More sharing options...
PcGeniusProductions Posted January 26, 2008 Author Share Posted January 26, 2008 I truly am speechless... ??? I usually go for the logical way of fixing this sort of thing, but This totally stumped me... Yes it works fine. Thank you so much, I tried to swap them around a bit in chunks, but naturally, it failed terribly. Never mind, I am not that good at hard coding. Thanks for your help, and you don't know how much better this will be for the search engine results. it will look much better. Thanks again. Very Best Ragards, from Reece. Thanks to everyone who has helped on this thread. Quote Link to comment Share on other sites More sharing options...
PHP Monkeh Posted January 26, 2008 Share Posted January 26, 2008 It's made a little more confusing with those types of if statements, but glad that's what you wanted Remember to click problem solved! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.