Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 24th, 2005, 12:40 PM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default format of this date

how can i change the format of this date:

01january06 to 01january2006 with this code below:

__________________________________________________ ____

<%

while not rs1.eof

new_string_date = ""
new_date = rs1("period1")
dateList = Split(new_date, ",")

For dCount = 0 To UBound(dateList)

'20JAN-01MAR

if len(dateList(dCount)) < 13 then

'aa = Left(dateList(dCount),5)
'bb = Right(dateList(dCount),5)
'left1 = right(year(now),2) & aa
'right2 = right(year(now),2) & bb

'response.write "left1 " &left1 & "<br>"
'response.write "right2 " &right2 & "<br>"

'first_year = Left(left1,2)
'first_year = ""
mon = Left(dateList(dCount),2)
first_date = Mid(dateList(dCount),3,2)

'second_year = Left(right2,2)
'second_year = ""
mon2 = Mid(dateList(dCount),6,2)
second_date = Mid(dateList(dCount),8,2)

'response.write "Month = " & mon & "<br>"
'response.write "First Date = " & first_date & "<br>"
'response.write "Month 2 = " & mon2 & "<br>"
'response.write "Second Date = " & second_date & "<br>"


new_string_date = first_date&setdate(mon)&Right(year(now)+1,2)&"-"&second_date&setdate(mon2)&Right(year(now)+1,2)&" "
else

first_year = Left(dateList(dCount),2)
mon = Mid(dateList(dCount),3,2)
first_date = Mid(dateList(dCount),5,2)

second_year = Mid(dateList(dCount),6,2)
mon2 = Mid(dateList(dCount),8,2)
second_date = Right(dateList(dCount),2)

'response.Write(Right(year(now)+1,2))
new_string_date = new_string_date &first_date&setdate(mon)&Right(year(now)+1,2)&"-"&second_date&setdate(mon2)&Right(year(now)+1,2)&" ,"
'response.write new_string_date & "<br/>"

end if

next
new_string_date = left(new_string_date,len(new_string_date)-1)
'response.write new_string_date


%>

__________________
_______________________
Ayrshire Minis - a Mini E-Community
http://www.ayrshireminis.com
http://www.crmpicco.co.uk
 
Old January 24th, 2005, 01:26 PM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default

function setdate(Fdate)
                        Select Case Fdate
                        Case "01"
                          validdate = "January"
                        Case "02"
                         validdate = "February"
                        Case "03"
                         validdate = "March"
                        Case "04"
                         validdate = "April"
                        Case "05"
                         validdate = "May"
                        Case "06"
                         validdate = "June"
                         Case "07"
                         validdate = "July"
                        Case "08"
                         validdate = "August"
                         Case "09"
                         validdate = "September"
                        Case "10"
                         validdate = "October"
                        Case "11"
                         validdate = "November"
                         Case "12"
                         validdate = "December"
                        end select
                        setdate = validdate
                        end function

i also have that...

 
Old January 24th, 2005, 06:02 PM
Friend of Wrox
Points: 6,664, Level: 34
Points: 6,664, Level: 34 Points: 6,664, Level: 34 Points: 6,664, Level: 34
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2004
Location: Sydney, NSW, Australia.
Posts: 1,870
Thanks: 12
Thanked 20 Times in 20 Posts
Send a message via AIM to mat41
Default

crmpicco

;;;how can i change the format of this date
What is your objective?
Change it to what format?

If I may, how did you end up with that kind of format? I would change my design/business rules to get a more friendly format to work with.

Wind is your friend
Matt
 
Old January 24th, 2005, 10:38 PM
Authorized User
 
Join Date: Dec 2004
Location: , , .
Posts: 31
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi crmpicco,

U actually have the format 01january06, just that u wanna change the 06 to 2006 instead?

You can use year(now) to get the year 2005 without the "2" in "Right(year(now)+1,2)"

Cheers.
 
Old January 25th, 2005, 05:07 AM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default

i can output the format:

01january06

how can i change it to:

01january2006

 
Old January 25th, 2005, 06:15 AM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default

new_string_date = left(new_string_date, len(new_string_date)-1)

is outputted as:

01April06

 
Old January 25th, 2005, 07:28 AM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default

new_string_date = left(new_string_date,len(new_string_date)-1)
response.write new_string_date

Output in IE:

01April06-30May06,01November06-16May06,02January06-31June06

