Solved

add date in function

Posted on 2014-02-12
5
229 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 33

Expert Comment

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

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 33

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

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
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/…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

839 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