The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Passing variables in the query string
Newb question.
I've been through the forums and haven't been able to find something in particular that answers my question. Thanks in advance for any comments. Here's what I need to get done: I have a non-vBulletin html page and I want to pass 3 variables from that page into a vBulletin page. www.mydomain.com/forumdisplay.php?a=1&b=2&c=3 Integers like the above - no text. When I get to the vBulletin page, how do I read the three variables to get the numbers 1,2,3? Basic, I know. Please help. Thanks! |
#2
|
|||
|
|||
PHP Code:
|
#3
|
||||
|
||||
Danny, thanks for the quick response.
Where exactly do I place this PHP code? In the template I want to read the query string in? Again, many thanks for the help. ------------------------------------------ Edit! Let me be more specific: I want to pass values for forumid's into the vBulletin page from a non-vBulletin page. I was planning on stuffing the query string with the following: www.mydomain.com/forumdisplay.php?f=1&c=2 ...where f=forumid and c=calendarid That way I can populate variables inside the header template for custom navigation. Again, I appreciate any help. |
#4
|
||||
|
||||
You can place the code in one of the "_start" hooks. For example, for showthread.php, showthread_start.
|
#5
|
||||
|
||||
Hanson, thanks for your reply. I'm sorry though, I'm not following.
I just went through the /forums directory and was unable to locate any file that ended with _start.* Where does the showthread_start. file reside? Is this the easiest way of passing variables from outside vBulletin into a vBulletin page? Again, thanks so much for the help. |
#7
|
||||
|
||||
Quote:
Just completed the following: 1. Plug-in's are enabled. 2. Created a new plugin called navTransport 3. Hook Location is 'forumdisplay_start' 4. Inserted this code: PHP Code:
http://www.mydomain.com/forums/forum...=9&e=2&b=2&g=4 Again, thank you for the help. |
#8
|
|||
|
|||
Typing:
PHP Code:
|
#9
|
||||
|
||||
Not working. I've got to be missing something.
I have the following HTML tag in the header: HTML Code:
<a href="/forums/forumdisplay.php?f={$vbulletin->GPC['b']}">
Code:
<a href="/forums/forumdisplay.php?f=2"> Code:
<a href="/forums/forumdisplay.php?f="> http://www.mydomain.com/forums/forum...=9&e=2&b=2&g=4 Perhaps there is something else that needs to be done? Thanks again for all assistance... |
#10
|
|||
|
|||
In your plugin temporarily add
PHP Code:
You may find the rest of the page ceases to function correctly just ignore that, you can remove the line once you've followed the instructions. Post what you get outputted here. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|