[0.8.1] Making activity.title for restful match the js apis

1 view
Skip to first unread message

Cassie

unread,
Jul 29, 2008, 2:17:46 PM7/29/08
to opensocial-an...@googlegroups.com
Right now activity objects have their titles specified like this:

{
"title" : { "type" : "html",
"value" : "<a href=\"foo\">some activity</a>"
}
}


This does not match with the js apis as all of the activity titles
have the same type - ie limited html. Let's make these the same and
simplify the title to look like this:

{
"title" : "<a href=\"foo\">some activity</a>"
}


- Cassie

John Panzer

unread,
Jul 30, 2008, 6:23:05 PM7/30/08
to opensocial-an...@googlegroups.com
+1, but with the addition to the spec that the content of the title is always (1 level entity escaped) HTML (may be filtered by server as needed).  I don't think that's in any of the specs AFAICT.


John Panzer (http://abstractioneer.org)

Ian Boston

unread,
Jul 30, 2008, 6:34:36 PM7/30/08
to opensocial-an...@googlegroups.com
No explicitly, but implied, by indication Title contains a limited
set of HTML tags.

Explicit would be good and avoid potential exploits in containers.

"TITLE
<static> object TITLE
A string specifying the primary text of an activity.
Titles may only have the following HTML tags: <b> <i>, <a>, <span>.
The container may ignore this formatting when rendering the activity."
http://www.opensocial.org/Technical-Resources/opensocial-spec-v08/
opensocial-reference08#opensocial.Activity.Field.TITLE

Louis Ryan

unread,
Jul 30, 2008, 7:20:09 PM7/30/08
to opensocial-an...@googlegroups.com
+1

On Tue, Jul 29, 2008 at 11:17 AM, Cassie <do...@google.com> wrote:

Kevin Marks

unread,
Jul 30, 2008, 9:36:51 PM7/30/08
to opensocial-an...@googlegroups.com
Why is this escaped in the JSON form? I can see the need in the XML form, but in JSON this is just odd

why not:

{
 "title" : "<a href=\"foo\">some activity</a>"
}

Is this for JSONP reasons?

Chris Chabot

unread,
Aug 4, 2008, 3:29:17 AM8/4/08
to opensocial-an...@googlegroups.com
Has consensus been reached on this thread? It seems to have not
received any comments for a few days.

I'm willing to contribute my +1 to this proposal but then it still
needs 2 more.

-- Chris

Evan Gilbert

unread,
Aug 4, 2008, 8:04:22 PM8/4/08
to opensocial-an...@googlegroups.com
+1

I'm assuming that Kevin's version is the correct one - this is one of the few fields that is meant to be assigned to HTML content.
Reply all
Reply to author
Forward
0 new messages