• Fabrice Talbot
  • NEWBIE
  • 0 Points
  • Member since 2013

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 3
    Replies
We have an app that posts to Chatter when it performs a certain function and we're porting this to work in Communities. The one thing we're stuck on is how to set the FeedItem.NetworkScope for the Community from which the FeedItem is being posted. 

Is there a way to obtain the Community ID in Apex so that we can set it as the NetworkScope?

We've been developing some functionality for a client that was orginally intended for Customer Portal but will now be going out on Salesforce Communties. We set up Communties on dev org and quickly discovered that custom buttons running javascript break if they reference libraries; including SF connection.js. We get a 404 not found error for connection.js.

 

The button works on Internal view but when the users switches to the portal it breaks.

 

Javascript using the same Ajax Toolkit library, JQuery etc running on a VF page works fine

 

Example:

 

Custom Button that contains this reference {!REQUIRESCRIPT('/soap/ajax/26.0/connection.js')} works in internal mode but gives a 404 externally. The library isn't the issue, Jquery libraries even saved as a static resource fail

 

I would appreciate some assistance on this