• This forum has been archived. New threads and replies may not be made. All add-ons/resources that are active should be migrated to the Resource Manager. See this thread for more information.

Remove Identities & Conversation options from privacy page?

Dean

in memoriam
The Contact Details page has the Conversation options, and we are not going to use the Identity services. How can they be removed from the account_privacy template?

untitleddd.webp


Additional information:
I put <xen:comment> around the last account_privacy template fieldset, and while that worked, it has the side effect of disabling the conversations & allow view identities (xf_user_privacy -> allow_send_personal_conversation = allow_view_identities = none) whenever Save is clicked on the Privacy page. Ideally both of those would not change when that page is saved.
<xen:comment>
<fieldset>
</fieldset>
</xen:comment>

Here is the part of the code in that template...
Code:
<xen:comment>
<fieldset>
        <dl class="ctrlUnit sectionLink" id="contact_details">
            <dt><a href="{xen:link 'account/contact-details'}">{xen:phrase edit_your_contact_details}</a></dt>
            <dd>
                <ul>
                    <li><label for="ctrl_allow_send_personal_conversation_enable"><input type="checkbox" name="allow_send_personal_conversation_enable" value="1" id="ctrl_allow_send_personal_conversation_enable" class="Disabler OptOut" {xen:checked "{$visitor.allow_send_personal_conversation} != 'none' "} /> {xen:phrase start_conversations_with_you}:</label>
                        <ul id="ctrl_allow_send_personal_conversation_enable_Disabler">
                            <li>
                                <select name="allow_send_personal_conversation" class="textCtrl autoSize" id="ctrl_allow_send_personal_conversation">
                                    <option value="everyone" {xen:selected "{$visitor.allow_send_personal_conversation} == 'everyone' "}>{xen:phrase all_visitors}</option>
                                    <option value="members"  {xen:selected "{$visitor.allow_send_personal_conversation} == 'members'  "}>{xen:phrase members_only}</option>
                                    <option value="followed" {xen:selected "{$visitor.allow_send_personal_conversation} == 'followed' "}>{xen:phrase people_you_follow_only}</option>
                                </select>
                            </li>
                        </ul>
                    </li>
                    <li><label for="ctrl_allow_view_identities_enable"><input type="checkbox" name="allow_view_identities_enable" value="1" id="ctrl_allow_view_identities_enable" class="Disabler OptOut" {xen:checked "{$visitor.allow_view_identities} != 'none' "} /> {xen:phrase view_your_identities}:</label>
                        <ul id="ctrl_allow_view_identities_enable_Disabler">
                            <li>
                                <select name="allow_view_identities" class="textCtrl autoSize" id="ctrl_allow_view_identities">
                                    <option value="everyone" {xen:selected "{$visitor.allow_view_identities} == 'everyone' "}>{xen:phrase all_visitors}</option>
                                    <option value="members"  {xen:selected "{$visitor.allow_view_identities} == 'members'  "}>{xen:phrase members_only}</option>
                                    <option value="followed" {xen:selected "{$visitor.allow_view_identities} == 'followed' "}>{xen:phrase people_you_follow_only}</option>
                                </select>
                            </li>
                        </ul>
                    </li>
                </ul>
            </dd>
        </dl>
    </fieldset>
</xen:comment>
    <dl class="ctrlUnit submitUnit">
        <dt></dt>
        <dd><input type="submit" name="save" value="{xen:phrase save}" accesskey="s" class="button primary" /></dd>
    </dl>

    <input type="hidden" name="_xfToken" value="{$visitor.csrf_token_page}" />
</form>
 
I updated post #1 with a new image of what is desired. Remove of both items from the account_privacy template.
 
I updated post #1 with a new image of what is desired. Remove of both items from the account_privacy template.


The commenting out that block will work. What should be done though is add in a hidden option that contains the conversation setting the member has selected on the other page, for the datawriter, :)

Code:
    <dl class="ctrlUnit submitUnit">
        <dt></dt>
        <dd><input type="submit" name="save"  value="{xen:phrase save}" accesskey="s" class="button primary"  /></dd>
    </dl>
    <input type="hidden" name="allow_send_personal_conversation" value="{$visitor.allow_send_personal_conversation}" />
    <input type="hidden" name="allow_view_identities" value="{$visitor.allow_view_identities}" />
    <input type="hidden" name="_xfToken" value="{$visitor.csrf_token_page}" />
</form>
 
Top Bottom