Home arrow Forum 2.0.3 Tester Questions and report Topic
  Welcome, Guest. Please login or register.
Did you miss your activation email?
November 22, 2008, 03:38:41 PM
Home New Posts Search Calendar


Login with username, password and session length
+  Joomla Forum
|-+  Joomla Hacks
| |-+  Joomla-SMF Forum Support
| | |-+  Joomla-SMF 2.0.x (Moderators: -Wolverine, kai920)
| | | |-+  2.0.3 Tester Questions and report Topic
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Go Down Print
Author Topic: 2.0.3 Tester Questions and report Topic  (Read 2338 times)
Livebox
Guest
2.0.3 Tester Questions and report Topic
« on: March 19, 2007, 01:07:56 PM »

When you are an tester off the 2.0.3 Bridge You can ask your questions in here.

When you want to be an tester you can PM Wolverine. Please only use this topic for questions and bug reports about the 2.0.3 Bridge

Have fun with testing and many thanks all for the help

Greetz,
Daan

PS: you will find and Excel file in the archive file with some test metrics. This will guide you through the testing  Wink
« Last Edit: March 19, 2007, 01:39:59 PM by Livebox » Logged
Livebox
Guest
Re: 2.0.3 Tester Question and report Topic
« Reply #1 on: March 19, 2007, 01:26:54 PM »

When I want to edit an profile Like the website name. I get this error. See picture. When I install the 2.0.2 Bridge the problem is gone. seems like a small bug? I did not select the option for CB. but it seems to look for it. Did an basic install.. (did not installed CB and the plugin) Default install

Quote Wolverine
Quote
I just fixed this problem
Logged
stefangranholm
Joomla Newbie
*

Karma: +0/-0
Offline Offline

Posts: 8


View Profile
Re: 2.0.3 Tester Questions and report Topic
« Reply #2 on: March 24, 2007, 08:05:46 AM »

To you who uses Jreaction comment system : BETA will conflict at the front page, when wieving a front page "read more" subject.

works great with CM, exept the redirection profile DO go to the SMF profile, even when et shoul redirect to the CB profile.

All i all, it do work well all other places. Login, registration in joomla and so on. I would wish it coul support C. Walters Anti spam system.
Logged
Livebox
Guest
Re: 2.0.3 Tester Questions and report Topic
« Reply #3 on: March 24, 2007, 11:55:56 AM »

What is your configuration?
Version of;
Joomla!
SMF
Cimmunity Builder
Do you use the 2.0.3 JSMF Bridge (the tester version)
Logged
Philippe Vanhaesendonck
Joomla Newbie
*

Karma: +1/-0
Offline Offline

Posts: 5


View Profile
Re: 2.0.3 Tester Questions and report Topic
« Reply #4 on: April 05, 2007, 04:22:22 PM »

Bug report: when 'Synchronize Usernames Only' flag is set, and the user updates its Name in Joomla!, the DisplayName is set to blank in SMF.

Problem analysis: in file administrator/components/com_smf/admin.smf.class.php $data is used as an object while at this point it is an array

Fix:
Code:
--- administrator/components/com_smf/admin.smf.class.php.orig   2007-04-05 21:22:37.000000000 +0200
+++ administrator/components/com_smf/admin.smf.class.php        2007-04-05 21:15:00.000000000 +0200
@@ -1342,7 +1342,7 @@

                     case 'realName':
                         if ($jsmfConfig->sync_uname) {
-                               $val = $data->username;
+                               $val = $data['username'];
                         }
                         break;
                     case 'gender':
====================================================================

Issue: I do not get smf_id in my CB profile.

Analysis: from what I can see from the code, the only place where the smf_id is added to CB is in integrateChangeMemberData, which is called when something changes in SMF (at least that's my understanding, but I can be wrong with that)
Since in my setup, registration and profile maintenance is only done in Joomla!/CB, I never get the smf_id in my joomla! profile...

Proposed solution: my knowledge of the bridge is limitted, but the following hack seems to work: when a user is registered in CB and inserted in SMF, we retrieve the smf_id and update CB
Code:
--- components/com_smf/smf.class.php.orig       2007-04-05 23:17:44.000000000 +0200
+++ components/com_smf/smf.class.php    2007-04-05 23:16:31.000000000 +0200
@@ -990,6 +990,32 @@
             $data->password = $password;
             if (!$this->createSMFUser($data)) {
                return false;
+            } else {
+              // PVanhaes
+              // We can update CB with SMFID....
+              // We could be more efficient, but this should work...
+              if ($this->isComInstalled('Community Builder%')) {
+                    $jid = $this->getJid(null, $data->username);
+                    if (empty($jid)) {
+                        mosErrorAlert($jsmf->err);
+                        return false;
+                    }
+                    $sid = $this->getSMFid(null, $data->username);
+                    if (empty($sid)) {
+                        mosErrorAlert($jsmf->err);
+                        return false;
+                    }
+                    $query =
+                        "UPDATE #__comprofiler " .
+                        "SET cb_jsmfid = '$sid' " .
+                        "WHERE id = '$jid' " .
+                        "LIMIT 1";
+                    $database->setQuery($query);
+                    if (!$database->query()) {
+                        mosErrorAlert($database->getErrorMsg().' ~~~ FROM::'.__FILE__.' || '.__FUNCTION__.' || '.__LINE__);
+                        return false;
+                    }
+                }
             }
         }
         return true;

