The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
How to get the thread URL from a nodeid?
Let's suppose I have a node id (the integer value) which corresponds to a thread. How do I get the URL?
|
#2
|
||||
|
||||
You can get to the threads by nodeid using the www.example.com/forum/node/1234 where 1234 is the nodeid. Is that what you are looking for or are you looking for API?
from the command line ---- curl http://www.vbulletin.com/forum/ajax/...l?nodeid=54756 or javascript --- Code:
$.ajax({ url: 'http://www.vbulletin.com/forum/ajax/api/route/getAbsoluteNodeUrl', type: "POST", dataType: 'json', data: { nodeid:'547' }, success: function(response) { if (response){ alert(response); } } }); You can also call the API in the templates using {vb:data} |
Благодарность от: | ||
Lynne |
#3
|
|||
|
|||
Once and again, thank you very much!
I did as you said using curl: PHP Code:
|
Благодарность от: | ||
MarkFL |
#4
|
||||
|
||||
Quote:
|
Благодарность от: | ||
MarkFL |
#5
|
|||
|
|||
Amazing!
And much simpler now: PHP Code:
|
4 благодарности(ей) от: | ||
bridge2heyday, Lynne, MarkFL, Replicant |
#6
|
|||
|
|||
Hello, sorry for response in old topic - but I have the same problem and don't know how to convert mysite.pl/forum/node1234 to full url to the post. I don't know how to use this getAbsoluteNodeUrl API. Any Tips?
Should create php file example converter.php and put this code in to this file? I need only working redirection from mysite.pl/forum/node1234 to full url to the post how to do that? |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|