Recent Topics

1 Apr 15, 2008 12:53    

My b2evolution Version: Not Entered

Hi there,
I hope I can explain this well enough, firstly my spec:
site: http://www.barnesnet.co.uk | version 2.4.1 | skin pixelgreen(modified).

Code I am trying to use, it's an adsense video player:

<div id='vu_ytplayer_vjVQa1PpcFOFCvi15rzd2gU3iSjc3pesHR16MfslkZ8='><a href='http://www.youtube.com/browse'>Watch the latest videos on YouTube.com</a></div><script type='text/javascript' src='http://www.youtube.com/cp/vjVQa1PpcFOFCvi15rzd2gU3iSjc3pesHR16MfslkZ8='></script>

This code will work fine if placed in a widget (free html) or probably within the skin template itself but as many of you probably already know due to the javascript section it will not function within a post. Actually the javascript section gets eaten up and disappears.

I am wanting to include this code in either one sticky post (I have setup sticky posts) or at the top of one of my categories (videos).

Questions:
Is it at all possible to allow javascript in posts (best for admin only).
How and where would you put the code so that it would only appear in one category?

Any help highly appreciated

2 Apr 15, 2008 16:13

On your Users tab, click the name of the group you want to give special posting permissions to. Then change the "security filters" section as need be. Sounds like you want to turn off "prevent javascripts" and maybe turn off "prevent objects"?

Would you be interested in being able to place a container for a widget *between* posts? That way instead of having your post with your whatever eventually roll off the page you could always have your whatever be between the first and second posts on a multipost page.

3 Apr 15, 2008 16:39

mmmm, I have already turned off "prevent javascripts" and "prevent objects"? from the admin group (I think this was to cure errors with live writer a while back.

I wonder if it could be tinymce eating the code?
anyway..
The second option does sound interesting, I did think about putting a container for the purpose but was not sure how I could place it either before (on-top of) all posts or like you say after the the first.

Trouble being, I don't want the item to show on all blogs, in every view. I simply want it above my video posts which are in a catergory all of their own. (videos).

Sounds to me like something must give??

4 Apr 15, 2008 16:48

I hadn't thought of a magical container that only shows up before a post in a category, but I'll bet it can be done. As for "not on every blog" well heck that's easy. On my blog you get an xkcd comic after the first post but only on my blog #1 because that's where I wanted it. Easy breazy, but NOT a "ready made there ya go" type of thing. I'll work on releasing a method to add a special container for that type of thing, and see about making it be "if the next post is category 442 then show up a container now".


Form is loading...