Can i change YEAR from two digits to four digits? i.e. 06 -> 2006?

 
Old January 25th, 2005, 07:32 AM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default

new_string_date = left(new_string_date,len(new_string_date)-1)

also trying to put a space between the 01 and the April....

any ideas guys?

 
Old January 25th, 2005, 11:15 AM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default




<%

  function swapHash(qString)
             swapHash = replace (qString,"#",",")
    end function

    function replaceHash(qString)
         replaceHash = replace (qString,",","#")
    end function

    'response.write(session("dbase_name"))

    contract_id = trim(request.form("contract_id"))
    dep = trim(request.form("dep"))
    arr = trim(request.form("arr"))
    via = trim(request.form("via"))
    season = trim(request.form("season"))
    air_cds = replaceHash(trim(request("air_cds")))
    company_id = Session("company_id")

    if Instr(air_cds,"#") > 0 then
      air_cds = left(air_cds,2)
    end if
    'response.write "Departure = " & dep & "<br>"
    'response.write "Arrival = " & arr & "<br>"
    'response.write "Via = " & via & "<br>"
    'response.Write contract_id
    'response.write company_id

    function setdate(Fdate)
                        Select Case Fdate
                        Case "01"
                          validdate = "January"
                        Case "02"
                         validdate = "February"
                        Case "03"
                         validdate = "March"
                        Case "04"
                         validdate = "April"
                        Case "05"
                         validdate = "May"
                        Case "06"
                         validdate = "June"
                         Case "07"
                         validdate = "July"
                        Case "08"
                         validdate = "August"
                         Case "09"
                         validdate = "September"
                        Case "10"
                         validdate = "October"
                        Case "11"
                         validdate = "November"
                         Case "12"
                         validdate = "December"
                        end select
                        setdate = validdate
                        end function

%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Display Fare Search</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style>
.alignCenter
{
    text-align: center;
}

a.{text-decoration:none}

</style>
</head>

<body bgcolor="#F5F5F5">
<form name="form" method="post">
<table width="800" border="1" bordercolor="#aaaaaa" align="center" cellpadding="0" cellspacing="0">

  <tr>
     <td>
<Table width="800" border="0" align="center" cellpadding="0" cellspacing="1">
<%
    'response.write ("select * from net_fares where air_cd = '"& air_cds &"' and contract_id = '"& contract_id &"' and company_id = '"& company_id &"' and dep like '%"& dep &"%' and arr like '%"& arr &"%'")
%>
<tr bgcolor="#006699">
    <td colspan="28" align="left">
    <b>Fare Search Result for <%=dep%> to : <%=arr%></b>
    </td>
</tr>
<%
  'response.write("select * from net_fares where air_cd = '"& air_cds &"' and contract_id = '"& contract_id &"' and company_id = '"& company_id &"' and dep like '%"& dep &"%' and arr like '%"& arr &"%'")

    set rs1=con.Execute("select * from net_fares where air_cd = '"& air_cds &"' and contract_id = '"& contract_id &"' and company_id = '"& company_id &"' and dep like '%"& dep &"%' and arr like '%"& arr &"%'")
    if not rs1.eof then
%>
<%

while not rs1.eof

new_string_date = ""
new_date = rs1("period1")
dateList = Split(new_date, ",")

For dCount = 0 To UBound(dateList)

'20JAN-01MAR

if len(dateList(dCount)) < 13 then

'aa = Left(dateList(dCount),5)
'bb = Right(dateList(dCount),5)
'left1 = right(year(now),2) & aa
'right2 = right(year(now),2) & bb

'response.write "left1 " &left1 & "<br>"
'response.write "right2 " &right2 & "<br>"

'first_year = Left(left1,2)
'first_year = ""
mon = Left(dateList(dCount),2)
first_date = Mid(dateList(dCount),3,2)

'second_year = Left(right2,2)
'second_year = ""
mon2 = Mid(dateList(dCount),6,2)
second_date = Mid(dateList(dCount),8,2)

'response.write "Month = " & mon & "<br>"
'response.write "First Date = " & first_date & "<br>"
'response.write "Month 2 = " & mon2 & "<br>"
'response.write "Second Date = " & second_date & "<br>"


new_string_date = first_date&setdate(mon)&Right(year(now)+1,2)&"-"&second_date&setdate(mon2)&Right(year(now)+1,2)&" "
else

first_year = Left(dateList(dCount),2)
mon = Mid(dateList(dCount),3,2)
first_date = Mid(dateList(dCount),5,2)

