HTML Logo by World Wide Web Consortium (www.w3.org). Click to learn more about our commitment to accessibility and standards.

Moving forward with Composr

ocPortal has been relaunched as Composr CMS, which is now in beta. ocPortal 9 will be superseded by Composr 10.

Head over to compo.sr for our new site, and to our migration roadmap. Existing ocPortal member accounts have been mirrored.


Uploading avatars...or not

Login / Search

 [ Join | More ]
 Add topic 
Posted
Rating:
#35688 (In Topic #8045)

Non-joined user

I've looked and looked (I could be going blind now, I'm not sure :lol:) but I can't find a way to prevent members from uploading avatar images. I would prefer that they use their own photo storage accounts elsewhere and just use a URL to link to their av. Please tell me there's a way to do this and I've just missed the setting somewhere?
Back to the top
 
Posted
Rating:
#35689
Avatar

Hi,

You'll need to deny permissions to the personalzone:editavatar page using the Permission Tree Editor. Browse to 'Personal Zone' then to 'editavatar', untick the groups you want it denied to, and save.


Become a fan of ocPortal on Facebook or add me as a friend. Add me on on Twitter.
Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about ocPortal whenever you see the opportunity.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying ocPortal on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Back to the top
 
Posted
Rating:
#35690

Non-joined user

Thank you Chris :)

Back to the top
 
Posted
Rating:
#35691

Non-joined user

Ooops, well now they can't edit their avatars at all. Is there no way to distinguish the permission to allow them linking to an image but NOT uploading?
Back to the top
 
Posted
Rating:
#35706
Joe
Avatar

Honoured member

You can probably try restricting the uploading of image extension(s).

1. Goto Adminzone
2. Click 'Setup' tab
3. Hit 'Configuration'
4. Click 'Security/Group options'

Finally, scroll down to the last box (should be the 'Upload' box), and remove any image extensions from the text-fields.

Warning: This might restrict someone, including yourself, from uploading images to the Gallery.

Back to the top
 
Posted
Rating:
#35715

Non-joined user

Thank you Joe, I'm going to give that a go. :)
Back to the top
 
Posted
Rating:
#35777
Avatar

Sorry for not reading very carefully…

There isn't an official way to do this. One other thing you could do is you could remove the upload field from the edit-avatar form.

Modified FORM_PAGE_FIELD:

Code

{+START,IF,{$NAND,{$MATCH_KEY_MATCH,personalzone:editavatar},{$OR,{$EQ,{BORING_NAME},alt_url},{$EQ,{BORING_NAME},file}}}}

{$,If editing this template, make sure that the setRequired Javascript function is updated}
<tr>
   <th id="requirea__{$?,{$IS_EMPTY,{BORING_NAME*}},{$RAND},{BORING_NAME*}}" abbr="{NAME=}" class="de_th {$?,{REQUIRED},dottedborder_barrier_a_required,dottedborder_barrier_a_nonrequired}">
      <span class="field_name"><span id="requireb__{$?,{$IS_EMPTY,{BORING_NAME*}},{$RAND},{BORING_NAME*}}" style="display: {$?,{REQUIRED},inline,none}">* </span>{NAME*}</span><br />

      {+START,IF_NON_EMPTY,{COMCODE}}
      <div class="comcode_supported">
         <input type="hidden" name="comcode__{$?,{$IS_EMPTY,{BORING_NAME*}},{$RAND},{BORING_NAME*}}" value="1" />
         {COMCODE}
      </div>
      {+END}
   </th>

   <td id="required__{$?,{$IS_EMPTY,{BORING_NAME*}},{$RAND},{BORING_NAME*}}" class="{$?,{REQUIRED},dottedborder_barrier_b_required,dottedborder_barrier_b_nonrequired}">
      <div id="error_{$?,{$IS_EMPTY,{BORING_NAME*}},{$RAND},{BORING_NAME*}}" style="display: none" class="input_error_here">&nbsp;</div>
      {+START,IF_NON_EMPTY,{BORING_NAME}}{+START,IF,{$NOT,{SKIP_LABEL}}}
         <div class="accessibility_hidden"><label for="{BORING_NAME*}">{NAME*}</label></div>
      {+END}{+END}
      {INPUT}
      {+START,IF_NON_EMPTY,{DESCRIPTION}}
         <div class="associated_caption">{DESCRIPTION}</div>
      {+END}
      <input type="hidden" id="requirec__{$?,{$IS_EMPTY,{BORING_NAME*}},{$RAND},{BORING_NAME*}}" name="require__{BORING_NAME*}" value="{$?,{REQUIRED},1,0}" />
   </td>
</tr>

{+END}


Become a fan of ocPortal on Facebook or add me as a friend. Add me on on Twitter.
Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about ocPortal whenever you see the opportunity.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying ocPortal on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Back to the top
 
Posted
Rating:
#35789
Joe
Avatar

Honoured member

I'd recommend Chris's method. Not sure if you're using the Gallery system, but I'd hate to see a module non-functional on your site (if you were to do what I said).

Back to the top
 
Posted
Rating:
#35909

Non-joined user

Oooh this is fabulous! This would solve a lot of problems, thank you Chris! We had a phpBB forum before and members were never allowed to upload their av's (why they keep on insisting on trying now is beyond me but that's the public for ya) I've had it set as you suggested Joe and it's been brilliant at keeping them from uploading anything but of course they still ask. LOL  Thank you both for your help!! :rockon:
Back to the top
 
There are too many online users to list.
Control functions:

Quick reply   Contract

Your name:
Your message: