PHP Web Host - Quality Web Hosting For All PHP Applications $35/month $250/year (Unlimited) - $25/month - 200,000 impressions - Your Ad Could be Here - Click For Details
  Login or Register
 • Home • Downloads • Your Account • Forums • 

View next topic
View previous topic


Google
 
Web RavenPHPScripts (This Site)
Post new topic   Reply to topic
Author Message
SV_JJSKID
New Member
New Member


Joined: Sep 06, 2004
Posts: 11

PostPosted: Mon Sep 06, 2004 12:50 am Reply with quote Back to top

Hi,
I'm new to the forum and have been able to do just about everything I wanted to do with my site thanks to this forum:) Between this site and PHPNUKE I've become interested in building websites again and have also gotten my brain racked with learning php. But alas, I have hit a bump and now I need some specific help.

Today, I spent all afternoon making a swell flash .swf for my Freelancer clan site
Only registered users can see links on this board!
Get registered or login to the forums!
and I got it to work by editing the file: header.html simply enough and added this code on line 3. In my search I noticed others with .swf troubles so here's my simplistic solution.
_______________________________________________________________
<td align="center" <object width="100%" height="155"><param name="movie" value="hmdl.swf"> <embed width="755" height="155" src="themes/subBlack3dBlue/forums/images/hmdl.swf"></embed></object></a></embed></td>
_______________________________________________________________

All that worked great and I like the way it looks with my theme BUT.... I don't like that it's on every page of the site because it's about 72Kb and also because the sounds I put in it get old after changing pages a few times.

What I would like to do is to point the site index to a special header file maybe e.x. header2.html. Then and add a new, smaller, less noisy .swf to the original header.html for every other page generated on the site. I'm hoping that the index alone can be pointed to header2.html, and leave the rest of the site pointing to the original header.html that it would save alot of editing.

A bit long winded I know but that's my process at work Idea Any help would be appreciated. Thank you
SV_JJSKID
View user's profile Send private message
GanjaUK
Life Cycles Becoming CPU Cycles


Joined: Feb 14, 2004
Posts: 633
Location: England

PostPosted: Mon Sep 06, 2004 9:43 am Reply with quote Back to top

SV_JJSKID, have you thought about maybe using a splash page with your noisy flash on? That way people will only hear it once before they enter the site. As users would be hitting the index a fair bit and it might be just as annoying.

You could still achieve what you was looking for originally by coding theme.php a little but what I suggested above might be the better solution. What do you think?
View user's profile Send private message Visit poster's website
SV_JJSKID
New Member
New Member


Joined: Sep 06, 2004
Posts: 11

PostPosted: Mon Sep 06, 2004 5:52 pm Reply with quote Back to top

While a splash page would do the trick I've used them on other sites and users would still get them as they entered the site anyway so I personally would rather just get to the index where the links are. I'm more interested in going the themes.php route but it's really beyond my abilities with php now, I'm still learning.
View user's profile Send private message
GanjaUK
Life Cycles Becoming CPU Cycles


Joined: Feb 14, 2004
Posts: 633
Location: England

PostPosted: Mon Sep 06, 2004 7:46 pm Reply with quote Back to top

Open up theme.php we are working in the Function themeheader() section. Add $home to the globals.

Then add this code somewhere below:
Code:

    if ($home==1) {
   $header_flash = "<object width=\"100%\" height=\"155\"><param name=\"movie\" value=\"MOVIE1.swf\"> <embed width=\"755\" height=\"155\" src=\"/themes/subBlack3dBlue/forums/images/MOVIE1.swf\"></embed></object>";
    } else {
   $header_flash = "<object width=\"100%\" height=\"155\"><param name=\"movie\" value=\"MOVIE2.swf\"> <embed width=\"755\" height=\"155\" src=\"/themes/subBlack3dBlue/forums/images/MOVIE2.swf\"></embed></object>";
    }


Now open header.html and replace your flash code with: $header_flash

