/    Sign up×
Community /Pin to ProfileBookmark

dynamic title script help?

i am having a problem getting a script to work correctly and im hoping someone can help me out??

im trying to install the dynamic title script and im getting an error message “object expected”

the body instructions are as follows…

<!– STEP TWO: Insert the onLoad event handler into your BODY tag –>

<BODY onLoad=”settitle()”>

and the following is how i added it

<BODY BGCOLOR=#FFFFFF LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0 background=”images/bgb.gif” onload=”dynAnimation(); settitle();”>

i contacted someone earlier for help with putting two onload commands in the same line (as shown above) so that is what i did, but maybe its wrong or i didnt do it right?

i hope i have explained this well enough?
if not just reply and i will explain more!
thanks!!

to post a comment
JavaScript

4 Comments(s)

Copy linkTweet thisAlerts:
@pyroOct 07.2003 — Can we see the actual script(s) please?
Copy linkTweet thisAlerts:
@NorthernerauthorOct 07.2003 — [b]here is the script im wanting to install, i have the first part put into the head[/b]


<!-- TWO STEPS TO INSTALL DYNAMIC TITLE:

  • 1. Copy the coding into the HEAD of your HTML document

  • 2. Add the onLoad event handler into the BODY tag -->


  • <!-- STEP ONE: Paste this code into the HEAD of your HTML document -->

    <HEAD>

    <SCRIPT LANGUAGE="JavaScript">

    <!-- This script and many more are available free online at -->

    <!-- The JavaScript Source!! http://javascript.internet.com -->

    <!-- Asif Nasir ([email protected]) -->

    <!-- Begin

    function settitle() {

    var a = "You can find every thing you need here. ";

    var b = "Best collection of scripts";

    var c = "Easy to use through cut & paste";

    var t = new Date();

    s = t.getSeconds();

    if (s == 10) {

    document.title = a;}

    else if (s == 20) {

    document.title = b;}

    else if (s == 30) {

    document.title = c;}

    else if (s == 40) {

    document.title = a;}

    else if (s == 50) {

    document.title = b;}

    else if (s == 00) {

    document.title = c;}

    setTimeout("settitle()", 1000);

    }

    // End -->

    </script>


    <!-- STEP TWO: Insert the onLoad event handler into your BODY tag -->

    <BODY onLoad="settitle()">

    <p><center>

    <font face="arial, helvetica" size"-2">Free JavaScripts provided<br>

    by <a href="http://javascriptsource.com">The JavaScript Source</a></font>

    </center><p>

    <!-- Script Size: 1.17 KB -->



    [b]and this is part of where im trying to install the 'onload' section[/b]


    </script>

    <script language="JavaScript1.2" fptype="dynamicanimation" src="file:///C:/Program%20Files/Microsoft%20Office/Office10/fpclass/animate.js">

    </script>

    </HEAD>

    <BODY BGCOLOR=#FFFFFF LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0 background="images/bgb.gif" onload="dynAnimation()">

    <table width="780" border="0" cellspacing="0" cellpadding="0" height="81">

    <tr>

    <td height="81" background="images/logo3.jpg">&nbsp;<div align="right">

    <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="60%" id="AutoNumber1" height="54">

    <tr>

    <td width="100%" height="19">&nbsp;</td>

    </tr>

    <tr>

    [b]i hope that is enough info, if not just let me know!



    thanks[/b]
    Copy linkTweet thisAlerts:
    @pyroOct 07.2003 — Try:

    &lt;script type="text/javascript"&gt;

    &lt;!-- This script and many more are available free online at --&gt;
    &lt;!-- The JavaScript Source!! <a href="http://javascript.internet.com">http://javascript.internet.com</a> --&gt;
    &lt;!-- Asif Nasir ([email protected]) --&gt;

    &lt;!-- Begin
    function settitle() {
    var a = "You can find every thing you need here. ";
    var b = "Best collection of scripts";
    var c = "Easy to use through cut &amp; paste";
    var t = new Date();
    s = t.getSeconds();
    if (s == 10) {
    document.title = a;}
    else if (s == 20) {
    document.title = b;}
    else if (s == 30) {
    document.title = c;}
    else if (s == 40) {

    document.title = a;}
    else if (s == 50) {
    document.title = b;}
    else if (s == 00) {
    document.title = c;}
    setTimeout("settitle()", 1000);
    }
    // End --&gt;
    &lt;/script&gt;

    &lt;script language="JavaScript1.2" fptype="dynamicanimation" src="file:///C:/Program%20Files/Microsoft%20Office/Office10/fpclass/animate.js"&gt;
    &lt;/script&gt;
    &lt;/HEAD&gt;
    &lt;BODY BGCOLOR=#FFFFFF LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0 background="images/bgb.gif" onload="dynAnimation(); settitle();"&gt;
    &lt;table width="780" border="0" cellspacing="0" cellpadding="0" height="81"&gt;
    &lt;tr&gt;
    &lt;td height="81" background="images/logo3.jpg"&gt; &lt;div align="right"&gt;
    &lt;table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="60%" id="AutoNumber1" height="54"&gt;
    &lt;tr&gt;
    &lt;td width="100%" height="19"&gt; &lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
    Copy linkTweet thisAlerts:
    @NorthernerauthorOct 07.2003 — still not working,

    i have tried tons of different things, looks like a problem in another area of code?

    sorry for wasting your time but im giving up, im not experienced enough at this
    ×

    Success!

    Help @Northerner spread the word by sharing this article on Twitter...

    Tweet This
    Sign in
    Forgot password?
    Sign in with TwitchSign in with GithubCreate Account
    about: ({
    version: 0.1.9 BETA 5.3,
    whats_new: community page,
    up_next: more Davinci•003 tasks,
    coming_soon: events calendar,
    social: @webDeveloperHQ
    });

    legal: ({
    terms: of use,
    privacy: policy
    });
    changelog: (
    version: 0.1.9,
    notes: added community page

    version: 0.1.8,
    notes: added Davinci•003

    version: 0.1.7,
    notes: upvote answers to bounties

    version: 0.1.6,
    notes: article editor refresh
    )...
    recent_tips: (
    tipper: @Yussuf4331,
    tipped: article
    amount: 1000 SATS,

    tipper: @darkwebsites540,
    tipped: article
    amount: 10 SATS,

    tipper: @Samric24,
    tipped: article
    amount: 1000 SATS,
    )...