Archive

Posts Tagged ‘date’

How to Know The Number of Days from Monday until Today of This Week in PHP

December 13th, 2009 Masino Sinaga No comments

There was a question asked to myself how to know the number of days that calculated from Monday until today of this week by using PHP script. Well, actually, we can make a function by checking based on the day name of today, then return the value based on its day name to the function. So here is the solution I made. Read more…

  • Share/Bookmark

How to Hide Date Based on Specified Page’s Title in iNove Theme of WordPress

December 6th, 2009 Masino Sinaga No comments

Have you ever wanted to hide the created date that displayed in a specified page based on its title page on your WordPress blog? For example, you used a page with permalink forum and its title page is Forum whereas the content of its page derived from the certain plugin that adding the Discussion Forum on your WordPress blog. Well, here is the solution how you can hide that date on the page. Read more…

  • Share/Bookmark
Categories: WordPress Tags: , , , , , , ,

How to Calculate Difference Between Two Dates Using VB6

September 1st, 2009 Masino Sinaga No comments

This following code will show you how to calculate difference between two dates by using Visual Basic 6. The calculation result will give you an output that contains of the difference between those two dates in format: Days, Hours:Minutes:Seconds. The both dates must be in complete format. For example: the first date is March 1, 2002 17:18:00, and the second date is September 1, 2002 09:42:30. After being calculated, then the output will give you the result as follow: 183 day(s), 16:24:30. It means: The difference between those two dates is: 183 days, 16 hours, 24 minutes, and 30 seconds. Read more…

  • Share/Bookmark

How to Convert 10 Digits Numeral to The Date Value?

August 29th, 2009 Masino Sinaga No comments

I have hundreds of records that need to be imported from one table and database (let’s say that this is the first database) to another table in different database (and the last one is the second database). Unfortunately, one of the columns in the table in first database has the Date value in 10 digits numeral format. For example: 1206980969. Actually, this value equals with March 31, 2008 16:29:29 on UTC. Then, how do I convert that 10 digits numeral to the Data value since the column in the second database is a Date field type? And how do I convert again that date according to my local time? Read more…

  • Share/Bookmark

How to Convert 5 Digits Numeral to The Date Value?

August 28th, 2009 Masino Sinaga No comments

A few days ago, a friend of mine asked me for help. He wanted to export his data from Excel file into Access database file. There were about sixteen thousand rows in Excel that have to be exported into Access. One of the columns in that Excel had a Date data. Unfortunately, most of those rows have the 5 digits numeral data, and not in the real Date Value data. For example, there was a row with value ‘38353. As we know, this is not a valid Date, right? Besides that, there is a ‘ character before the value itself. In this case, that value become a String and not a numeral value anymore. Read more…

  • Share/Bookmark

Change the Date Format in WordPress Theme

August 23rd, 2009 Masino Sinaga 21 comments

If you want to change the date format based on your theme that you are using in WordPress, then you have to edit a code or such a string in the .po and .mo file, regarding to your language in that theme. Typically, these files are located in \themes\{yourtheme}\{langdirectory}\ sub directory. Adjust {yourtheme} with your theme name, and {langdirectory} with your language directory name (some themes using “lang”; and the others using “language” as the language directory name). Read more…

  • Share/Bookmark