second_year = Mid(dateList(dCount),6,2)
mon2 = Mid(dateList(dCount),8,2)
second_date = Right(dateList(dCount),2)

'response.Write(Right(year(now)+1,2))
new_string_date = new_string_date &first_date&setdate(mon)&Right(year(now)+1,2)&"-"&second_date&setdate(mon2)&Right(year(now)+1,2)&" ,"
'response.write new_string_date & "<br/>"

end if

next
new_string_date = left(new_string_date, len(new_string_date)-1)
'response.write new_string_date


%>
<%
    'departure = len(rs1("dep"))
    'arrival = len(rs1("arr"))
    season = len(rs1("season"))
%>
<tr bordercolor="#bbbbbb" bgcolor="#cccccc">
  <td colspan="8" align="left">
  <b>Season: <%=rs1("season")%></b></td>
</tr>
<tr bgcolor="#000000">
    <td colspan="6" bgcolor="#dddddd">
    <div align="left">

    <span class="style9"><b>PERIOD: <%=new_string_date%></b></span>
    </div>
    </td>
</tr>
<tr bgcolor="#dddddd">
    <td width="259" colspan="6" bgcolor="#dddddd">
    <div align="left">

    <span class="style9"><b>CABIN: <%=rs1("cabin")%></b></span>
    </div>
    </td>
</tr>

<%
    if request.form("arr") = "" then
%>

<tr bgcolor="#dddddd">
<td width="259" colspan="6" bgcolor="#dddddd">
    <div align="left">

    <span class="style9"><b>Arriving: <%=rs1("arr")%></b></span>
    </div>
    </td>
</tr>
<%
    else
    end if
%>
<tr bgcolor="#dddddd">
    <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 1</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td>
</tr>
  <%
  if rs1("class1") <> "" then
  %>
<tr bordercolor="#000000" bgcolor="#ececec">
    <td><div align="center"><a href="fare_edit2.asp?fare_id=<%=rs1("fare_id")%>&c ontract_id=<%=contract_id%>&company_id=<%=company_ id%>&air_cds=<%=air_cds%>&class1=<%=rs1("class1")% >&1fare1234=<%=rs1("1fare1234")%>&1fare567=<%=rs1( "1fare567")%>&fare1_adv_pur=<%=rs1("fare1_adv_pur" )%>"><%=rs1("fare_id")%></a></div></td>
    <td><div align="center"><%=rs1("class1")%></div></td>
    <td><div align="center"><%=rs1("1fare1234")%></div></td>
    <td><div align="center"><%=rs1("1fare567")%></div></td>
    <td><div align="center"><%=rs1("fare1_adv_pur")%></div></td>
</tr>
  <%
      else

    %>
<tr>
    <td></td>
</tr>
<%
    end if
%>
<%
      if rs1("class2") <> "" then
%>
<tr bgcolor="#CCCCCC">
    <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 2</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td></tr>
<tr bgcolor="#ECECEC">
    <td><div align="center"><a href="fare_edit2.asp?fareid=<%=rs1("fare_id")%>&cl ass2=<%=rs1("class2")%>&2fare1234=<%=rs1("2fare123 4")%>&2fare567=<%=rs1("2fare567")%>&fare2_adv_pur= <%=rs1("fare2_adv_pur")%>"><%=rs1("fare_id")%></a></div></td>
    <td><div align="center"><%=rs1("class2")%></div></td>
    <td><div align="center"><%=rs1("2fare1234")%></div></td>
    <td><div align="center"><%=rs1("2fare567")%></div></td>
    <td><div align="center"><%=rs1("fare2_adv_pur")%></div></td>
  </tr>
<%
      else
%>
<tr>
    <td></td>
</tr>
<%
    end if
%>
<%
      if rs1("class3") <> "" then
%>
<tr bordercolor="#CCCCCC" bgcolor="#CCCCCC">
       <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 3</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td></tr>
<tr bordercolor="#ececec" bgcolor="#ececec">
    <td><div align="center"><a href="fare_edit2.asp?fareid=<%=rs1("fare_id")%>&cl ass3=<%=rs1("class3")%>&3fare1234=<%=rs1("3fare123 4")%>&3fare567=<%=rs1("3fare567")%>&fare3_adv_pur= <%=rs1("fare3_adv_pur")%>"><%=rs1("fare_id")%></a></div></td>
    <td><div align="center"><%=rs1("class3")%></div></td>
    <td><div align="center"><%=rs1("3fare1234")%></div></td>
    <td><div align="center"><%=rs1("3fare567")%></div></td>
    <td><div align="center"><%=rs1("fare3_adv_pur")%></div></td>
