Concrete5 commerce - customize profile page [helpful/solved]

Permalink 1 user found helpful
Hi,
I build a shop with C5.
I would like to customize the "profile " page, I need to hide the category "friends" and Search.. because my clients are not "friends" and they don't need to speech each others.

What is the good solution ?
Something with permissions ? or display none in the code ? .. but where ?

thank you

1 Attachment

Elstud
 
irsah replied on at Permalink Reply
irsah
Hi..

1. I believe it would be in the public html/concrete/elements/profile/sidebar.php. copy this file and paste in your root and would look like this publichtml/elements/profile/sidebar.php

Open the file and you can custom the friends profile page edit mode and also the search bar in your users single pages sidebar column

2. Copy the public_html/concrete/single_pages/"profile" folder and paste into your root like so public_html/single_pages/profile/ . Inside the folder would be the .php files for your profile pages. The view.php file would be the page holding your user profile pages, which includes the sidebar above, the message, the avatar etc...

Hope it helps,
Irsah

*edit* did the see the attachment. Just use no. 1.
Elstud replied on at Permalink Reply
Elstud
Thank you,

It's OK for the fist step.
Copy .. and it's Ok to hide the search form, but I can't found to hide "friends" in the sidebar in the view.php ?

This is view.php >

<?php  defined('C5_EXECUTE') or die("Access Denied."); ?>
<div class="sixteen columns">
<div id="ccm-profile-wrapper">
    <?php  Loader::element('profile/sidebar', array('profile'=> $profile)); ?>    
    <div id="ccm-profile-body">   
       <div id="ccm-profile-body-attributes">
       <div class="ccm-profile-body-item">
        <h1><?php echo $profile->getUserName()?></h1>
        <?php 
        $uaks = UserAttributeKey::getPublicProfileList();
        foreach($uaks as $ua) { ?>
            <div>
                <label><?php echo $ua->getKeyName()?></label>
                <?php echo $profile->getAttribute($ua, 'displaySanitized', 'display'); ?>
            </div>


Can you help me more ?
Thank you Irsah
irsah replied on at Permalink Reply
irsah
Ok that was 1 step..

You have to do the step 2, copy the concrete/single_pages/profile/friends.php up to your root single/pages/profile/ folder and edit friends.php file. At top the the code would be like this;

<?php  defined('C5_EXECUTE') or die("Access Denied."); ?>
<div id="ccm-profile-wrapper">
   <?php  Loader::element('profile/sidebar', array('profile'=> $profile)); ?>    
    <div id="ccm-profile-body">   
        <h1><?php echo t('My Friends') ?></h1>
..more code...


Change the line in the h1 tags or you can comment the entire division out for the friends/users call/code...

Or if you do not to use the links at all (i probably missed out on this)...

For the friends links is actually echoed out thru the dashboard> single_pages > friends page. You can edit its page properties to exclude from nav > and permissions for admin only if you do not require the links to display in the profile page for a user/customer.

or if u want to use the link change the name of the page in dashboard > single_pages > friends page to "customer" (ie your example) and the links on your user profile page will change to "customer" as well.
Elstud replied on at Permalink Reply
Elstud
Of course !!!
exclude the page from nav .. page list ... and more ..

Thank you very much for your help !!

Have a good day.

JF
irsah replied on at Permalink Best Answer Reply
irsah
I had too many ideas, first i taught you want to use the friends profile and change to customer but read on again, it's probably best just to exclude it. because a lot of changes then :).

If it's OK you can just mark this thread to close it and others may find it useful. Glad it worked out. Best wishes JF
Elstud replied on at Permalink Reply
Elstud
Humm .. Sorry, I am stupid Guy .. but I don't know How I can close this thread !!
I can stop monitoring but I see nowhere a link to close ..
adajad replied on at Permalink Reply
adajad
Nowhere to close a thread. You can edit the title and include [SOLVED], to inform other users browsing the issue is gone.
irsah replied on at Permalink Reply
irsah
Sorry guys probably i've mislead.. I should have written discussion helpful/solved. Thanks for heads up adajad.