Extra files for advprofile
Posted 01/06/2008 - 23:06 by Michelle
Update Jan 24: I removed the file because they have been committed to the modules. You need to use the dev version of both bio and CCK until they have new releases.
Advanced profile is dependent on patches getting into bio and cck. You can see the issues here http://drupal.org/node/200708 and here http://drupal.org/node/203495 . To make it a little easier, I zipped up the files. Put the bio ones in the bio directory and the content ones in the cck directory. Once these are in the official releases of bio and cck you won't need to deal with this anymore.
[Jan 10: I put an updated bio.module in the zip]
Michelle
This error occurs right after installing the needed modules:
warning: array_keys() [function.array-keys]: The first argument should be an array in /home/grahamwellington/public_html/mysite/drupal/modules/bio/bio_views.inc on line 39.
I'm using the patched files you provided above.
Hi,
The only missing part I think is a sample template.php, I know adding the variables can be a tricky part.
Could you upload your Garland template for us to view?
Thanks
Sean
content_panels.inc looks like it has been updated.
See http://drupal.org/node/203495#comment-683873 at the bottom for it... This is based on the Date of the files in the zip
That comment is just pointing back here. What's in the zip is the files you should use until bio/cck get sorted out. If they end up not being committed, I'll roll the files into advprofile so you don't need to maintain hacked modules.
Michelle
I received a similar error to Graham's "another error" above.
Because it references the Bio contributed module, I went ahead and opened an issue here under the Bio module.
However, with all the dependencies the Advanced Profile module has with other modules, I'm not sure where the problem is so I thought I'd let Michelle know. :)
Thanks,
Walt
Yeah, I've been talking to him on IRC. Guess I should have posted here as well for everyone else. That bio error only happens on install that I can tell and doesn't appear to be causing any other problems. Thanks for filing an issue. I haven't had a chance to make sure it wasn't advprofile related. Since it wasn't causing problems, it had a low priority.
Michelle
Hi there,
I'm having a similar problem, and I any tips would be fantastic.
having installed advanced profile and all the supporting elements. I get the same error as the first poster.
Fatal error: Call to undefined function dsm() in /home/maybeor/www/www/modules/advanced_profile/advanced_profile.module on line 108
I get this when I try to enter: admin/settings/advancedprofile
now I believe this may be due to variables issues in my template.php. So, here is my template.php variables section:
---
function _phptemplate_variables($hook, $vars = array()) {
if (module_exists('advanced_profile')) {
$vars = advanced_profile_addvars($hook, $vars);
}
if (module_exists('advanced_forum')) {
$vars = advanced_forum_addvars($hook, $vars);
}
if ($hook == 'page') {
return $vars;
}
return array();
}
---
I realise the if ($hook == 'page') bit is a bit different. I'm using theme Alek 2.0, and I think that's sort of worked for advanced forum and when I used Michelle's earlier tutorial. So this might be the problem.
The other possibility is that when I return to the admin page it says:
---
* The content type uprofile already exists in this database.
* Exiting. No import performed.
---
I'm thinking that perhaps because I had followed Michelle's user profiles 2 tutorial (I did it backwards before installing the new advanced profile module). I probably need to delete some databases or something.
Sorry this is such a lengthy rant...any help on any of this would be sooo good.
thanks
thomas
I've been doing something similar using views, panel 2, and CCK, but ran into a couple snags.
I'd like to use this method, but no matter what I add to the template.php file my site breaks...
so where would I add this code...
if (module_exists('advanced_profile')) {
$vars = advanced_profile_addvars($hook, $vars);
}
This is from the salamander theme template.php
<?php
// add jquery.pngFix.js file
drupal_add_js(drupal_get_path('theme', 'salamander') . '/js/jquery.pngfix.js', 'theme');
// Salamander's regions
function salamander_regions() {
return array(
'header' => t('Header'),
'user1' => t('User 1'),
'user2' => t('User 2'),
'user3' => t('User 3'),
'sidebar_left' => t('Left sidebar'),
'sidebar_right' => t('Right sidebar'),
'content_top' => t('Top content'),
'content_bottom' => t('Bottom content'),
'user4' => t('User 4'),
'user5' => t('User 5'),
'user6' => t('User 6'),
'footer' => t('Footer')
);
}
// Breadcrumb override
function salamander_breadcrumb($breadcrumb) {
if (!empty($breadcrumb)) {
$breadcrumb[] = drupal_get_title(); // full breadcrumb
return ''. implode(' » ', $breadcrumb) .'';
}
}
// Quick fix for the validation error: 'ID "edit-submit" already defined'
$elementCountForHack = 0;
function phptemplate_submit($element) {
global $elementCountForHack;
return str_replace('edit-submit', 'edit-submit-' . ++$elementCountForHack, theme('button', $element));
}
Sorry about the long post but it's been driving me nuts for 6 months not being able to add anything at all to the file.
Daryl
I spent a lot of time writing http://drupal.org/node/207841 . Please read it and use the issue queue if you have more problems or comment on that node if you have suggestions to make it clearer. I'm going to close comments on this node. This is not an issue queue.
Michelle

Site contents are licensed under a
I followed your directions to a tee but still get this error after installing advprofile:
Fatal error: Call to undefined function: dsm() in /home/grahamwellington/public_html/mysite/drupal/modules/advanced_profile/advanced_profile.module on line 108
I added the patched files to the correct directories, and also added that extra line to the template.php in my garland theme.
What did I miss?
Thanks