Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. window.parent not working in firefox

window.parent not working in firefox

Scheduled Pinned Locked Moved ASP.NET
5 Posts 5 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Member 3981366
    wrote on last edited by
    #1

    I am using following function to print iframe . but it doent work with Firefox and works in IE..why dont work in mozilla fireox 3.0..pls gv alternate.. function Print() { var iframeE3 =parent.document.frames['pageframe1'].document.frames[2]; var iframeE4 =iframeE3.document.frames.length; if (iframeE4>0) { iframeE3.focus(); iframeE3.print(); } else { alert('no selection'); } }

    A C N 3 Replies Last reply
    0
    • M Member 3981366

      I am using following function to print iframe . but it doent work with Firefox and works in IE..why dont work in mozilla fireox 3.0..pls gv alternate.. function Print() { var iframeE3 =parent.document.frames['pageframe1'].document.frames[2]; var iframeE4 =iframeE3.document.frames.length; if (iframeE4>0) { iframeE3.focus(); iframeE3.print(); } else { alert('no selection'); } }

      A Offline
      A Offline
      Anshumas
      wrote on last edited by
      #2

      try directly with help of document.getElementById('iframe12') etc..

      Anshuman Singh

      A 1 Reply Last reply
      0
      • A Anshumas

        try directly with help of document.getElementById('iframe12') etc..

        Anshuman Singh

        A Offline
        A Offline
        Abhijit Jana
        wrote on last edited by
        #3

        Anshumas wrote:

        try directly with help of document.getElementById('iframe12') etc..

        What does it mean ? Did you read the complete requirment ?

        cheers, Abhijit CodeProject MVP


        My Blog : Abhijit's World of .Net

        1 Reply Last reply
        0
        • M Member 3981366

          I am using following function to print iframe . but it doent work with Firefox and works in IE..why dont work in mozilla fireox 3.0..pls gv alternate.. function Print() { var iframeE3 =parent.document.frames['pageframe1'].document.frames[2]; var iframeE4 =iframeE3.document.frames.length; if (iframeE4>0) { iframeE3.focus(); iframeE3.print(); } else { alert('no selection'); } }

          C Offline
          C Offline
          Christian Graus
          wrote on last edited by
          #4

          This code is really messy, I assume it blows up in FF, given that you never check if your assumptions are correct ( that there are 3 frames, that iframeE3 is not null, etc )

          Christian Graus Driven to the arms of OSX by Vista.

          1 Reply Last reply
          0
          • M Member 3981366

            I am using following function to print iframe . but it doent work with Firefox and works in IE..why dont work in mozilla fireox 3.0..pls gv alternate.. function Print() { var iframeE3 =parent.document.frames['pageframe1'].document.frames[2]; var iframeE4 =iframeE3.document.frames.length; if (iframeE4>0) { iframeE3.focus(); iframeE3.print(); } else { alert('no selection'); } }

            N Offline
            N Offline
            N a v a n e e t h
            wrote on last edited by
            #5

            Adding to what others said, Install FireBug and check what's wrong with the script. Or there is an Error Console available with firefox which will show the errors in the current page. Try that.

            Navaneeth How to use google | Ask smart questions

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups