The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
time format?
Ok so with help from staff I was able to change my forums last post time to say "X minutes ago"
So now I want to change this in a older mod I have. The code is like this.... Code:
$gnptime = vbdate('H:i', $gthread[lastpost]); |
#2
|
||||
|
||||
Try something like:
PHP Code:
|
#3
|
|||
|
|||
so I replace 'timeformat' with what???
BTW thanks for answering ! |
#4
|
||||
|
||||
You don't replace it with anything. The variable being used $vbulletin->options['timeformat'] will be in your vBulletin date/time format options.
If you want to learn about the "H:i" modifier characters, view this page: http://us2.php.net/manual/en/function.date.php Have you tried PHP Code:
If you want to do it in a more complicated way it would be: PHP Code:
|
#5
|
|||
|
|||
thanks that was what I meant to ask sorry I wasnt more clear.
What im trying to achieve is X minutes ago |
#6
|
||||
|
||||
I gave you a line to try in place of what you were trying.
|
#7
|
|||
|
|||
I know and I did thank you but that didnt do anything.... See I used 'H:i A' BUT It still shows army time. I tried the other guys code and it shows the wrong time.
heres mine..... 21-03, 21:08 PM I want it to look like 21-3, 9:08 PM Lastly I really wanted it to look say it was posted 1 minute ago... 21-3, 1 Minute ago IS this possible? |
#8
|
||||
|
||||
That's why I gave you the php manual page, it tells you how to make your own date format string. But since you're too lazy, here...
For "21-3, 9:08 PM" Use: PHP Code:
PHP Code:
|
#9
|
|||
|
|||
sorry I am lazy I thought maybe someone knew off the top of their head as ive seen this on many forums. THanks for your hard work. Lately I have been lazy, working alot! thanks!
--------------- Added [DATE]1237755290[/DATE] at [TIME]1237755290[/TIME] --------------- OK I see what u mean by the date thing so I guess I will remove that. Now I tried some of the code without the date thing but that only will show just a comma now? Any idea on that? I have tried the coding found at php website with no good results. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|