0

I want to get a value of ui:repeat for post in facebook through javascript. The error is Uncaught ReferenceError: some is not defined al HTMLAnchorElement.onclick (index.xhtml:1)

this is my jsf code

<ui:repeat var="leyes" value="#{votarControlador.lstLey}">                                
    <h:outputLabel value="  #{leyes.titulo}"/>
    <h:link  onclick="shareLey(#{leyes.titulo})" value="Post Facebook" />                                                                                                   
</ui:repeat>   

this is my code in javascript:

function shareLey(ley_) 
{
    FB.ui(
    {
        method: 'feed',
        link: 'https://www.youtube.com/watch?v=cx_rqWj50IA',
        name: ley_,
        description: 'Si tu ley es la más votada, me comprometo a Gestionar su Desarrollo y Cumplimiento',
        caption: 'Sabías que tú puedes crear una LEY',
        action_type: 'og.likes',
        action_properties: JSON.stringify({
            object: 'https://www.youtube.com/watch?v=cx_rqWj50IA'
        })
    },
}
Daniel Corzo
  • 1,055
  • 2
  • 19
  • 32

0 Answers0