Skip to content

Instantly share code, notes, and snippets.

@reinaldob
Created July 4, 2014 13:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save reinaldob/29af5ed2d7bcb8025100 to your computer and use it in GitHub Desktop.
Save reinaldob/29af5ed2d7bcb8025100 to your computer and use it in GitHub Desktop.
module ConcursoCulturalVideoVagas
module VideosHelper
def botao_add_to_page
url_da_app = "#{FACEBOOK_CONFIG['facebook_url']}"
app_id = FACEBOOK_CONFIG['app_id']
"<div style='margin: 15px'>
<h3>App Concurso Cultural</h3>
<br/>
<br/>
<a class='btn' href='#' onclick=\"top.location.href='http://www.facebook.com/dialog/pagetab?app_id=#{app_id}&redirect_uri=#{url_da_app}';\">Instala a Tab</a></div>"
end
def eh_adm
@signed_request && @signed_request["page"] && @signed_request["page"]["admin"]
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment