Author |
Message |
GanjaUK
Life Cycles Becoming CPU Cycles

Joined: Feb 14, 2004
Posts: 633
Location: England
|
Posted:
Sat Feb 14, 2004 1:57 pm |
|
I need to add a couple of bits of java to header.html for my site http://www.ganjauk.com when i add the java it does nothing.
on the GT website: http://gt.audioslaved.com/ like that at the top, i have been looking for a theme download that already has them in so i can break it down and see how it works.
Code:
<A HREF="#"
onClick="this.style.behavior='url(#default#homepage)';
this.setHomePage('http://www.GanjaUK.com');">
Set Homepage
</A>
|
Why does this above code not work in nuke?
If you dont know how, but know a theme that is for download that has these things in the header let me know so i can take a look how it works.
I posted this message on nuke cops but dont often get a reply there so i thought i would try this site.
Thanks |
|
|
|
 |
chatserv
Member Emeritus

Joined: May 02, 2003
Posts: 1389
Location: Puerto Rico
|
Posted:
Sat Feb 14, 2004 6:42 pm |
|
Post the section of the header with the code inserted in it. |
|
|
|
 |
GanjaUK

|
Posted:
Sat Feb 14, 2004 7:03 pm |
|
Thats a link to the header with the homepage java in, it works where it is now, but when its loaded up with the rest of the nuke page it no longer sets homepage.
http://www.exodia.34sp.com/ganjauk/portal/themes/GanjaUK-DaRkSiDe-Productions/header2.html
The homepage java does not require java in the head section, however i would like to add bookmark java to that header too, that does however require java in the head of the page.
Code:<script language="JavaScript1.2" type="text/JavaScript">
/*
GanjaUK.com*/
//bookmark
var bookmarkurl="http://www.GanjaUK.com"
var bookmarktitle="GanjaUK.com"
function addbookmark(){
if (document.all)
window.external.AddFavorite(bookmarkurl,bookmarktitle)
}
</script>
|
Soon as i learn how to put java into nuke i will be able to sort all this out, i just got stuck with the homepage link as it does not have any java so i couldnt work out why it does not work in nuke.
Any help would be much appreciated. |
|
|
|
 |
chatserv

|
Posted:
Sun Feb 15, 2004 10:05 pm |
|
Try placing the code inside of includes/my_header.php |
|
|
|
 |
GanjaUK

|
Posted:
Sun Feb 15, 2004 10:19 pm |
|
The code needs to be placed on the exact button on my header.
You can see my header on the site: http://www.ganjauk.com I want to put the homepage/set bookmark link on the buttons I have already put in place on the right of the header (Above the forward/rewind buttons).
Make homepage button does not need any code other than the onClick tag in the <body> of the page.
The problem seems to be nuke adds \ infront of every ' |
|
|
|
 |
chatserv

|
Posted:
Sun Feb 15, 2004 10:30 pm |
|
Then you could try placing the make homepage code inside of your theme's themeheader() function |
|
|
|
 |
GanjaUK

|
Posted:
Mon Feb 16, 2004 10:02 am |
|
I added this line to the themeheader()
Code:
$set_homepage = "<A HREF=\"#\"
onClick=\"this.style.behavior='url(#default#homepage)';
this.setHomePage('http://www.GanjaUK.com');\">\n";
|
I then added $set_homepage to my header.html It went in the right place but the output of it still has the \ inside which stops it from working. Is there some way to put it in theme header so it ignores the \
This is probably starting to sound confusing now, i hope you can bare with me.  |
|
|
|
 |
chatserv

|
Posted:
Mon Feb 16, 2004 10:27 am |
|
Try this one:
Code:<!--[if IE]>
<font face="Arial" size="3">
<A HREF=\"#\"
onClick=\"this.style.behavior='url(#default#homepage)';
this.setHomePage('http://www.GanjaUK.com'');\">
Make GanjaUK Your Homepage
</A>
</font>
<![endif]-->
|
|
|
|
|
 |
GanjaUK

|
Posted:
Mon Feb 16, 2004 10:42 am |
|
Thats the same code. The only probably seems to be that nuke changes
to
Should i try adding it to includes/javascript.php? |
|
|
|
 |
GanjaUK

|
Posted:
Mon Feb 16, 2004 11:05 am |
|
I think i need to echo the line, but i dont know how to do that so it only displays where i type $set_homepage and call it from header.html |
|
|
|
 |
GanjaUK

|
Posted:
Mon Feb 16, 2004 2:46 pm |
|
It's fixed now, open theme.php and change:
to
Code:print stripslashes($r_file);
|
|
|
|
|
 |
chatserv

|
Posted:
Mon Feb 16, 2004 2:49 pm |
|
|
|
 |
|