You are missing our premiere tool bar navigation system! Register and use it for FREE!

NukeCops  
•  Home •  Downloads •  Gallery •  Your Account •  Forums • 
Readme First
- Readme First! -

Read and follow the rules, otherwise your posts will be closed
Modules
· Home
· FAQ
· Buy a Theme
· Advertising
· AvantGo
· Bookmarks
· Columbia
· Community
· Donations
· Downloads
· Feedback
· Forums
· PHP-Nuke HOWTO
· Private Messages
· Search
· Statistics
· Stories Archive
· Submit News
· Surveys
· Theme Gallery
· Top
· Topics
· Your Account
Who's Online
There are currently, 141 guest(s) and 0 member(s) that are online.

You are Anonymous user. You can register for free by clicking here
Nuke Cops :: View topic - need help adding javascript code to theme.php [ ]
 Forum FAQ  •  Search  •   •  Memberlist  •  Usergroups   •  Register  •  Profile •    •  Log in to check your private messages  •  Log in

 
Post new topic  Reply to topicprinter-friendly view
View previous topic Log in to check your private messages View next topic
Author Message
KevinE
Private
Private


Joined: Apr 18, 2004
Posts: 46


PostPosted: Tue Nov 15, 2005 5:55 am Reply with quoteBack to top

This is the code for Google's new free page tracking system and it requires it to be placed between the <head> and </head> on your home page. Can anyone explain to me where to put this code in the theme.php so that it will work the same way.

<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-XXXXXX-1";
urchinTracker();
</script>


Thanks in advance,
KevinE
Find all posts by KevinEView user's profileSend private message
KevinE
Private
Private


Joined: Apr 18, 2004
Posts: 46


PostPosted: Tue Nov 15, 2005 8:42 am Reply with quoteBack to top

I tried adding the code to my_header.php which according to the howto here says


The PHP-Nuke HTML header (i.e. everything that goes between the <head> and </head> tags in the HTML code of the generated page) is fully customizable through the includes/my_header.php file. This file contains whatever custom stuff you need to include in your site when the header loads.

But I keep getting a parse error on the very first line of code.



<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System */
/* =========================== */
/* */
/* Copyright (c) 2002 by Francisco Burzi */
/* http://phpnuke.org */
/* */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License. */
/************************************************************************/

if (eregi("my_header.php", $_SERVER['SCRIPT_NAME'])) {
Header("Location: ../index.php");
die();
}

<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-XXXXX-1";
urchinTracker();
</script>


?>
Find all posts by KevinEView user's profileSend private message
webjunky
Lieutenant
Lieutenant


Joined: May 11, 2003
Posts: 167


PostPosted: Tue Nov 15, 2005 9:03 am Reply with quoteBack to top

<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System */
/* =========================== */
/* */
/* Copyright (c) 2002 by Francisco Burzi */
/* http://phpnuke.org */
/* */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License. */
/************************************************************************/

if (eregi("my_header.php", $_SERVER['SCRIPT_NAME'])) {
Header("Location: ../index.php");
die();
}

?>
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-XXXXX-1";
urchinTracker();
</script>
<?

?>

_________________
- Do not pm me for help -
Find all posts by webjunkyView user's profileSend private message
KevinE
Private
Private


Joined: Apr 18, 2004
Posts: 46


PostPosted: Tue Nov 15, 2005 11:18 am Reply with quoteBack to top

It worked perfectly thanks WebJunky
Find all posts by KevinEView user's profileSend private message
Display posts from previous:      
Post new topic  Reply to topicprinter-friendly view
View previous topic Log in to check your private messages View next 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



Powered by phpBB © 2001, 2005 phpBB Group

Ported by Nuke Cops © 2003 www.nukecops.com
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::
Powered by TOGETHER TEAM srl ITALY http://www.togetherteam.it - DONDELEO E-COMMERCE http://www.DonDeLeo.com - TUTTISU E-COMMERCE http://www.tuttisu.it
Web site engine's code is Copyright © 2002 by PHP-Nuke. All Rights Reserved. PHP-Nuke is Free Software released under the GNU/GPL license.
Page Generation: 0.419 Seconds - 95 pages served in past 5 minutes. Nuke Cops Founded by Paul Laudanski (Zhen-Xjell)
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::