</tr>
<%
      else
%>
<tr>
    <td></td>
</tr>
<%
    end if
%>
<%
      if rs1("class4") <> "" then
%>
<tr bgcolor="#CCCCCC">
    <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 4</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td></tr>
<tr bgcolor="#ECECEC">
    <td><div align="center"><a href="fare_edit2.asp?fareid=<%=rs1("fare_id")%>&cl ass4=<%=rs1("class4")%>&4fare1234=<%=rs1("4fare123 4")%>&4fare567=<%=rs1("4fare567")%>&fare4_adv_pur= <%=rs1("fare4_adv_pur")%>"><%=rs1("fare_id")%></a></div></td>
    <td><div align="center"><%=rs1("class4")%></div></td>
    <td><div align="center"><%=rs1("4fare1234")%></div></td>
    <td><div align="center"><%=rs1("4fare567")%></div></td>
    <td><div align="center"><%=rs1("fare4_adv_pur")%></div></td>
  </tr>
<%
      else
%>
<tr>
    <td></td>
</tr>
<%
    end if
%>
<%
      if rs1("class5") <> "" then
%>
<tr bordercolor="#CCCCCC" bgcolor="#CCCCCC">
    <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 5</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td></tr>
<tr bordercolor="#ececec" bgcolor="#ececec">
    <td><div align="center"><a href="fare_edit2.asp?fareid=<%=rs1("fare_id")%>&cl ass5=<%=rs1("class5")%>&5fare1234=<%=rs1("5fare123 4")%>&5fare567=<%=rs1("5fare567")%>&fare5_adv_pur= <%=rs1("fare5_adv_pur")%>"><%=rs1("fare_id")%></a></div></td>
    <td><div align="center"><%=rs1("class5")%></div></td>
    <td><div align="center"><%=rs1("5fare1234")%></div></td>
    <td><div align="center"><%=rs1("5fare567")%></div></td>
    <td><div align="center"><%=rs1("fare5_adv_pur")%></div></td>
</tr>
<%
      else
%>
<tr>
    <td></td>
</tr>
<%
    end if
%>
<%
      if rs1("class6") <> "" then
%>
<tr>
    <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 6</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td></tr>
<tr>
    <td><div align="center"><a href="fare_edit2.asp?fareid=<%=rs1("fare_id")%>&cl ass6=<%=rs1("class6")%>&6fare1234=<%=rs1("6fare123 4")%>&6fare567=<%=rs1("6fare567")%>&fare6_adv_pur= <%=rs1("fare6_adv_pur")%>"><%=rs1("fare_id")%></a></div></td>
    <td><div align="center"><%=rs1("class6")%></div></td>
    <td><div align="center"><%=rs1("6fare1234")%></div></td>
    <td><div align="center"><%=rs1("6fare567")%></div></td>
    <td><div align="center"><%=rs1("fare6_adv_pur")%></div></td>
</tr>
<%
      else
%>
<tr>
      <td></td>
</tr>
<%
      end if
%>
<%
      if rs1("class7") <> "" then
%>
<tr bordercolor="#CCCCCC" bgcolor="#CCCCCC">
    <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 7</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td><tr bordercolor="#ececec" bgcolor="#ececec">
</tr>
<tr>
    <td><div align="center"><a href="fare_edit2.asp?fareid=<%=rs1("fare_id")%>&cl ass7=<%=rs1("class7")%>&7fare1234=<%=rs1("7fare123 4")%>&7fare567=<%=rs1("7fare567")%>&fare7_adv_pur= <%=rs1("fare7_adv_pur")%>"><%=rs1("fare_id")%></a></div></td>
    <td><div align="center"><%=rs1("class7")%></div></td>
    <td><div align="center"><%=rs1("7fare1234")%></div></td>
    <td><div align="center"><%=rs1("7fare567")%></div></td>
    <td><div align="center"><%=rs1("fare7_adv_pur")%></div></td>
</tr>
<%
      else
%>
<tr>
      <td></td>
</tr>
<%
      end if
%>
<%
      if rs1("class8") <> "" then
%>
<tr>
    <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 8</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td></tr>
