[Joomla 1.5RC3-FIX] Profile update cb.core foreach

15 years 5 months ago #79916 by CyberCobre
file didn't attach. Reposted. Mod, please delete this post

Post edited by: CyberCobre, at: 2008/11/18 00:19

Please Log in to join the conversation.

15 years 5 months ago #79918 by CyberCobre
To fix this, simply FTP into your account, download (forced ascii) the cb.core.php file found in:

../components/com_comprofiler/plugin/user/plug_cbcore

Find lines 235 and 236 which will look like this:

$userParams = array();
$userParams = $this->_getUserParams($ui, $user);

Change them to this (in other words, swap them around):

$userParams = $this->_getUserParams($ui, $user);
$userParams = array();

Reload the cb.core.php file (forced ascii, overwrite)

Problem solved.

A zip file of the fixed cb.core.php file is attached.




Attachment cb-e13bd50628871d3cf476322ca5ce5619.zip not found

Attachments:

Please Log in to join the conversation.

15 years 5 months ago #80388 by chechovacan
Replied by chechovacan on topic Re:[Joomla 1.5RC3-FIX] Profile update cb.core fore
sdwyer wrote:

I would also recommend changing line 238 of cb.core.php from:
[code:1]if ( ( count( $userParams ) > 0 ) && in_array( $_CB_framework->getCfg( "frontend_userparams" ), array( '1', null) ) ) {[/code:1]
to:
[code:1]if ($userParams !== false && ( count( $userParams ) > 0 ) && in_array( $_CB_framework->getCfg( "frontend_userparams" ), array( '1', null) ) ) {[/code:1]
since it is possible that JParameter::getParams could return false, and count(false) returns 1 for some reason.


:woohoo: This just work fine!... thanks a lot!...

Please Log in to join the conversation.

15 years 4 months ago #80455 by judlee
Replied by judlee on topic Re:i fix 1.5 profile update error
squallata wrote:

in comprofiler.html.php
change this
[code:1]
//--><!]]></script>
<form action="<?php echo sefRelToAbs("index.php?option=$option".getCBprofileItemid(true)); ?>" method="post" id="adminForm" name="adminForm" onsubmit="return submitbutton(this)">
<!-- TAB -->
[/code:1]
white this
[code:1]
//--><!]]></script>
<form action="<?php echo "index.php?option=$option".getCBprofileItemid(); ?>" method="post" id="adminForm" name="adminForm" onsubmit="return submitbutton(this)">
<!-- TAB -->
[/code:1]
and i can update my profile now :D


This worked perfectly. Thanks so much for posting the fix. :cheer:

Please Log in to join the conversation.

15 years 4 months ago #81242 by motnaf
Replied by motnaf on topic Re:i fix 1.5 profile update error
thnx man , you are genius!!!!!

Please Log in to join the conversation.

15 years 4 months ago #81880 by iPoul
For some reason, the only thing all these fixes do, is remove the error, im still not able to actual update the profile (front-end) as a regular user, it just tries to fetch some article which doesnt exist, tho it equal the user id i try to update.

Joomla 1.5.7 - CB 1.1

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.264 seconds

Facebook Twitter LinkedIn