MOVIE1 is the flash for index.php, and MOVIE2 will load up on any other page. I tested this and it works perfectly.
View user's profile Send private message Visit poster's website
SV_JJSKID
New Member
New Member


Joined: Sep 06, 2004
Posts: 11

PostPosted: Mon Sep 06, 2004 9:09 pm Reply with quote Back to top

I tried it and couldn't get it to fly. Here's what I did...



THEME.PHP__________________________________________________

function themeheader() {
global $admin, $home, $user, $banners, $sitename, $slogan, $cookie, $prefix, $db, $nukeurl, $anonymous;
if ($banners == 1) {
$numrows = $db->sql_numrows($db->sql_query("SELECT * FROM ".$prefix."_banner WHERE type='0' AND active='1'"));
/* Get a random banner if exist any. */
/* More efficient random stuff, thanks to Cristian Arroyo from
Only registered users can see links on this board!
Get registered or login to the forums!
*/

if ($home==1) {
$header_flash = "<object width=\"100%\" height=\"155\"><param name=\"movie\" value=\"hmdl.swf\"> <embed width=\"755\" height=\"155\" src=\"/themes/subBlack3dBlue/forums/images/hmdl.swf\"></embed></object>";
} else {
$header_flash = "<object width=\"100%\" height=\"155\"><param name=\"movie\" value=\"hmdl2.swf\"> <embed width=\"755\" height=\"155\" src=\"/themes/subBlack3dBlue/forums/images/hmdl2.swf\"></embed></object>";
}
______________________________________________________________

HEADER.HTML_________________________________________________

Replaced

<tr>
<td align="center" <object width="100%" height="155"><param name="movie" value="hmdl.swf"> <embed width="755" height="155" src="themes/subBlack3dBlue/forums/images/hmdl.swf"></embed></object></a></embed></td>
</tr>

With
<tr>
<td align="center">$header_flash</a></td>
</tr>
_______________________________________________________
View user's profile Send private message
GanjaUK
Life Cycles Becoming CPU Cycles


Joined: Feb 14, 2004
Posts: 633
Location: England

PostPosted: Mon Sep 06, 2004 9:24 pm Reply with quote Back to top

Looks like you added the flash code in theme.php inside the banners code. As I don't see any closing }

You need to add that code on it's own. For example look for:
Code:
$public_msg = public_message();


Make a new line above that and put it there.
View user's profile Send private message Visit poster's website
SV_JJSKID
New Member
New Member


Joined: Sep 06, 2004
Posts: 11

PostPosted: Mon Sep 06, 2004 9:34 pm Reply with quote Back to top

Sweet it works Exclamation Thanks a lot for the help Very Happy

Check it out fl.sv1web.com
View user's profile Send private message
GanjaUK
Life Cycles Becoming CPU Cycles


Joined: Feb 14, 2004
Posts: 633
Location: England

PostPosted: Mon Sep 06, 2004 9:38 pm Reply with quote Back to top

Cool Your welcome. And yeah looks good. Wink
View user's profile Send private message Visit poster's website
Display posts from previous:       
Post new topic   Reply to topic

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Forums ©
 

All logos and trademarks in this site are property of their respective owner.
The comments are property of their posters, all the rest © 2002-2008 by Raven
Proud to be listed at Lobo Links Web Directory

You can syndicate our news using the file xml

CSE HTML Validator Helped Clean up This Page! [Valid RSS] valid RSS 2.0 Valid robots.txt Stop Spam Harvesters, Join Project Honey Pot

Website engines core code is © copyright by PHP-Nuke but has been heavily patched and modified by myself and others.
PHP-Nuke is a free software released under the GNU/GPL.


:: fisubice phpbb2 style by Daz :: PHP-Nuke theme by www.nukemods.com ::

:: fisubice Theme Recoded To 100% W3C CSS & HTML 4.01 Transitional Compliance by Raven and 64bitguy ::

:: W3C CSS Compliance Validation :: W3C HTML 4.01 Transitional Compliance Validation ::

zerosum