Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Oct 2005
    Location
    Delhi
    Posts
    76
    Thanks
    0
    Thanked 0 Times in 0 Posts

    what is wrong in this code

    Code:
    var u_agent = navigator.userAgent;
    	if (u_agent.indexOf('Firefox') != -1) {
    		document.writeln("<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0\" width=\"32\" height=\"32\"><param name=\"movie\" value=\"glow_device2.swf\" /><param name=\"quality\" value=\"high\" /><embed src=\"glow_device2.swf\" quality=\"high\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\" type=\"application/x-shockwave-flash\" width=\"32\" height=\"32\"></embed></object>");
    	}
    	else
    	{
    		document.writeln("<OBJECT CLASSID=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" CODEBASE=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab\" ID=\"testmovie1\" width=\"32\" height=\"32\" style=\"margin-left:15px;position:absolute; top:434px; left:595px; z-index:1; cursor:hand;\" border=\"0\" id=\"obj2\" name=\"obj2\" title=\"Next:Plant new ideas\"><PARAM NAME=\"MOVIE\" VALUE=\"glow_device2.swf\"><PARAM NAME=\"QUALITY\" VALUE=\"high\"><PARAM NAME=\"SCALE\" VALUE=\"SHOWALL\"><EMBED	NAME=\"testmovie1\" SRC=\"glow_device2.swf\" WIDTH=\"32\" HEIGHT=\"32\" QUALITY=\"high\" SCALE=\"SHOWALL\" swLiveConnect=\"true\" PLUGINSPAGE=\"http://www.macromedia.com/go/flashplayer/\"></EMBED></OBJECT>");
    	}

  • #2
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    Nothing seems to be wrong with it but why are you trying to use browser detection to output flash?
    ||||If you are getting paid to do a job, don't ask for help on it!||||


  •  

    Posting Permissions

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