<tr>
    <td><div align="center"><a href="fare_edit2.asp?fareid=<%=rs1("fare_id")%>&cl ass8=<%=rs1("class8")%>&8fare1234=<%=rs1("8fare123 4")%>&8fare567=<%=rs1("8fare567")%>&fare8_adv_pur= <%=rs1("fare8_adv_pur")%>"><%=rs1("fare_id")%></a></div></td>
    <td><div align="center"><%=rs1("class8")%></div></td>
    <td><div align="center"><%=rs1("8fare1234")%></div></td>
    <td><div align="center"><%=rs1("8fare567")%></div></td>
    <td><div align="center"><%=rs1("fare8_adv_pur")%></div></td>
</tr>
<%
   else
%>
<tr>
  <td></td>
</tr>
<%
    end if
%>
<%
      if rs1("class9") <> "" then
%>
<tr bordercolor="#CCCCCC" bgcolor="#CCCCCC">
    <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 9</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td></tr>

<tr bordercolor="#ececec" bgcolor="#ececec">
    <td><div align="center"><a href="fare_edit2.asp?fareid=<%=rs1("fare_id")%>&cl ass9=<%=rs1("class9")%>&9fare1234=<%=rs1("9fare123 4")%>&9fare567=<%=rs1("9fare567")%>&fare9_adv_pur= <%=rs1("fare9_adv_pur")%>"><%=rs1("fare_id")%></a></div></td>
    <td><div align="center"><%=rs1("class9")%></div></td>
    <td><div align="center"><%=rs1("9fare1234")%></div></td>
    <td><div align="center"><%=rs1("9fare567")%></div></td>
    <td><div align="center"><%=rs1("fare9_adv_pur")%></div></td>
</tr>
<%
   else
%>
<tr>
  <td></td>
</tr>
<%
    end if
%>
<%
      if rs1("class10") <> "" then
%>
<tr>
    <td><div align="center"><b><span class="style7">Fare ID</span></b></div></td>
    <td><div align="center"><b><span class="style7">Class 10</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Midweek</span></b></div></td>
    <td><div align="center"><b><span class="style7">Fare Weekend</span></b></div></td>
    <td><div align="center"><b><span class="style7">Advance Purchase</span></b></div></td></tr>
<tr>
    <td><div align="center"><a href="fare_edit2.asp?fareid=<%=rs1("fare_id")%>&cl ass10=<%=rs1("class10")%>&10fare1234=<%=rs1("10far e1234")%>&10fare567=<%=rs1("10fare567")%>&fare10_a dv_pur=<%=rs1("fare10_adv_pur")%>"><%=rs1("fare_id ")%></a></div></td>
    <td><div align="center"><%=rs1("class10")%></div></td>
    <td><div align="center"><%=rs1("10fare1234")%></div></td>
    <td><div align="center"><%=rs1("10fare567")%></div></td>
    <td><div align="center"><%=rs1("fare10_adv_pur")%></div></td>
</tr>
  <%
   else
  %>
  <tr>
  <td></td>
  </tr>
<%
    end if
%>

<%
    rs1.movenext
    wend %>

    <%
    else
%>
<tr>
    <td align="center" colspan="8">
    <b>Sorry, <br>there are no results for your criteria<br></b></td>
</tr>
</table>
<% end if %>
    </td>

  </tr>

</table>
</form>

</body>
</html>


 
Old January 25th, 2005, 11:16 AM
Friend of Wrox
Points: 8,019, Level: 38
Points: 8,019, Level: 38 Points: 8,019, Level: 38 Points: 8,019, Level: 38
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2005
Location: Mauchline, East Ayrshire, Scotland
Posts: 1,525
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to crmpicco Send a message via AIM to crmpicco Send a message via MSN to crmpicco Send a message via Yahoo to crmpicco
Default

how can i change '06' (the year) to '2006'????





Similar Threads
Thread Thread Starter Forum Replies Last Post
date format differs, need to force format somehow patricolsson ASP.NET 2.0 Basics 1 December 3rd, 2009 12:53 AM
Convert British format date to American format? fyr PHP How-To 0 December 19th, 2007 03:17 PM
Help with date format gregalb SQL Server 2000 1 February 13th, 2007 10:15 AM
How to give Date format while entering date Subuana Beginning VB 6 4 March 17th, 2006 07:25 AM
date format differs, need to force format somehow patricolsson HTML Code Clinic 2 January 12th, 2006 05:55 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.