Skip to content

Instantly share code, notes, and snippets.

@shrutis22
Last active Jul 15, 2016
Embed
What would you like to do?
The News page which will be displayed as an inline VF page in Account detail page.
<apex:page standardController="Account" extensions="NewsWidgetController" sidebar="false" showHeader="false" standardStylesheets="false" applyHtmlTag="false" applyBodyTag="false" docType="html-5.0" >
<html>
<head>
<title>
Google News
</title>
</head>
<body>
<div width="100%" style="text-align:center" >
<img src="{!$Resource.News_Loading}" id="loader"></img>
</div>
<div id="news">
</div>
<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/jquery/2.2.1/jquery.min.js"></script>
<script type="text/javascript" src="{!$Resource.GoogleNewsJS}"></script>
<script type="text/javascript">
$( document ).ready (
function() {
getNews( encodeURIComponent( "{!Account.Name}" ) );
}
);
</script>
</body>
</html>
</apex:page>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment