Register Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools
  #1  
Old 03 May 2011, 14:44
Spinball's Avatar
Spinball Spinball is offline
 
Join Date: Feb 2002
How to change the meta description? vboptions[description]?

Folks I have a custom template which I use to output custom pages outside normal forum functionality.
I want to change the keywords and description metas which in the headinclude look like

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

My php script does this at the top:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

and after building the page into $page, then

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

The template looks like this:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

In the php script, I tried
$vbulletin->options['description'] = "AVForums reviews";
and
$vboptions['description'] = "AVForums reviews";

and neither work.
Any ideas please?
__________________
AVForums.com the UK's largest audio visual home consumer electronics forums. Running several hacks with thanks to vBulletin.org and its members.

Last edited by Spinball : 03 May 2011 at 14:49.
Reply With Quote
  #2  
Old 05 May 2011, 09:33
Spinball's Avatar
Spinball Spinball is offline
 
Join Date: Feb 2002
Anyone?
__________________
AVForums.com the UK's largest audio visual home consumer electronics forums. Running several hacks with thanks to vBulletin.org and its members.
Reply With Quote
  #3  
Old 05 May 2011, 13:47
kh99's Avatar
kh99 kh99 is offline
 
Join Date: Aug 2009
Real name: Kevin
Maybe you could make a plugin on hook parse_templates like this:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


Or maybe in your code you could do a preg_replace() on $headinclude after global.php is included, and replace the meta tags.

Last edited by kh99 : 05 May 2011 at 14:42. Reason: should have been headinclude
Reply With Quote
  #4  
Old 05 May 2011, 21:47
Spinball's Avatar
Spinball Spinball is offline
 
Join Date: Feb 2002
Thanks. It's not until I'm a bit into the script that I know what description I want to have. It's kind of a problem and I think I might have to create a custom version of global.php just for these special pages.
__________________
AVForums.com the UK's largest audio visual home consumer electronics forums. Running several hacks with thanks to vBulletin.org and its members.
Reply With Quote
  #5  
Old 05 May 2011, 22:00
kh99's Avatar
kh99 kh99 is offline
 
Join Date: Aug 2009
Real name: Kevin
OK, how about this: in the headinclude template put

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


around the meta tags, and in your template put a new variable where you want the description meta tags to be (or maybe copy the entire meta tag block from headinclude to your template and replace the variables as needed), then you have until the template eval to set that variable.

Last edited by kh99 : 05 May 2011 at 22:05.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Jump


New To Site? Need Help?

All times are GMT. The time now is 15:38.

Layout Options | Width: Wide Color: