SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    Non-Member
    Join Date
    Sep 2010
    Posts
    17
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    how to enter copyright ?

    Hi all
    I have launched my new web site :-)
    I want to insert like this"Copyright ©2000 - 2011, "
    how to insert this with the help of JavaScript?
    I have tried but web page shows
    " [an error occurred while processing this directive] "
    Can you help me to avoid this error?

  2. #2
    SitePoint Wizard donboe's Avatar
    Join Date
    Jun 2010
    Location
    Netherlands
    Posts
    1,967
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Maybe you can show the javascript you used. Another way of doing this is to use server side scripting (PHP, ASP, Coldfusion etc..)
    “Good artists copy, great artists steal” (Pablo Picasso - 1934)

  3. #3
    Programming Since 1978 silver trophybronze trophy felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, NSW, Australia
    Posts
    16,607
    Mentioned
    24 Post(s)
    Tagged
    1 Thread(s)
    The text you want to insert written in HTML and JavaScript would be:

    "Copyright ©2000 - "+today.getFullYear();

    assuming you have already defined today using:

    var today = new Date();

    It would still be better to do it using a server side language though so that more people will see it.
    Stephen J Chapman

    javascriptexample.net, Book Reviews, follow me on Twitter
    HTML Help, CSS Help, JavaScript Help, PHP/mySQL Help, blog
    <input name="html5" type="text" required pattern="^$">


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •