Titles question

Post Reply
tubeman
Posts: 417
Joined: Sat Mar 02, 2013 11:33 am

Titles question

Post by tubeman » Thu Jan 24, 2019 1:29 am

Hi,
In titles for example if I want:

order = ctr and page is 1
<title> Latest Videos </title>

Page after 1
<Title> Latest Videos Page 2 </title>

basically don't want to put the word and number for Page 1, how do I do this?

admin
Site Admin
Posts: 27738
Joined: Wed Sep 10, 2008 11:43 am

Re: Titles question

Post by admin » Thu Jan 24, 2019 5:02 am

if ($_GET['page'] > 1) {
show title page ...
} else {
show title
}
Have you done script update ?

tubeman
Posts: 417
Joined: Sat Mar 02, 2013 11:33 am

Re: Titles question

Post by tubeman » Thu Jan 24, 2019 9:17 am

What do I add in this code to make it work:

<?php if ($_GET['order'] == 'ctr') {?>

<title>Site order by CTR </title>

<?php } elseif ($_GET['order'] == 'date') { ?>

<title>Site order by date </title>

<?php } else { ?>

<title>Default order (default = by ctr ) </title>

<?php } ?>

admin
Site Admin
Posts: 27738
Joined: Wed Sep 10, 2008 11:43 am

Re: Titles question

Post by admin » Thu Jan 24, 2019 9:24 am

The code looks ok
Have you done script update ?

tubeman
Posts: 417
Joined: Sat Mar 02, 2013 11:33 am

Re: Titles question

Post by tubeman » Thu Jan 24, 2019 9:32 am

I mean how do I add the ($_GET['page'] > 1) within this code?

admin
Site Admin
Posts: 27738
Joined: Wed Sep 10, 2008 11:43 am

Re: Titles question

Post by admin » Thu Jan 24, 2019 10:06 am

replace

<title>Site order by CTR </title>

with the example code
Have you done script update ?

tubeman
Posts: 417
Joined: Sat Mar 02, 2013 11:33 am

Re: Titles question

Post by tubeman » Thu Jan 24, 2019 11:03 am

I was trying but getting syntax errors, can you please give it to me for 1 part, remaining I will figure out.

tubeman
Posts: 417
Joined: Sat Mar 02, 2013 11:33 am

Re: Titles question

Post by tubeman » Thu Jan 24, 2019 12:44 pm

I figured it out, Thanks

admin
Site Admin
Posts: 27738
Joined: Wed Sep 10, 2008 11:43 am

Re: Titles question

Post by admin » Thu Jan 24, 2019 2:00 pm

Ok )
Have you done script update ?

Post Reply