# Hey I need help detecting different browsers

**URL:** <https://forum.kirupa.com/t/hey-i-need-help-detecting-different-browsers/58856>\
**Category:** programming\
**Created:** [July 26, 2004, 6:15pm UTC](https://forum.kirupa.com/t/hey-i-need-help-detecting-different-browsers/58856 "2004-07-26T18:15:57Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![nuscott56](https://avatars.discourse-cdn.com/v4/letter/n/bbce88/32.png) [@nuscott56](https://forum.kirupa.com/u/nuscott56)\
**Post date:** [July 26, 2004, 6:15pm UTC](https://forum.kirupa.com/t/hey-i-need-help-detecting-different-browsers/58856/1 "2004-07-26T18:15:57Z")

</div>

hey I’m creating a flash site-which is now complete-that is going to run through dreamweaver, which has both flash and hml versions of the site, I am using dreamweaver mx 2004 and I need to figure out the onLoad()…if, then statements nessesary to test for a specific browser-either mac safari or win netscape 5.5+ so I can utilize the onLoad(), resizeTo, moveTo, functions of the javascript to open my cromless windows centered in the middle of the page. I have the scripts completed for the cromless windows that open perfectly when assigned to a specific engine, either safari or netscape, but one script will default and fail if it is opened in the other browser, I know that netscape doesn’t use the a\>herf coding of html as well as safari, so I need to have seperate codes employed when the onLoad() detects for which browser is currently being used on the machine. so a basic on run array would follow like this:  
user accesses main page  
HTML and Flash option buttons  
//well forget about the HTML since everyone can read it  
Flash Button is Pressed  
onLoad(), local machine detects browser  
if Safari-then load mac safe script  
//this pops a centered-chromless window  
runs flash document  
else if Netscape, then load win/netscape friendly script  
//this pops the netscape chromless centered window  
runs flash document  
any ideas or scripts would be a lifesaver,  
also if anyone can do this with less coding…i.e, the javascript that runs seamlesly between platforms for the chromeless popup, that would be more than appriciated, thanks  
Scott