===================================================================
Issue: cannot change username in CB (Error: Username (MyNewName) does not exist in SMF or not able to retrieve userid )

Analysis: in administrator/components/com_smf/admin.smf.class.php, function updateMember we have:
Code:
        //check if we already have the user's smf id from CB
        if (empty($extras->cb_jsmfid)) {
            $uid = $this->getSMFid($data->id, $data->username);
            if (!$uid || empty($uid)) {
                //might be updating their username
                if ($jsmfConfig->cache_user_array && $jsmfConfig->caching) {
                    $user_array = $jsmfCache->get('user_array');
                    if (empty($user_array)) {
                        jsmfFrontend::_buildUserArray();
                        $user_array = $jsmfCache->get('user_array');
                    }
                    $uid = array_search($data->id, $user_array);
                }
                if (empty($uid)) {
                    //user doesn't exist, no good
                    $this->err = 'Username ('.$data->username.') does not exist in SMF or not able to retrieve userid ~~~ FROM::'.__FILE__.' || '.__FUNCTION__.' || '.__LINE__;
                    return false;
                }
            }

Now,
  • getSMFid fails since we are changing username (normal behaviour)
  • the cache lookup fail as well, since I have user cache disabled (normal behaviour as well)
  • but what is strange is that cb_jsmfid is not in $extras, while I do have the smf_id in CB!
It took me some time to understand why the cb_jsmfid was not in extras.
Looking at the CB code, it appears that CB will only exposes in $extras the fields that are published and not readonly. The issue here is that jsmf create the field readonly...
I have switched that readonly flag, and now it works.
This is not very nice since the field appears in the profile with no value (hidden).

Again this may not be the proper fix here, just wanted to highlight the issue and a possible workaround...



Modarator Note: please edit your post.In stat of posting a new one Wink We merged all post to one.

Contributor Note: This is your decision, but I was reporting 3 separate issues that in my view deserves 3 different posts -- Now if somebody want to comment on one of these issues, they are all mixed.
Are you on a post-saving quest?
Groetjes
Philippe
« Last Edit: April 06, 2007, 04:52:08 AM by Philippe Vanhaesendonck » Logged
-Wolverine
Moderator
Joomla Guru
*****

Karma: +376/-34
Offline Offline

Posts: 3393


Lead Developer


View Profile WWW
Re: 2.0.3 Tester Questions and report Topic
« Reply #5 on: April 16, 2007, 10:59:44 PM »

Philippe, extremely valuable feedback!  I have merged your suggestions into the bridge and will take a look at the smf id issue.  Actually, I filed a bug report with CB stating that a change in username should send both the old and new username to any triggered plugins. 
« Last Edit: April 16, 2007, 11:01:26 PM by -Wolverine » Logged

Need help?  Check Here First!
Get the JSMF User Guide
SEARCH this forum.
Pages: [1] Go Up Print 
« previous next »
Jump to:  



Login with username, password and session length

Powered by MySQL Powered by PHP Joomla Forum | Powered by SMF 1.1 RC1.
© 2001-2005, Lewis Media. All Rights Reserved.
Joomla Bridge by JoomlaHacks.com
Valid XHTML 1.0! Valid CSS!

Joomla Hacks is a Joomla Components, Joomla Modules, Joomla Templates, & Joomla Mambots resource portal. None of the text or images in this public website may be copied without the expressed written consent of the authors. Copyright 2005 by JoomlaHacks.com. Powered by Joomla. All rights reserved.
Terms of Use
Joomla Hacks



Joomla Hacks
German Lang French Lang Italian Lang Spanish Lang Japanese Lang Chinese Lang
Search Contact About Advertise Blogs Topsites Submit News Register Login