What's new
try
{
GupShup.html.util.showElement("adModule1",false);
GupShup.html.util.overlay(document.getElementById("adModuleholder1_RIGHT"),document.getElementById("adModule1"),"left", 0, 0);
}
catch(error)
{
if (GupShup.conf.jsDebug)
alert('Could not process ad module 1 : error-' + error);
}
Browse by Categories
All ·
/* To create a template placeholder map.
* 1. Create a top level object template.
* 2. This top level object contains an array with one entry for each placeholder in the template
* 3. Each entry for a placeholder has two members:
* - tmplKey: Identifies the regular expression used in the template
* - tmplMap: Identifies the member object in the JSON object which should replace the template placeholder.
*/
function getTmplPlaceHolderMap()
{
var placeHolderMap = new Array();
placeHolderMap[0] = new Object();
placeHolderMap[0].key = "http://resource.smsgupshup.com/webimages/$CAT_PAGE_URL$.html";
placeHolderMap[0].dataMember = "catHREF";
placeHolderMap[1] = new Object();
placeHolderMap[1].key = "$CAT_NAME$";
placeHolderMap[1].dataMember = "catName";
return placeHolderMap;
}
function extractCatDataObjects(categoryList, start, limit)
{
var catArr = new Array();
var j = 0;
for(var i=start; i <= limit; i++)
{
var entry = new Object();
entry.catHREF = '/categories' + '/' + categoryList[i].name;
entry.catName = categoryList[i].displayName;
catArr[j++] = entry;
}
return catArr;
}
function catListJsp_process()
{
var featuredCatListJson = '/*-secure-{"params":{"limit":-1,"start":0,"type":"ALL_CATEGORIES","getAll":"false","needTotalForPg":false},"message":"","categories":[{"featuredRank":1,"url":"http://www.smsgupshup.com/categories/Business","status":"ENABLED","name":"Business","id":3,"displayName":"Business"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Clubs & Organizations","status":"ENABLED","name":"Clubs &#38; Organizations","id":24,"displayName":"Clubs &#38; Organizations"},{"featuredRank":1,"url":"http://www.smsgupshup.com/categories/Education & Campus","status":"ENABLED","name":"Education &#38; Campus","id":4,"displayName":"Education &#38; Campus"},{"featuredRank":1,"url":"http://www.smsgupshup.com/categories/Entertainment","status":"ENABLED","name":"Entertainment","id":5,"displayName":"Entertainment"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Events & Parties","status":"ENABLED","name":"Events &#38; Parties","id":19,"displayName":"Events &#38; Parties"},{"featuredRank":1,"url":"http://www.smsgupshup.com/categories/Finance","status":"ENABLED","name":"Finance","id":6,"displayName":"Finance"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Food & Drinks","status":"ENABLED","name":"Food &#38; Drinks","id":23,"displayName":"Food &#38; Drinks"},{"featuredRank":1,"url":"http://www.smsgupshup.com/categories/Health","status":"ENABLED","name":"Health","id":8,"displayName":"Health"},{"featuredRank":1,"url":"http://www.smsgupshup.com/categories/Jobs","status":"ENABLED","name":"Jobs","id":10,"displayName":"Jobs"},{"featuredRank":1,"url":"http://www.smsgupshup.com/categories/Jokes","status":"ENABLED","name":"Jokes","id":11,"displayName":"Jokes"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Movies & TV","status":"ENABLED","name":"Movies &#38; TV","id":12,"displayName":"Movies &#38; TV"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Music","status":"ENABLED","name":"Music","id":13,"displayName":"Music"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/News & Politics","status":"ENABLED","name":"News &#38; Politics","id":14,"displayName":"News &#38; Politics"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/People & Blogs","status":"ENABLED","name":"People &#38; Blogs","id":26,"displayName":"People &#38; Blogs"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Romance","status":"ENABLED","name":"Romance","id":25,"displayName":"Romance"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Shopping & Deals","status":"ENABLED","name":"Shopping &#38; Deals","id":21,"displayName":"Shopping &#38; Deals"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Spirituality","status":"ENABLED","name":"Spirituality","id":20,"displayName":"Spirituality"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Sports","status":"ENABLED","name":"Sports","id":17,"displayName":"Sports"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Technology","status":"ENABLED","name":"Technology","id":16,"displayName":"Technology"},{"featuredRank":0,"url":"http://www.smsgupshup.com/categories/Travel & Lifestyle","status":"ENABLED","name":"Travel &#38; Lifestyle","id":22,"displayName":"Travel &#38; Lifestyle"}],"status":"SUCCESS","errorCode":"NO_ERROR"}*/';
if (GupShup.util.isInitialized(GupShup.conf.currentModule))
{
if (GupShup.util.trim(GupShup.conf.currentModule.refreshUrl) == '')
{
GupShup.conf.currentModule.refreshUrl
= GupShup.conf.readUrl + "&type=" + 'ALL_CATEGORIES'
+ '&getAll=false&needTotalForPg=false';
}
else
{
featuredCatListJson = GupShup.conf.currentModule.refreshArgs;
}
}
var featuredCatList = GupShup.util.getJsonFromResponse(featuredCatListJson);
if((typeof(featuredCatList.status) != 'undefined') && (featuredCatList.status == 'SUCCESS') && (featuredCatList.categories.length > 0))
{
var categoryList = featuredCatList.categories;
var tmplPlaceHolderMap = getTmplPlaceHolderMap();
var limit = ((categoryList.length < 200)? categoryList.length : 200);
/* Expand all the data objects, except the last, in the first template. */
var tmplDataObjArr = extractCatDataObjects(categoryList, 0, (limit - 2));
GupShup.util.expandTemplateInDiv("catEntrySpanRIGHT", "catEntryTemplateRIGHT", tmplPlaceHolderMap, tmplDataObjArr);
/* Expand the last entry in the second template. */
tmplDataObjArr = extractCatDataObjects(categoryList, (limit - 1), (limit - 1));
GupShup.util.expandTemplateInDiv("catLastEntrySpanIdRIGHT", "catLastEntryTemplateRIGHT", tmplPlaceHolderMap, tmplDataObjArr);
}
}
try
{
catListJsp_process();
}
catch(error)
{
if (GupShup.conf.jsDebug)
alert('Could not process catListJsp module : error-' + error);
}
$POSTS_COUNT$ posts, $SUBSCRIBER_COUNT$ members
Popular Groups
function popularGroupsJsp_process()
{
var jsonStr = '{"params":{"showLatestMessage":false,"limit":5,"start":0,"catId":"-1","type":"GLOBAL_POPULAR","showLatestMsg":"false","fromDays":15,"orientation":"RIGHT","newPageParams":"","newPage":"LOGIN","needTotalForPg":false,"showAll":"false"},"message":"","status":"SUCCESS","entities":[{"isDefault":"false","totalSubscribers":1707,"imageUrl":"http://resource2.smsgupshup.com/webimages/images/channels/4.3.0.76849.gif","totalPosts":349,"userId":10893900,"isPremium":false,"isPrivate":false,"id":10931517,"description":"JOIN MY GROUP AND ENJOY FREE SHAYRIS&#46;THIS GROUP IS ONLY FOR SHAYRIS&#46;GUARANTEED ENJOYMENT&#46;HERE U WILL GET SHAYRIS OF EVERY TYPE&#46;TELL YOUR FRIENDS TO JOIN BY SMS &#34;JOIN SHAYRI&#95;HUMTUM&#34; to 567673434 ","groupUrl":"http://www.smsgupshup.com/groups/SHAYRI_HUMTUM","name":"SHAYRI&#95;HUMTUM","isPartner":false,"orgName":"SHAYRI_HUMTUM"},{"isDefault":"false","totalSubscribers":399,"imageUrl":"http://resource.smsgupshup.com/webimages/entity/12/979/12979891_1226751351027.png","totalPosts":44,"userId":11028437,"isPremium":false,"isPrivate":false,"id":12979891,"description":"Latest tips and tricks 4 ur mobile ","groupUrl":"http://www.smsgupshup.com/groups/Mobi_tricks","name":"Mobi&#95;tricks","isPartner":false,"orgName":"Mobi_tricks"},{"isDefault":"false","totalSubscribers":44662,"imageUrl":"http://resource.smsgupshup.com/webimages/entity/2/583/2583871_1214341818104.png","totalPosts":774,"userId":2583895,"isPremium":false,"isPrivate":false,"id":2583871,"description":"This GROUP Specially for Funny sms Now This Group is NO1 Joke Group of Gupshup JOKES msg JOIN this group and get 4 msg daily ","groupUrl":"http://www.smsgupshup.com/groups/BHARGAVA","name":"BHARGAVA","isPartner":false,"orgName":"BHARGAVA"},{"isDefault":"false","totalSubscribers":1149,"imageUrl":"http://resource.smsgupshup.com/webimages/entity/8/330/8330965_1223392857491.png","totalPosts":406,"userId":8317107,"isPremium":false,"isPrivate":false,"id":8330965,"description":" ","groupUrl":"http://www.smsgupshup.com/groups/PPBnews","name":"PPBnews","isPartner":false,"orgName":"PPBnews"},{"isDefault":"false","totalSubscribers":3169,"imageUrl":"http://resource2.smsgupshup.com/webimages/entity/12/162/12162421_1225275672330.png","totalPosts":230,"userId":10486101,"isPremium":false,"isPrivate":false,"id":12162421,"description":"For daily sexy jokes&#44;shayri&#44;sms&#58; JOIN Sexyhungama to 567678 for daily veg joks&#44;shari&#44;sms&#58; JOIN RONANCEMASTI to 567678 for frndsip wid me ","groupUrl":"http://www.smsgupshup.com/groups/Sexyhungama","name":"Sexyhungama","isPartner":false,"orgName":"Sexyhungama"}],"errorCode":"NO_ERROR","urchinUrl":"/index/weekly_popular?page=1"}';
if (GupShup.util.isInitialized(GupShup.conf.currentModule))
{
if (GupShup.util.trim(GupShup.conf.currentModule.refreshUrl) == '')
{
GupShup.conf.currentModule.refreshUrl
= GupShup.conf.readUrl + "&type=" + 'GLOBAL_POPULAR'
+ '&showLatestMsg=false' + '&showAll=false' + '&fromDays=' + '15'
+ '&start=0' + '&limit=' + '5' + '&needTotalForPg=false';
}
else
{
featuredCatListJson = GupShup.conf.currentModule.refreshArgs;
}
}
var popularGroups = GupShup.util.getJsonFromResponse(jsonStr);
if((typeof(popularGroups.status) != 'undefined') && (popularGroups.status == 'SUCCESS') && (popularGroups.entities.length > 0))
{
var map =
[
{key:'http://resource2.smsgupshup.com/webimages/$GROUP_IMG_SRC$.jpg', dataMember:'imageUrl'},
{key:'$GROUP_NAME$', dataMember:'name'},
{key:'http://resource2.smsgupshup.com/webimages/$GROUP_PAGE_URL$.jpg', dataMember:'groupUrl'},
{key:'$POSTS_COUNT$', dataMember:'totalPosts'},
{key:'$SUBSCRIBER_COUNT$', dataMember:'totalSubscribers'}
];
GupShup.util.expandTemplateInDiv('popularGroupsContainerRIGHT', 'popularGroupsTemplateRIGHT', map, popularGroups.entities);
}
}
try
{
popularGroupsJsp_process();
}
catch(error)
{
if (GupShup.conf.jsDebug)
alert('Could not process popularGroups module : error-' + error);
}
try
{
GupShup.html.util.showElement("adModule2",false);
GupShup.html.util.overlay(document.getElementById("adModuleholder2_RIGHT"),document.getElementById("adModule2"),"left", 0, 0);
}
catch(error)
{
if (GupShup.conf.jsDebug)
alert('Could not process ad module 2 : error-' + error);
}
var innerScriptDiv = "";
var innerScriptText = "";
var orientation = "RIGHT";
var modules = GupShup.conf[orientation + '_Modules'] = new Array();
GupShup.conf.currentModule = modules[0] = {name : 'whatsNew.jsp', rank : 0,
orientation : 'right', refreshUrl : '', refreshArgs : ''};
GupShup.html.dynamicBar.executeJavaScript('whatsNew.jsp_RIGHT_javaScript');
GupShup.conf.currentModule = modules[1] = {name : 'adModule1.jsp', rank : 1,
orientation : 'right', refreshUrl : '', refreshArgs : ''};
GupShup.html.dynamicBar.executeJavaScript('adModule1.jsp_RIGHT_javaScript');
GupShup.conf.currentModule = modules[2] = {name : 'popularCat.jsp', rank : 2,
orientation : 'right', refreshUrl : '', refreshArgs : ''};
GupShup.html.dynamicBar.executeJavaScript('popularCat.jsp_RIGHT_javaScript');
GupShup.conf.currentModule = modules[3] = {name : 'popularGroups.jsp', rank : 3,
orientation : 'right', refreshUrl : '', refreshArgs : ''};
GupShup.html.dynamicBar.executeJavaScript('popularGroups.jsp_RIGHT_javaScript');
GupShup.conf.currentModule = modules[4] = {name : 'adModule2.jsp', rank : 4,
orientation : 'right', refreshUrl : '', refreshArgs : ''};
GupShup.html.dynamicBar.executeJavaScript('adModule2.jsp_RIGHT_javaScript');
GupShup.conf.currentModule = null;
|


