Register Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools
  #1  
Old 03 Jun 2011, 17:12
galerio's Avatar
galerio galerio is offline
 
Join Date: Feb 2011
Can't use php echo $_GET in template. Need help

I need to add a code like

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

to show the word searched (it comes from an url .php?q=example). But this function doesn't show anything, just blank!
And also when I put into search script to automatically write the word in the search form

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

it shows in the search field the exact text <?php echo $_GET["q"]; ?> !!!!

Is there some vb function that strip this code?
Reply With Quote
  #2  
Old 03 Jun 2011, 18:38
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Real name: Lynne
You cannot add php to templates. You must put your php code into a plugin and then enter the results into the template. However, you should be able to just use the variable in the template. Try something like just {vb:raw $_GET['q']}
__________________
Former vBulletin.org Staff Member

Try a search before posting for help. Many users won't, and don't, help if the question has been answered several times before.
W3Schools -
Online vBulletin Manual
If I post some CSS and don't say where it goes, put it in the additional.css template.
I will NOT help via PM (you will be directed to post in the forums for help.)
Reply With Quote
  #3  
Old 03 Jun 2011, 18:48
galerio's Avatar
galerio galerio is offline
 
Join Date: Feb 2011
Thanks, it works!
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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 03:27.

Layout Options | Width: Wide Color: