Problem with adding a flash in the sidebar

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
Post Reply
Snowfox
Regular
Posts: 16
Joined: Mon Aug 22, 2005 6:46 pm
Contact:

Problem with adding a flash in the sidebar

Post by Snowfox »

I want to add this little funky flash:
http://julk.net.free.fr/nectarine/ticker/necta_julk.php
Into my sidebar, with the html bugget plugin, but the problem is
that it loads the flash incorrect not showing the playlist as it should,
but if i open the flash just with my browser it works. Any ideas ?
judebert
Regular
Posts: 2478
Joined: Sat Oct 15, 2005 6:57 am
Location: Orlando, FL
Contact:

Post by judebert »

I believe PHP in nuggets is disabled for security reasons.

In fact, I don't even know if it'll work in Smarty templates. Try adding it to your header for a test: edit your index.tpl to add the required PHP and see what happens.
Judebert
---
Website | Wishlist | PayPal
Snowfox
Regular
Posts: 16
Joined: Mon Aug 22, 2005 6:46 pm
Contact:

Post by Snowfox »

No luck either, putting the flash in the header ends in the same
resault like putting it into the html nugget.
judebert
Regular
Posts: 2478
Joined: Sat Oct 15, 2005 6:57 am
Location: Orlando, FL
Contact:

Post by judebert »

Yeah, I was afraid of that.

You can run PHP from your templates through a customization file called config.inc.php. For instance, you could create a config.inc.php in your template directory with this content:

Code: Select all

<?php
ob_start();
include your_php_file.php
$data = ob_get_contents();
ob_end_clean();
$serendipity['smarty']->assign('my_content', $data);
?> 
Then modify your template with {$my_content} wherever you want the output to go. You've got to be careful with paths: see this entry for embedding PHP in your blog.

You could also try the externalphp sidebar plugin, which allows you to call (as the name suggests) external PHP programs.

The documentation for using PHP in your templates is here.
Judebert
---
Website | Wishlist | PayPal
Post Reply