Adding Flash Header In Drupal


Author Message
Tom

Posted: 4/30/2009
Quote message 

I cannot figure out how to add a flash header to my Drupal theme that I have created with Artisteer, I have figured out how to insert a rotate.php and I can get random pics to appear in my header but I would love to be able to insert a swf file. Help this is got to be simple but I cant figure it out!
 
Garry

Posted: 5/1/2009
Quote message 

You ca do it by inserting following code:

<object width="550" height="400">
<param name="movie" value="somefilename.swf">
<embed src="somefilename.swf" width="550" height="400">
</embed>
</object>
 
bluehead

Posted: 5/1/2009
Quote message 

I managed this by adding the region and pasting flash in to the block, but
you can do this by adding the layer in page.tpl.php and page.tpl.php files



 
Tom

Posted: 5/1/2009
Quote message 

Hey I have tried to use code like Garry has suggested and cannot get it to display the flash. I don't know if I'm not inserting it the right place under the right div ect. I also don't know if it is a css problem. Its very frustrating I need help!
 
Tom

Posted: 5/1/2009
Quote message 

Ok I did get the flash header to appear but only on the /admin/build/themes page or any other admin pages, how do i get it to appear on all pages?

PS thanks for your help thus far!
 
Garry

Posted: 5/2/2009
Quote message 

As Bluehead said "I managed this by adding the region and pasting flash in to the block, but you can do this by adding the layer in page.tpl.php and page.tpl.php files"

You can try creating new region
 
Tom

Posted: 5/2/2009
Quote message 

Ok I got the flash content to appear after adding a new region, THANKS FOR THE INPUT

But I still have a problem it only appers on admin pages and not on the pages I have created, not sure why! I have a fair amount of experience with blocks and I do have the "Show on every page except the listed pages." selected ect. but it still cannot get it to appear on my pages I created! But it appears on all admin pages!
 
john

Posted: 5/2/2009
Quote message 

http://tidbits.ben-mullikin.com/
 
Tom

Posted: 5/2/2009
Quote message 

I have got the flash in the header but it only shows on admin pages and not on any of the nodes i have created
 
bluehead

Posted: 5/5/2009
Quote message 

http://ppwebstudio.co.uk/rmf/

This is a flash inserted to a header through the block.
Is this what you want to achieve?
 
Tom

Posted: 5/5/2009
Quote message 

Yes this is similar with what I am trying to do!
 
bluehead

Posted: 5/5/2009
Quote message 

So define a region in your_module.info file and insert a code

to page.tpl.php and page-node.tpl.php

<div class="Header">
<div class="Header-jpeg"></div>

just after header-jpeg

<?php if ($your_new_region) : ?>
<div class="new_region_layer"><?php echo $your_new_region; ?></div>
<?php endif; ?>


Then create a new block and paste

<embed width="270" height="115" menu="true" loop="true" play="true" wmode="transparent" src="http://your_logo_path/logo.swf" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash"></embed>

set the input format for fullHTML

good luck
 
bluehead

Posted: 5/5/2009
Quote message 

remember to clear the cache after you add the region in the *.info file
 
Tom

Posted: 5/5/2009
Quote message 

Thanks for that beautiful set of instructions! But sad to say after about 20 hours of work and just last night I figured out that the code had to be in both the page.tpl.php and page-node.tpl.php. If only someone had made this plane before, mabey Artisteer could add it to the FAQ or something I new it had to be able to be done but fought and fought with it. But thanks for the clear insturctions I am sure this will help others!!!!

One other problem I am haveing is theming the new reagon in CSS it seems becaue we are displaying it as a block their are some block CSS styles that are not giving me full control of where the SWF displays. For example I have to use weard -11left margin to get the swf to line up right, not sure whats going on, let me know if you can help, It would be greatly appreciated.

P.S. I also found some pretty cool php code that will randomely load different SWF files wich makes for a pretty cool header.
 
bluehead

Posted: 5/6/2009
Quote message 

Tom - can you send me an email on webmaster@ppwebstudio.co.uk
 
Tom

Posted: 5/6/2009
Quote message 

