The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
![]()
I want to be able to parse javascript into a post. I have tried to enable HTML for admins, but when I post is just displays the html ,i.e. <script type="text/javascript" src="http://someurlhere.com"></script>
and doesn't get the contents from the javascript. Is there are way to do this? If not, I also have and XML feed that I can work with, but it is not RSS. Is there a way to parse the XML and have it post into a new thread like the rss feed manager does? |
#2
|
||||
|
||||
![]()
You'll probably want to make a javascript bbCode...
Code:
Title: Javascript Tag: javascript Use {option}: Yes Description: The [JAVASCRIPT] tag allows you to place javascript in your post. Replacement: <script type="text/javascript" src="{option}">{param}</script> You would want to duplicate this bbCode if you want to allow the use of javascript that's not in a .js file somewhere, but turn off the {option}. At least, the last time I made a bbCode that had an option, if the option wasn't specified the bbCode wasn't parsed. Finally to top it all off, you'll want to use some Advanced bbCode Permissions to stop anyone else from using the javascript bbCode. |
#3
|
||||
|
||||
![]()
You'll definitely want to restrict that BB code down to admins only (if you use it). It could be very dangerous.
|
#4
|
|||
|
|||
![]()
Thanks for the replies. I tried exactly what you said and it doesn't seem to be working. I am using vb 3.6.4. What do i put in between the [javascript] tags? just the url or the whole code, i.e. <script. . . .> I tried both. When I put in the <script> code it doesn't seem to parse, just displays nothing. If I just put the url of the javascript, I just see the text, i.e. [javascript] text here and url[/javascript]
Any insight? I also duplicated the code and took the option out(just the radio button option). Was I supposed to remove the {option} in the bbcode? The url I am trying to parse is not a .js file. |
#5
|
||||
|
||||
![]()
The replacement should be:
Code:
<script type="text/javascript" src="{param}"></script> Quote:
|
#6
|
||||
|
||||
![]() Quote:
Code:
[javascript="whatever.js"][/javascript] The one that Dismounted gave you will let you use it like this Code:
[javascript]whatever.js[/javascript] |
#7
|
|||
|
|||
![]()
Perfect. Thank you both.
|
![]() |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|