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

Link to use for "Reported Content" addon.

Login / Search

 [ Join | More ]
 Add topic 
Posted
Rating:
#83013 (In Topic #17284)
Avatar

Fan in action

I installed the "Reported Content" addon to allow for reporting of user submitted news, blogs, galleries, etc. but I can't seem to call it up from the blocks I want. What link are we suppose to be using for this?

Back to the top
 
Posted
Item has a rating of 5 (Liked by Shinuk)  
Rating:
#83035
Avatar

ocStaff (admin)

Ah yes, I can see this is not explained anywhere.

Eventually this addon will probably become a core part of the system, but for now it only exists in non-bundled land without any default integration. It works like the reports posts system in the forum, i.e. actually saves the reports onto the forum in the same way.

I'll give an example for news…

In the NEWS_FULL_SCREEN template you'll find the action links are driven by…

Code


   {$,Load up the staff actions template to display staff actions uniformly (we relay our parameters to it)...}
   {+START,INCLUDE,STAFF_ACTIONS}
      1_URL={SUBMIT_URL*}
      1_TITLE={$?,{BLOG},{!ADD_NEWS_BLOG},{!ADD_NEWS}}
      1_REL=add
      1_NOREDIRECT=1
      2_URL={EDIT_URL*}
      2_ACCESSKEY=q
      2_TITLE={!_EDIT_LINK}
      2_REL=edit
      3_URL={NEWSLETTER_URL*}
      3_TITLE={+START,IF_NON_EMPTY,{NEWSLETTER_URL}}{!newsletter:NEWSLETTER_SEND}{+END}
   {+END}

change to:

Code


   {$,Load up the staff actions template to display staff actions uniformly (we relay our parameters to it)...}
   {+START,INCLUDE,STAFF_ACTIONS}
      1_URL={SUBMIT_URL*}
      1_TITLE={$?,{BLOG},{!ADD_NEWS_BLOG},{!ADD_NEWS}}
      1_REL=add
      1_NOREDIRECT=1
      2_URL={EDIT_URL*}
      2_ACCESSKEY=q
      2_TITLE={!_EDIT_LINK}
      2_REL=edit
      3_URL={NEWSLETTER_URL*}
      3_TITLE={+START,IF_NON_EMPTY,{NEWSLETTER_URL}}{!newsletter:NEWSLETTER_SEND}{+END}
      4_URL={$PAGE_LINK,_SEARCH:reportcontent:content_type=news:content_id={ID}:url={$SELF_URL&}}
      4_TITLE=Report this
   {+END}

So, you are probably thinking: what does _SEARCH:reportcontent:content_type=download:content_id={ID}:url={$SELF_URL&} mean?
  • _SEARCH – look for the reportcontent module, wherever it is; you could put site instead, it doesn't matter much
  • reportcontent – our reporting module that does the work
  • news – the content type; the name of a file in sources/hooks/systems/content_meta_aware
  • {ID} – content ID; usually it's passed into a template as a parameter named 'ID' like it is here
  • {$SELF_URL&} – the current URL needs to be passed through



Become a fan of ocPortal on Facebook or add me as a friend.

Expand: Was I helpful? Was I helpful?

Expand: Follow me on Twitter Follow me on Twitter







If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource.
Back to the top
 
Posted
Rating:
#83041
Avatar

Fan in action

You rock. Worked perfectly for news (and blogs), and for galleries after changing the content type. Thanks.  :thumbs:
Back to the top
 
1 guests and 0 members have just viewed this: None
Control functions:

Quick reply   Contract

Your name:
Your message: