Home Relocation Services
 
 

We at Stevens Movers knows that understanding your needs, provide solutions and being honest is the key to a successful move.

 

Move Size

Estimated Moving Date

getting the current date - Dreamweaver AppDev

hi guys I?ve created 3 selection boxes on a form: 1 for the date, with values 1 - 31. 1 for the month, with values 1- 12 1 for the year with values 2005 - 2008 i would like the selection boxes to display the current date. how do i do that ?...

  1. #1

    Default getting the current date

    hi guys I?ve created 3 selection boxes on a form:
    1 for the date, with values 1 - 31.
    1 for the month, with values 1- 12
    1 for the year with values 2005 - 2008

    i would like the selection boxes to display the current date.

    how do i do that ?


    ranip Guest

  2. #2

    Default Re: getting the current date

    This may help out...

    [url]http://www.merlyn.demon.co.uk/vb-dates.htm[/url]

    HTH,
    Drew

    "ranip" <webforumsusermacromedia.com> wrote in message
    news:d4j6qv$62p$1forums.macromedia.com...
    > hi guys I?ve created 3 selection boxes on a form:
    > 1 for the date, with values 1 - 31.
    > 1 for the month, with values 1- 12
    > 1 for the year with values 2005 - 2008
    >
    > i would like the selection boxes to display the current date.
    >
    > how do i do that ?
    >
    >

    Drew Guest

  3. #3

    Default Re: getting the current date

    it didn't really.
    i am new to programming and i don't really know how to incorporate the example
    to the code i wrote
    that is the code and as you can see it is manually selected.
    how do i automate it and programmatically select the month ?



    <select class="txtSelect" name="SelMonth" size="1" tabindex="2">
    <option VALUE=01>Jan</option>
    <option VALUE=02>Feb</option>
    <option VALUE=03>Mar</option>
    <option VALUE=04>Apr</option>
    <option VALUE=05 SELECTED >May</option>
    <option VALUE=06>Jun</option>
    <option VALUE=07>Jul</option>
    <option VALUE=08>Aug</option>
    <option VALUE=09>Sep</option>
    <option VALUE=10>Oct</option>
    <option VALUE=11>Nov</option>
    <option VALUE=12>Dec</option>
    </SELECT>

    ranip Guest

  4. #4

    Default Re: getting the current date

    it didn't really.
    i am new to programming and i don't really know how to incorporate the example
    to the code i wrote
    that is the code and as you can see it is manually selected.
    how do i automate it and programmatically select the month ?



    <select class="txtSelect" name="SelMonth" size="1" tabindex="2">
    <option VALUE=01>Jan</option>
    <option VALUE=02>Feb</option>
    <option VALUE=03>Mar</option>
    <option VALUE=04>Apr</option>
    <option VALUE=05 SELECTED >May</option>
    <option VALUE=06>Jun</option>
    <option VALUE=07>Jul</option>
    <option VALUE=08>Aug</option>
    <option VALUE=09>Sep</option>
    <option VALUE=10>Oct</option>
    <option VALUE=11>Nov</option>
    <option VALUE=12>Dec</option>
    </SELECT>

    ranip Guest

  5. #5

    Default Re: getting the current date

    Are you using VBScript? If so, here is the answer...

    Month(Date) returns the Month
    Day(Date) returns the Day
    Year(Date) returns the Year

    Copy the code below into a new ASP page,

    <%
    Response.Write("Hello, today's date is, " & Date & "<br><br>")
    Response.Write("The Month is " & Month(Date) & "<br>")
    Response.Write("The Day is " & Day(Date) & "<br>")
    Response.Write("The Year is " & Year(Date) & "<br>")
    %>

    That will return the date, and then the parts of the date...

    HTH,
    Drew

    "ranip" <webforumsusermacromedia.com> wrote in message
    news:d4jbed$cdf$1forums.macromedia.com...
    > it didn't really.
    > i am new to programming and i don't really know how to incorporate the
    > example
    > to the code i wrote
    > that is the code and as you can see it is manually selected.
    > how do i automate it and programmatically select the month ?
    >
    >
    >
    > <select class="txtSelect" name="SelMonth" size="1" tabindex="2">
    > <option VALUE=01>Jan</option>
    > <option VALUE=02>Feb</option>
    > <option VALUE=03>Mar</option>
    > <option VALUE=04>Apr</option>
    > <option VALUE=05 SELECTED >May</option>
    > <option VALUE=06>Jun</option>
    > <option VALUE=07>Jul</option>
    > <option VALUE=08>Aug</option>
    > <option VALUE=09>Sep</option>
    > <option VALUE=10>Oct</option>
    > <option VALUE=11>Nov</option>
    > <option VALUE=12>Dec</option>
    > </SELECT>
    >

    Drew Guest

  6. #6

    Default Re: getting the current date

    i am using html and java script

    here is the code for the entire page:


    <html><head>
    <title>A Us Leading Van Line , Offers: Residential, Commercial Relocation
    Services, Storage Facilities.</title>
    <meta NAME="description" CONTENT="Stevens Movers is a US based leading van
    lines offers ,relocation services, moving companies, Van Lines Services, Moving
    all over the USA.">
    <meta NAME="keywords" CONTENT=" movers, moving, relocation, Denver storage,
    Denver moving services, Denver relocation services, Denver storage services,
    Denver Van Lines, Colorado moving services, Colorado relocation services,
    Colorado storage services, Colorado Van Lines, Colorado Moving Company,
    Colorado Movers, Colorado Moving, Movers in denver, Movers in colorado, Moving
    in Colorado, Movers in Colorado, Movers in denver, Movers in colorado, denver
    moving company, denver moving companies">
    <meta NAME="REVISED" CONTENT="2004/02/12">
    <meta NAME="robots" CONTENT="all">
    <!-- Fireworks MX Dreamweaver MX target. Created Thu Jul 10 16:25:51 GMT-0600
    (Mountain Daylight Time) 2003-->
    <script language="JavaScript">
    <!--
    function MM_preloadImages() { //v3.0
    var d=doent; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length;
    i++)
    if (a.indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a;}}
    }

    function MM_swapImgRestore() { //v3.0
    var i,x,a=doent.MM_sr; for(i=0;a&&i<a.length&&(x=a)&&x.oSrc;i++)
    x.src=x.oSrc;
    }

    function MM_findObj(n, d) { //v4.01
    var p,i,x; if(!d) d=doent;
    if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].doent; n=n.substring(0,p);}
    if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++)
    x=d.forms[n];
    for(i=0;!x&&d.layers&&i<d.layers.length;i++)
    x=MM_findObj(n,d.layers.doent);
    if(!x && d.getElementById) x=d.getElementById(n); return x;
    }

    function MM_swapImage() { //v3.0
    var i,j=0,x,a=MM_swapImage.arguments; doent.MM_sr=new Array;
    for(i=0;i<(a.length-2);i+=3)
    if ((x=MM_findObj(a))!=null){doent.MM_sr[j++]=x; if(!x.oSrc)
    x.oSrc=x.src; x.src=a[i+2];}
    }
    //-->
    </script>

    <meta http-equiv="Content-Type" content="text/html; cht=iso-8859-1">



    <style type="text/css">
    <!--
    .style1 { color: #00FF99;
    font-size: 12px;
    }
    .style2 {color: #009966}
    .style8 {color: #000000}
    -->
    </style>
    </head>
    <body bgcolor="#ffffff" leftmargin="0" topmargin="0" marginwidth="0"
    marginheight="0"
    onLoad="MM_preloadImages('images/getin.gif','images/truck_logo.jpg','images/home
    _g.jpg','images/Horse_logo.jpg','images/getin1.gif')"><!-- DHTML Menu Builder
    Loader Code START -->
    <div id=DMBRI style="position:absolute;">
    <img src="menus/Top/dmb_i.gif" name=DMBImgFiles width="1" height="1"
    border="0" alt="">
    <img src="menus/Top/dmb_m.gif" name=DMBJSCode width="1" height="1" border="0"
    alt="">
    </div>
    <script language="JavaScript" type="text/javascript">
    var rimPath=null;var rjsPath=null;var rPath2Root=null;function
    InitRelCode(){var iImg;var jImg;var
    tObj;if(!doent.layers){iImg=doent.images['DMBImgFiles'];jImg=doent.imag
    es['DMBJSCode'];tObj=jImg;}else{tObj=doent.layers['DMBRI'];if(tObj){iImg=tObj
    ..doent.images['DMBImgFiles'];jImg=tObj.doent.images['DMBJSCode'];}}if(!tOb
    j){window.setTimeout("InitRelCode()",700);return
    false;}rimPath=_gp(iImg.src);rjsPath=_gp(jImg.src) ;rPath2Root=rjsPath+"../../";r
    eturn true;}function _purl(u){return
    xrep(xrep(u,"%%REP%%",rPath2Root),"\\","/");}function
    _fip(img){if(img.src.indexOf("%%REL%%")!=-1)
    img.src=rimPath+img.src.split("%%REL%%")[1];return img.src;}function
    _gp(p){return p.substr(0,p.lastIndexOf("/")+1);}function xrep(s,f,n){if(s)
    s=s.split(f).join(n);return s;}InitRelCode();
    </script>
    <script language="JavaScript" type="text/javascript">
    function LoadMenus() {if(!rjsPath){window.setTimeout("LoadMenus()", 10);return
    false;}var navVer = navigator.appVersion;
    if(navVer.substr(0,3) >= 4)
    if((navigator.appName=="Netscape") && (pInt(navigator.appVersion)==4)) {
    doent.write('<' + 'script language="JavaScript" type="text/javascript"
    src="' + rjsPath + 'nsTop.js"><\/script\>');
    } else {
    doent.write('<' + 'script language="JavaScript" type="text/javascript"
    src="' + rjsPath + 'ieTop.js"><\/script\>');
    }return true;}LoadMenus();</script>
    <!-- DHTML Menu Builder Loader Code END -->
    <div id=DMBRI style="position:absolute;"> <img src="menus/images/dmb_i.gif"
    name=DMBImgFiles width="1" height="1" border="0" alt=""> <img
    src="menus/dmb_m.gif" name=DMBJSCode width="1" height="1" border="0" alt="">
    </div>
    <script language="JavaScript" type="text/javascript">
    var rimPath=null;var rjsPath=null;var rPath2Root=null;function
    InitRelCode(){var iImg;var jImg;var
    tObj;if(!doent.layers){iImg=doent.images['DMBImgFiles'];jImg=doent.imag
    es['DMBJSCode'];tObj=jImg;}else{tObj=doent.layers['DMBRI'];if(tObj){iImg=tObj
    ..doent.images['DMBImgFiles'];jImg=tObj.doent.images['DMBJSCode'];}}if(!tOb
    j){window.setTimeout("InitRelCode()",700);return
    false;}rimPath=_gp(iImg.src);rjsPath=_gp(jImg.src) ;rPath2Root=rjsPath+"../";retu
    rn true;}function _purl(u){return
    xrep(xrep(u,"%%REP%%",rPath2Root),"\\","/");}function
    _fip(img){if(img.src.indexOf("%%REL%%")!=-1)
    img.src=rimPath+img.src.split("%%REL%%")[1];return img.src;}function
    _gp(p){return p.substr(0,p.lastIndexOf("/")+1);}function xrep(s,f,n){if(s)
    s=s.split(f).join(n);return s;}InitRelCode();
    </script>

    <div id=DMBRI style="position:absolute;">


    <table width="843" border="0" cellpadding="0" cellspacing="0">
    <tr>
    <td width="101" height="27" rowspan="3" align="right">
    <td width="250" rowspan="3" align="right"><img
    src="images/StevensLogo.gif" width="250" height="188">
    <td width="113" rowspan="3""" align="right" bgcolor=""#f6f6f4>
    <td width="379" "342" height="13" align="left" valign="top">&nbsp;</td>
    <tr>
    <td "342" height="7" align="left" valign="top"><a href="welcome.html"
    onMouseOut="MM_swapImgRestore()"
    onMouseOver="MM_swapImage('logo_truck','','images/Horse_logo.jpg',1);"><img
    name="logo_truck" src="images/logo_truck.jpg" width="342" height="107"
    border="0" alt="Home Relocation Services"></a></td>
    <tr>
    <td "342" height="7" align="left" valign="top">&nbsp;</td>
    </table>
    <tr>

    </table>
    </tr>
    <table width="843" border="0" cellspacing="0" cellpadding="0">
    <tr>
    <td width="101" height="32" align="center" valign="middle"><div
    align="left"></div></td>
    <td width="350" "352" height="32" align="center" valign="middle"><a
    href="welcome.html" onMouseOut="MM_swapImgRestore()"
    onMouseOver="MM_swapImage('getin','','images/getin1.gif',1);"><img name="getin"
    src="images/getin.gif" width="350" height="62" border="0" ></a></td>
    <td width="11" height="32" align="center" valign="middle">&nbsp;</td>
    <td width="381" align="center" valign="middle" bgcolor="FFFFFF"><p>We at
    Stevens Movers knows that understanding your needs, provide solutions and being
    honest is the key to a successful move. </p></td>
    <tr>
    <td align="center" valign="middle" bgcolor="FFFFFF">&nbsp;</td>
    <td height="16" align="center" valign="middle" bgcolor="FFFFFF"><table
    cellpadding=0 cellspacing=0 width=334 bgcolor=#FFFFFF>
    <tr bgcolor="FFFFFF">
    <td height="29" colspan="2" align="center" valign="middle"><img
    src="images/free_quR.gif" width="140" height="21">
    </tr>
    <tr bgcolor="DCDBC9">
    <td height="23" colspan="2" align="left" valign="middle"><p
    class="style8">Move Size </p>
    </tr>
    <tr bgcolor="DCDBC9">
    <td height="24" colspan="2" align="left" valign="middle"><select
    name="Move Size" class=textS size="1" tabindex="1">
    <option value="" selected >Select weight</option>
    <option value="0_Partial Home 500-1000 lbs">Partial Home
    500-1000 lbs</option>
    <option value="0_Studio 1500 lbs">Studio 1500 lbs</option>
    <option value="1_1 BR Small 3000 lbs">1 Small Bedroom</option>
    <option value="1_1 BR Large 4000 lbs">1 Large Bedroom 4000
    lbs</option>
    <option value="1_2 BR Small 4500 lbs">2 Small Bedrooms 4500
    lbs</option>
    <option value="1_2 BR Large 6500 lbs">2 Large Bedrooms 6500
    lbs</option>
    <option value="1_3 BR Small 8000 lbs">3 Small Bedrooms 8000
    lbs</option>
    <option value="1_3 BR Large 9000 lbs">3 Large Bedrooms 9000
    lbs</option>
    <option value="1_4 BR Small 10000 lbs">4 Small Bedrooms 10000
    lbs</option>
    <option value="1_4 BR Large 12000 lbs">4 Large Bedrooms 12000
    lbs</option>
    <option value="1_Over 12000 lbs">Over 12000 lbs</option>
    </select> </tr>
    <tr bgcolor="DCDBC9">
    <td height="22" colspan="2" align="Left" valign="middle"><span
    class="style8">Estimated Moving Date </span></td>
    </tr>
    <tr bgcolor="DCDBC9">
    <td height="34" colspan="2" align="Left" valign="middle">
    <div align="left">
    <!--Select Move Month -->
    <select class="txtSelect" name="SelMonth" size="1" tabindex="2">
    <option VALUE=01>Jan</option>
    <option VALUE=02>Feb</option>
    <option VALUE=03>Mar</option>
    <option VALUE=04>Apr</option>
    <option VALUE=05 SELECTED >May</option>
    <option VALUE=06>Jun</option>
    <option VALUE=07>Jul</option>
    <option VALUE=08>Aug</option>
    <option VALUE=09>Sep</option>
    <option VALUE=10>Oct</option>
    <option VALUE=11>Nov</option>
    <option VALUE=12>Dec</option>
    </SELECT>
    <!--End Month Select -->

    <!--Start day Select -->
    <select class="txtSelect" name="MoveDay" size="1" tabIndex=3>
    <option VALUE=01>1</option>

    ranip Guest

Similar Threads

  1. Current Date
    By jhcaron in forum Macromedia Dynamic HTML
    Replies: 3
    Last Post: January 8th, 09:28 PM
  2. inserting system or current date
    By akcreative in forum Coldfusion Database Access
    Replies: 4
    Last Post: September 1st, 10:24 PM
  3. ASP.NET Current Date in TextBox
    By acidrain9 in forum Adobe Dreamweaver & Contribute
    Replies: 2
    Last Post: February 17th, 04:48 PM
  4. current date - 7 dayz?
    By mr_burns in forum PHP Development
    Replies: 3
    Last Post: October 8th, 08:10 AM
  5. Current Date & Time
    By R3iam webforumsuser@macromedia.com in forum Macromedia Dreamweaver
    Replies: 4
    Last Post: July 19th, 12:08 AM

Bookmarks

Posting Permissions

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