Popular Topics

  • Portable Applications
  • Radar Detectors
  • Peak Oil Theory
  • Planet Orbits
  • GPS

     

  • A2DVoices.com

    HTML Webpage Authoring Tricks
    6 August 2005 (Updated 12/17/07)

     

    How To Redirect a Web Site to Different URL
    Javascript allows a web author to redirect a webpage URL to a new URL. For instance, if you would like all visitors to the website http://www.easygardeningwithmarie.com to be redirected to http://www.a2dvoices.com/gardening, the web author adds the following code anywhere inside the header (HEAD) section of the redirected HTML file:

      <SCRIPT LANGUAGE=JAVASCRIPT TYPE="TEXT/JAVASCRIPT">
      <!-- Hide script from old browsers<br>
      if (location.hostname == "www.easygardeningwithmarie.com")
      {
      location.href = "http://www.a2dvoices.com/gardening/";
      }
      //-- Stop hiding script -->
      </SCRIPT>

     

    How To Embed Audio In a Webpage
    Audio can be added to any webpage. The audio playback can be initiated manually or automatically. An automatic webpage greeting can be inserted using the <embed> function:

      <EMBED SRC="http://www.a2dvoices.com/gardening/audio/GardeningVignette_0004.mp3" WIDTH=1 HEIGHT=1 HIDDEN="true" AUTOSTART="true" LOOP="false">
    A manual audio slider ( )can be added on your page:
      <EMBED="http://www.a2dvoices.com/audio/BrettHospital100305demo.mp3" WIDTH=100 HEIGHT=20 HIDDEN="false" AUTOSTART="false" LOOP="false"></EMBED>
    A manual button webpage link ( ) can be created using the <button> function with javascript:
      <script>
      function PlayAudio(audioobj)
      {
      var audio=document.getElementById(audioobj);
      audio.Play();
      }
      </script>
      <embed src="http://www.a2dvoices.com/audio/BrettHospital100305demo.mp3"
      autostart=false width=0 height=0 id="AUDIO_001" enablejavascript="true"> <BUTTON onClick="PlayAudio('AUDIO_001')">Play</BUTTON>

     

    How To Open A Link In A New Browser Window
    HTML allows the web author to determine whether a webpage link opens in the existing window or a new window. For instance, the following code will reopen this webpage in the current window:

      <A href="http://www.a2dvoices.com/realitycheck/help/HTMLAuthoringTips.html">Opens in Current Window</a>
    The following code will open this webpage again in a new window:
      <A href="http://www.a2dvoices.com/realitycheck/help/HTMLAuthoringTips.html" target="_blank">Opens in New Window</a>

     

    How To Send An Email From A Web Page
    Sending a email from your web page using the mailto function:

      <A HREF="mailto:dubuque@a2dvoices.com">dubuque@a2dvoices.com?subject=HOW TO SEND EMAIL FROM A WEBPAGE</A>

    HOME

    A2DVOICES.COM

    TOP OF PAGE

      Copyright © 2000-2008 A2DVoices.Com® - All rights reserved