Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> How To's
Author Message
Bravo2zero
Regular
Regular


Joined: Nov 28, 2005
Posts: 92
Location: UK

PostPosted: Sat Jan 07, 2006 7:36 pm Reply with quote

Hi can anyone tell me if it is possible to have a different logo.gif in nuke 7.6 everytime you visit the site or refresh the page etc,

i have seen this done with cpg dragonfly etc,

any help appreciated

B2Z

_________________
dodging bullets ain't easy but it's a job! 
View user's profile Send private message
hitwalker
Sells PC To Pay For Divorce


Joined:
Posts: 5661

PostPosted: Sat Jan 07, 2006 8:32 pm Reply with quote

well you could replace your logo code with this..
simple but effective.. Only registered users can see links on this board! Get registered or login!
 
View user's profile Send private message
Bravo2zero
PostPosted: Sat Jan 07, 2006 9:38 pm Reply with quote

thanks for the reply, i have tried to have a go but i'm not that good at this,

ok i have removed the logo.gif line etc, and replaced with the script etc from your link you supplied,
now the orignal logo has gone but nothing has been replaced????

i think it may be to do with not knowing where to find the images? and the help file don't explain how to link the images to the folder where they are on the server etc,

can you advise me please what i'm doing wrong.

thanks inadvance
B2Z
 
hitwalker
PostPosted: Sun Jan 08, 2006 5:51 am Reply with quote

well you could have tried the sample there..
as far as it looks no paths are realy given..
and the image is in the folder where the script runs.
just try a few...
 
Bravo2zero
PostPosted: Sun Jan 08, 2006 7:21 am Reply with quote

this may sound daft but i do have to add the script in the themes header not the html/header.php in the root?

just that our theme header is .html not .php ?

also can it go anywhere in the header or will it have to be on the line i removed for the logo.gif?

thanks in advance

B2Z
 
hitwalker
PostPosted: Sun Jan 08, 2006 7:24 am Reply with quote

yes it sure is recommended to place it where your logo was....
and put the code in your custom-header.php after the ?> tag.
 
Bravo2zero
PostPosted: Sun Jan 08, 2006 7:36 am Reply with quote

I have uploaded the file to our server for you to look at as it won't let me paste in here, can you look at it please and tell me whats wrong.
Only registered users can see links on this board! Get registered or login!

and this is the original below
Only registered users can see links on this board! Get registered or login!
i have placed a 1 in the header name just for folder purpose ok.

thans B2Z
 
hitwalker
PostPosted: Sun Jan 08, 2006 7:51 am Reply with quote

no no no...i said to put the code in includes/custom_files/custom_header.php after the php closing tag..
 
Bravo2zero
PostPosted: Sun Jan 08, 2006 7:54 am Reply with quote

ok i don't have a custom_header.php in that location you have said just an index.php,

sorry to be real lame here but i'm still learning this php lark.

thanks B2Z
 
hitwalker
PostPosted: Sun Jan 08, 2006 8:02 am Reply with quote

ok listen...
go into your includes folder and if its not there create a folder called custom_files
next... in that folder put a file called custom_head.php

next....in that file put the following content....

<?php
if (stristr($_SERVER['SCRIPT_NAME'], "custom_head.php")) {
Header("Location: ../index.php");
die();
}

?>
put here your logo code.. understand?
 
Bravo2zero
PostPosted: Sun Jan 08, 2006 8:13 am Reply with quote

ok lets see if i'm learning or getting worse Rolling Eyes Only registered users can see links on this board! Get registered or login!

i have the location custom files etc already as you said, now in there i copied a php file, edited it and removed all coding, then added your one, at the end othe tag>i added the script fom the site.

uploaded it and still nothing so guess i'm not getting the full picture, or was i supposed to have the coding in it as the original header.html ?

and i copied all three logos to the custom files folder

thanks for being patient

B2Z
 
hitwalker
PostPosted: Sun Jan 08, 2006 8:29 am Reply with quote

ok...seems ok...
now the ... printImage(); script part should be in the theme header as it is already?
Ok..now you gotta try to put the images at some places cause i dont know how from what path it will look for it...
 
Bravo2zero
PostPosted: Sun Jan 08, 2006 8:32 am Reply with quote

function printImage() {
var r = Math.ceil(Math.random() * NumberOfImagesToRotate);
document.write(FirstPart + r + LastPart);
}

just that part? do i add this anywhere if so in the theme header? also do i need to take out the line again for the logo in the theme header or will it overide it?
 
hitwalker
PostPosted: Sun Jan 08, 2006 8:34 am Reply with quote

well i think its better you provide someone some login stuff to help you cause this is taking to much time....
 
Bravo2zero
PostPosted: Sun Jan 08, 2006 8:44 am Reply with quote

if you are to busy i fully understand but as i said i'm learning as i go along here, and everyone needs to learn and start somewhere,

it may seem very simple to some people but those learning need a bit more explainging to,

now the ... printImage(); script part should be in the theme header as it is already?

i don't understand you on this? the header.html i have in my theme is a original version now, except for the line of the logo has been removed, and has none of the new script in there, as i thought you said in needed to go only in the includes/custom files/custom_header.php ???
i have added the three new logo's to theme root, theme images, and also to includeds/custom files folder.

if you can't help please just say and i will try to find a way to get it sorted,

thanks in advance

B2Z
 
hitwalker
PostPosted: Sun Jan 08, 2006 8:57 am Reply with quote

again...
this script comes in 2 parts !
The first part is the big that goes in your custom_head.php (as you already did)

The second part...(as the tutorial explains on that website) is where you want the random logo to show !
The were talking about the java script lines with printImage(); in it...

That part takes the place where you had your logo....
 
Bravo2zero
PostPosted: Sun Jan 08, 2006 9:23 am Reply with quote

sorted now, you have to add the logo1.gif/logo2.gif/logo3.gif to the main httpdocs root,

it is now working a treat, thanks a bunch for your help, i'm sorry it took so long but once the penny drops and clicks as to speak, all becomes clearer.

thanks again for your patience

B2Z
 
hitwalker
PostPosted: Sun Jan 08, 2006 9:40 am Reply with quote

ok good luck..
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> How To's

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
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©