SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Addict
    Join Date
    Aug 2007
    Posts
    318
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Post Syntax Problem (hyperlinked image)

    When i write
    Code:
    <script language=javascript>document.write("<a href='http://del.icio.us/post?url="+document.location.href+"&title="+document.title+"' ><img src="/includes/addons/social/images/delicious.png" alt="ADD TO DEL.ICIO.US"></a>")</script>
    i donot get any display of hyperlinked image. What to do

  2. #2
    SitePoint Zealot
    Join Date
    Jun 2007
    Posts
    150
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The image src attribute is encapsulated by double quotes. The document.write method also uses double quotes.

    Either use single quotes, or escape the double quotes: \"


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
  •