Hey I sent you that email!
 
Thor

Posted: 5/15/2009
Quote message 

Quote bluehead:

So define a region in your_module.info file and insert a code

to page.tpl.php and page-node.tpl.php

<div class="Header">
<div class="Header-jpeg"></div>

just after header-jpeg

<?php if ($your_new_region) : ?>
<div class="new_region_layer"><?php echo $your_new_region; ?></div>
<?php endif; ?>


Then create a new block and paste

<embed width="270" height="115" menu="true" loop="true" play="true" wmode="transparent" src="http://your_logo_path/logo.swf" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash"></embed>

set the input format for fullHTML

good luck


this code picks up the Block style definitions, is there a way to turn those off for the header block only?
 
bluehead

Posted: 5/31/2009
Quote message 

yes

give them style i.e

#block-block-14 .Block-tl, #block-block-14 .Block-tr, #block-block-14 .Block-bl, #block-block-14 .Block-br, #block-block-14 .Block-tc, #block-block-14 .Block-bc, #block-block-14 .Block-cl, #block-block-14 .Block-cr, #block-block-14 .Block-cc {
display:none;
}
 
phicarre

Posted: 6/5/2009
Quote message 

And what about the class "new_region_layer" ?
 
phicarre

Posted: 6/5/2009
Quote message 

... and I would like to have my swf instead of the "background" in order to have the possibility to display the foreground photo and the title.

I tried your suggestion. My swf covered all these things !
 
hmt3

Posted: 7/10/2009
Quote message 

I submitted it as a feature request, but if anyone from Artiseer is reading this forum post - the ability to insert a Flash header would be a very nice option in the Header tab.
 
gems730917

Posted: 8/11/2009
Quote message 

Hi folks.

Great document, but i'm stuck with the "pick up the Block style definitions".

"this code picks up the Block style definitions, is there a way to turn those off for the header block only?"

The answer is: yes give them style i.e #block-block-14 .Block-tl.....

I'm working in a charity site, and unfortunately my experiece is limited as a rookie :(.

Could you help me on "how to give the style" mean?. Thanks.
 
bluehead

Posted: 8/19/2009
Quote message 

@gems730917 send me your email on webmaster@ppwebstudio.co.uk
 
shawn

Posted: 9/14/2009
Quote message 

I completely agree - ability to add flash or other objects is high value!
Quote hmt3:

I submitted it as a feature request, but if anyone from Artiseer is reading this forum post - the ability to insert a Flash header would be a very nice option in the Header tab.


 
bhd

Posted: 10/2/2009
Quote message 

Quote shawn:

I completely agree - ability to add flash or other objects is high value!
Quote hmt3:

I submitted it as a feature request, but if anyone from Artiseer is reading this forum post - the ability to insert a Flash header would be a very nice option in the Header tab.




You can't put flash into CSS. Flash is the content not a structure.

 
hmt3

Posted: 10/13/2009
Quote message 

Quote bhd:

Quote shawn:

I completely agree - ability to add flash or other objects is high value!
Quote hmt3:

I submitted it as a feature request, but if anyone from Artiseer is reading this forum post - the ability to insert a Flash header would be a very nice option in the Header tab.




You can't put flash into CSS. Flash is the content not a structure.



So put the coding into the php files. We want the ability to create Flash headers.

Of course, having gone round and round on this issue, perhaps the easiest solution is to allow for the creation of a "Header" block and "Menu" block. Then we could do this in Drupal.

The best reason for buying Artisteer is that it creates all of the massively complicated coding (for non-propeller heads) that makes a theme work. The drawback is that if we want to incorporate something that Artisteer doesn't offer out of the box, like a Flash header, we have to dig into PHP code, figure out what Artisteer did and come up with a workaround.

I realize that feature requests are coming at the developers fast and furious. But if someone can post a workaround on the forums; then why can't the workaround be implemented into the program?
 
Peter

Posted: 10/13/2009
Quote message 

i use fckeditor + imce
In Input Format add <embeb><img> ( and others input formats, see fckeditor readme)
and that´s all