Can somebody hint the follow: I have to insert in my custom module oа Joomla (HTML essentially) the service info, which is shown by Joomla usually - I need the date of creation and the number of how this article was viewed?
Asked
Active
Viewed 414 times
0
-
What do you mean: the number of how this article was viewed ? – Shaz May 28 '12 at 16:04
-
Yes, I do. Some PHP-code $count = JFactory("article").getHowManyViewver – Eugene Shmorgun May 28 '12 at 16:34
-
What's the joomla version your developing on ? – HamZa May 28 '12 at 18:17
-
2sql query provided by Okonomiyaki3000 is your best bet and please o please upgrade to Joomla 2.5 if you get the chance ;) – Lodder May 29 '12 at 02:26
-
1@Lodder See that little 'up' arrow next to my answer? – Okonomiyaki3000 May 29 '12 at 06:31
-
o yeah...made use of it now ;) – Lodder May 29 '12 at 17:11
1 Answers
2
You can run a very simple query to get this:
SELECT `created`, `hits` FROM #__content WHERE `id` = <your article id>
created
is the creation date, hits
is it number of times the article has been viewed.

Okonomiyaki3000
- 3,628
- 23
- 23
-
you can get the article id with http://stackoverflow.com/questions/6056886/joomla-plugin-how-to-get-article-tile-and-article-id to make it dynamic ! – HamZa May 29 '12 at 07:41