PDA

View Full Version : Integrating dynamic drive carousel with Wordpress



Dannymax
05-15-2009, 12:14 AM
1) Script Title:

dynamic drive carousel
Wordpress


2) Script URL (on DD):

http://www.dynamicdrive.com/dynamicindex4/stepcarousel.htm

3) Describe problem:

I want to use the dynamic drive carousel on my wordpress blog and have got it working ok on a test page...

http://www.dannymax.co.uk/blog/wp-content/themes/elegance/Untitled-1.php

When I try and call the js into the header.php and put the code in the page the script wont run so just the html is displayed...

http://www.dannymax.co.uk/blog/?page_id=2

After hours of trying to sort this myself Im out of ideas, please help!

X96 Web Design
05-15-2009, 12:27 AM
That's one bad thing about Wordpress - It automatically edits your HTML code, and you can't disable this function (as far as I know). It's caused me lots of grief with HTML examples...

Look what it does to your javascript! ::


<p><script type="text/javascript"></p>
<p>stepcarousel.setup({
galleryid: 'mygallery', //id of carousel DIV
beltclass: 'belt', //class of inner "belt" DIV containing all the panel DIVs
panelclass: 'panel', //class of panel DIVs each holding content
autostep: {enable:true, moveby:1, pause:3000},
panelbehavior: {speed:500, wraparound:false, persist:true},
defaultbuttons: {enable: true, moveby: 1, leftnav: ['Untitled-2.gif', 10, 80], rightnav: ['Untitled-2_right.gif', -30, 80]},
statusvars: ['statusA', 'statusB', 'statusC'], //register 3 variables that contain current panel (start), current panel (last), and total panels
contenttype: ['inline'] //content setting ['inline'] or ['external', 'path_to_external_file']
})</p>
<p></script></p>

Every line break it determines as a <P>... There have been many angry bug reports in the Wordpress Codex, and they plan to fix it in a future release...

Not much you can do, file another report into Wordpress and maybe they'll be fed up with all the reports and fix the issue... ;)

// X96 \\

Dannymax
05-15-2009, 08:42 AM
Thanks for that X96 ,

I have found a way to get rid of those <p> tags using...

http://plugins.trac.wordpress.org/wiki/TextControl

might help you with some of your issues. Trouble is that the carousel still wont work, any other ideas?