Solved

add date in function

Posted on 2014-02-12
5
226 Views
Last Modified: 2014-02-12
hi, i wanna add a date (asp) in a function, how do i do that?

so every month, it will be updated automaticly (10/current month/current year)


thx


<%
function invitation (lng)
	
	
	select case lng
	case "fr"
		invitation = invitation & "<p>Welcome..... </p>"
		invitation = invitation & "<P><span class=title_2>answer before 10/here current month/here current year</span></P>"	

		
	
	case "nl"
		invitation = invitation & "<p>Welcome 2 </p>"
		invitation = invitation & "<P><span class=title_2>Vul je cijfers in voor 01/01/2014</span></P>"	

	end select
end function
%>
  

Open in new window

0
Comment
Question by:fedkris
  • 3
  • 2
5 Comments
 
LVL 32

Expert Comment

by:Big Monty
ID: 39853556
what dates do you want to add? 10 days to the current date?
0
 
LVL 32

Expert Comment

by:Big Monty
ID: 39853564
or do you just want the current month and year to display?

invitation = invitation & "<P><span class=title_2>answer before 10/<%=Month( Now )%>/<%=Year( Now )%></span></P>"
0
 

Author Comment

by:fedkris
ID: 39854641
but the code, is already between <%

function....

%>


it doesn't work... i tried that also, before...
0
 
LVL 32

Accepted Solution

by:
Big Monty earned 500 total points
ID: 39854657
you're right, my mistake. try this (assuming it's what you want, you never really clarified my question):

invitation = invitation & "<P><span class=title_2>answer before 10/" & Month( Now ) & "/" & Year( Now ) & "</span></P>"
0
 

Author Closing Comment

by:fedkris
ID: 39854684
thx!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I was asked about the differences between classic ASP and ASP.NET, so let me put them down here, for reference: Let's make the introductions... Classic ASP was launched by Microsoft in 1998 and dynamically generate web pages upon user interact…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.
This is a video describing the growing solar energy use in Utah. This is a topic that greatly interests me and so I decided to produce a video about it.

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now