• twitter image
  • facebook image
  • youtube image
  • linkedin image
Language: CMS Made Simple Czech CMS Made Simple France CMS Made Simple Hungary CMS Made Simple Russia CMS Made Simple Netherlands

All times are UTC




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 posts ] 
Author Message
 Post subject: Patch for Statistics module
PostPosted: Tue Apr 22, 2008 4:36 pm 
Offline
Forum Members
Forum Members

Joined: Wed Mar 26, 2008 1:49 am
Posts: 233
Location: Stuttgart / Germany
Attached is a MLE patch for the Statistics module.

Regards,
Carsten


Attachments:
modules-Statistics-Statistics.module.php.diff.txt [777 Bytes]
Downloaded 638 times
Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Patch for Statistics module
PostPosted: Tue May 06, 2008 10:55 am 
Offline
Forum Members
Forum Members

Joined: Fri Apr 25, 2008 8:14 pm
Posts: 10
Hi,

I have MLE 1.2.4b and added this patch. I have 2 languages: english and dutch. Before the patch, the Current Online Visitors always calles the pages by the Dutch titles. After the patch it calles all the pages by the English title. Ofcourse it needs to call the pages whatever is really is (so if I visit a Dutch page, I would like the dutch title and an english page should get an english title in Current Online Visitors).
What can I do?

Sincerely,
Sirab


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Patch for Statistics module
PostPosted: Wed May 07, 2008 4:17 pm 
Offline
Forum Members
Forum Members

Joined: Wed Mar 26, 2008 1:49 am
Posts: 233
Location: Stuttgart / Germany
Hi Sirab,

sorrry for the delay.

Quote:
Before the patch, the Current Online Visitors always calles the pages by the Dutch titles. After the patch it calles all the pages by the English title.

That's not exactly what happens. "Statistics" only count pages with their pageid, regardless if you access the Dutch or English version. And in the "Statistics" you see now the page titles according to your current language setting.

Without this patch, you see most time no page titles. Or, if you have transferred a normal site to MLE, you see only the old page titles, but no titles for new pages (or if you change a page title).

Quote:
Ofcourse it needs to call the pages whatever is really is

That would be really nice ;-) But needs a lot of more changes in "Statistics" (and makes "Statistics" uncompatible to the standard version.)

Regards,
Carsten


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Patch for Statistics module
PostPosted: Thu May 08, 2008 2:46 pm 
Offline
Forum Members
Forum Members

Joined: Fri Apr 25, 2008 8:14 pm
Posts: 10
Ok, thanks!


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Patch for Statistics module
PostPosted: Wed Mar 04, 2009 3:33 pm 
Offline
Forum Members
Forum Members
User avatar

Joined: Sat Jan 24, 2009 3:12 pm
Posts: 183
...and? still I dont know what should I to modify for good work module..  ???

_________________
CMS Made Simple! Best CMS! :)


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
 Post subject: Re: Patch for Statistics module
PostPosted: Fri Mar 06, 2009 5:47 pm 
Offline
Support Guru
Support Guru
User avatar

Joined: Mon Jul 04, 2005 5:12 pm
Posts: 4809
Location: Ferrara, Italy
requish wrote:
...and? still I dont know what should I to modify for good work module..  ???


Is a diff file:
Quote:
--- modules/Statistics/Statistics.module.php.orig 2008-04-22 17:36:43.859375000 +0100
+++ modules/Statistics/Statistics.module.php 2008-04-22 17:37:16.765625000 +0100
@@ -644,7 +644,10 @@

function InternalGetPageTitle($content_alias, $forcemenutext=false) {
$db=&$this->GetDb();
- $query="SELECT content_name,menu_text FROM ".cms_db_prefix()."content WHERE content_alias=? OR content_id=?";
+// Start MLE
+        global $mleblock;
+ $query="SELECT content_name$mleblock AS content_name,menu_text$mleblock AS menu_text FROM ".cms_db_prefix()."content WHERE content_alias=? OR content_id=?";
+// End MLE
$dbresult=$db->Execute($query,array($content_alias,$content_alias));
if (!$dbresult || $dbresult->RecordCount()==0) return "";
$row=$dbresult->FetchRow();


Edit modules/Statistics/Statistics.module.php and (around 644 row) and look for signs:
- Delete this row
+ Add this row

Alby

_________________
Former Italian Admin and Moderator
Multilingual: MLE is not CMSMS


Last edited by alby on Sat Mar 07, 2009 9:14 am, edited 1 time in total.

Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
A2 Hosting