PDA

Zobacz pełną wersję : Template-top w swf



snake1984
15-02-2011, 09:32
Witam,
Jestem początkujący i mam pytanie, jak mogę zrobić top we flashu, bo aktualnie mam go w png z wipsem w css :

#template-top { color: #fff; width: 980px; height: 300px; text-align: left; background: url(../images/bck.png) no-repeat left top; margin-left: auto; margin-right: auto; }

a chciałbym przerobić jakoś żeby było flash.
Z góry dziękuję za pomoc.

tomaszek83
15-02-2011, 10:06
że tak się zapytam... a jaki cel ma ta zamiana na flash? no i z tego co wiem to PNG jest statyczne a Flash dynamiczne... no ale chyba że chcesz zmienić zawartość div-a o id "top". To co innego. Można tam umieścić moduł wyświetlający flasha, ewentualnie osadzić w pliku index.php statycznie plik flashowy. Ale żeby zrobić jedno i drugie trzeba się trochę znać na html, css...

a tak już poza tym to nikt bez linka do strony Ci nie pomoże...

snake1984
27-03-2011, 18:56
ok zrobiłem już pierwszy krok, znalazłem w index.php user4 i osadziłem flasha ale nie mogę go wyrównać do lewej. Czy mam zmieniać na pałę w css czy coś w index grzebać. oto link http://snake1984.nazwa.pl/testowy


index wyglada tak



<?php
/**
* @copyright Copyright (C) 2005 - 2007 Open Source Matters. All rights reserved.
* @license GNU/GPL, see LICENSE.php
* Joomla! is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined( '_JEXEC' ) or die( 'Restricted access' );
require_once dirname(__FILE__) . DIRECTORY_SEPARATOR . 'com.php';
$tg = 0;
if ($this->countModules('left') == 0 && $this->countModules('right') == 0 ) { $tg = 1; }
if ($this->countModules('left') && $this->countModules('right') == 0) { $tg = 2; }
if ($this->countModules('left') == 0 && $this->countModules('right')) { $tg = 3; }
if ($this->countModules('left') && $this->countModules('right')) { $tg = 4; }
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $this->language; ?>" lang="<?php echo $this->language; ?>">
<head><jdoc:include type="head" />
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/system/css/system.css" type="text/css" />
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/system/css/general.css" type="text/css" />
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/<?php echo $this->template?>/css/style.css" type="text/css" />
<?php if ($this->countModules('hornav')): ?>
<script language="javascript" type="text/javascript" src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template?>/js/moomenu.js"></script>
<?php endif; ?>
<!--[if lte IE 6]>
<style>
#hornav ul li ul {
left: -999em;
margin-top: 0px;
margin-left: 0px;
}
.tg-top, .tg-bottom, .tg { behavior: url("templates/TEMPLATENAME/css/fix.htc"); }
</style>
<![endif]-->
</head>
<body>
<div id="tg-top" class="tg-top"></div>
<div id="tg" class="tg">
<div id="template-top">
<div class="template-top-">
<div id="logo"></div>
</div>
<div class="template-top">

<div id="template-top-second"><jdoc:include type="modules" name="user4" style="xhtml" />

<object type="application/x-shockwave-flash" data="images/kino.swf" style="height:150px; width:980px;">
<param name="movie" value="images/kino.swf" />
<param name="quality" value="high" />
<param name="scale" value="noScale" />
<param name="menu" value="false">
<param name="bgcolor" value="#333333">
<param name="pluginurl" value="http://www.macromedia.com/go/getflashplayer" />
</object>

</div>
</div>
</div>
<div id="template-menu"><div id="hornav"><jdoc:include type="modules" name="user3" style="xhtml" /></div></div>

<div id="template">
<div id="template-center<?php echo $tg ?>">
<?php if ($this->countModules('left')) { ?><div id="allsidebar-left"><jdoc:include type="modules" name="left" style="tg" /></div><?php } ?>
<div id="template-center-center<?php echo $tg ?>">
<div id="template-center-center-center<?php echo $tg ?>"><jdoc:include type="component" />
<div id="tg-advert1"><jdoc:include type="modules" name="tg-advert1" /></div><?php include "html/mod_mostread/component.php"; ?>
</div>
</div>
<?php if ($this->countModules('right')) { ?><div id="allsidebar-right"><jdoc:include type="modules" name="right" style="tg" /></div><?php } ?>
<div style="clear: both;"></div></div>
</div>
<?php if ($this->countModules('tg-user3') || $this->countModules('tg-user4')) { ?>
<div id="tg-user-bottom" class="clearfix">
<div class="tg-user3"><jdoc:include type="modules" name="tg-user3" style="xhtml" /></div>
<div class="tg-user4"><jdoc:include type="modules" name="tg-user4" style="xhtml" /></div>
</div>
<?php } ?>
<div id="tg-bottom-menu" class="clearfix">
<div id="tg-bottom-menu-left"><div id="credit" class="credit">Joomla <a href="http://www.educationtemplate.com" target="_blank">Education template</a> by <a href="http://www.earnmoneyanytime.com" target="_blank">Earn Money</a>.</div></div>
<div id="tg-bottom-menu-right"></div>
</div>
</div>
<div id="tg-bottom" class="tg-bottom"></div>

</body>
</html>

nikszal
27-03-2011, 19:13
Nie masz szansy osadzenia flasha długiego na 980px w pozycji user4. Bez stosownych zmian w css nie osadzisz prawidłowo tej animacji.

a_m
27-03-2011, 19:14
wywal .template-top- z zawartością z index php

///
ale w obecnym układzie - @nikszal ma rację

snake1984
27-03-2011, 19:20
jak wywalam to flash spada w dól a header jest nad flashem.
@nikszal więc co mógłbym zmienić lub wywalić z css??

a_m
27-03-2011, 19:23
<div id="tg-top" class="tg-top"></div>
<div id="tg" class="tg">
<div id="template-top">
<div class="template-top-">
<div id="logo"></div>
</div>
<div class="template-top">
<div id="template-top-second"><jdoc:include type="modules" name="user4" style="xhtml" />

snake1984
27-03-2011, 19:26
jak wywalam :

<div class="template-top-">
<div id="logo"></div>
</div>

to całe menu i środek mi wycina

a_m
27-03-2011, 19:29
bo pewnie coś źle robisz

snake1984
27-03-2011, 19:30
UDAŁO SIĘ :D

div id="tg-top" class="tg-top"></div>
<div id="tg" class="tg">
<div id="template-top">
<div class="template-top-">
<div id="logo">

<object type="application/x-shockwave-flash" data="images/kino.swf" style="height:150px; width:980px;">
<param name="movie" value="images/kino.swf" />
<param name="quality" value="high" />
<param name="scale" value="noScale" />
<param name="menu" value="false">
<param name="bgcolor" value="#333333">
<param name="pluginurl" value="http://www.macromedia.com/go/getflashplayer" />
</object>

</div>
</div>
<div class="template-top">

<div id="template-top-second"><jdoc:include type="modules" name="user4" style="xhtml" />



</div>
</div>


wsadziłem obiekt w id="logo" i w css zmieniłem : padding-top: 0px; padding-left: 0px; na 0.
Dzięki za pomoc pozdrawiam.