def openWebPage(webPagePath):
 if (webPagePath.find('#') != (-1)):
  redirectionText = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">\n<html>\n<head>\n'
  redirectionText += ('<meta http-equiv="REFRESH" content="0;url=%s"></head>\n</HTML>\n' % webPagePath)
  webPagePath = archive.getDocumentationPath('redirect.html')
  archive.writeFileText(webPagePath, redirectionText)
 webPagePath = ('"%s"' % webPagePath)
 try:
  os.startfile(webPagePath)
  return
 except:
  pass
 webbrowserName = webbrowser.get().name
 if (webbrowserName == ''):
  print 'Skeinforge was not able to open the documentation file in a web browser.  To see the documentation, open the following file in a web browser:'
  print webPagePath
  return
 os.system(((webbrowserName + ' ') + webPagePath))

def openWebPage ( webPagePath ) : if ( webPagePath . find ( '#' ) != ( - 1 ) ) : redirectionText = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">\n<html>\n<head>\n' redirectionText += ( '<meta http-equiv="REFRESH" content="0;url=%s"></head>\n</HTML>\n' % webPagePath ) webPagePath = archive . getDocumentationPath ( 'redirect.html' ) archive . writeFileText ( webPagePath , redirectionText ) webPagePath = ( '"%s"' % webPagePath ) try : os . startfile ( webPagePath ) return except : pass webbrowserName = webbrowser . get ( ) . name if ( webbrowserName == '' ) : print 'Skeinforge was not able to open the documentation file in a web browser.  To see the documentation, open the following file in a web browser:' print webPagePath return os . system ( ( ( webbrowserName + ' ' ) + webPagePath ) )
open a web page in a browser .