The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Width Widget

4 posters

Go down

Width Widget Empty Width Widget

Post by Arsalan3d June 27th 2013, 12:08 pm

Can anybody tell me how can i add this widht adjust widget in my forum

Width Widget Untitl15
Arsalan3d
Arsalan3d
Forumember

Male Posts : 55
Reputation : 1
Language : English, Hindi
Location : India

http://saudatricks.forummotion.com

Back to top Go down

Width Widget Empty Re: Width Widget

Post by levy June 27th 2013, 12:15 pm

Your forum url and where you found that script ?
levy
levy
Hyperactive

Male Posts : 2632
Reputation : 350
Language : English, Romanian
Location : Romania

https://portofolio.goodforum.net/

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Arsalan3d June 27th 2013, 5:35 pm

Arsalan3d
Arsalan3d
Forumember

Male Posts : 55
Reputation : 1
Language : English, Hindi
Location : India

http://saudatricks.forummotion.com

Back to top Go down

Width Widget Empty Re: Width Widget

Post by levy June 27th 2013, 6:01 pm

Code:
jQuery(document).ready(function(){



jQuery("#posaljiwidth").click(function(){
var a=eval(document.getElementById("selektwidth").value);
var b=0;
jQuery("table.bodylinewidth").animate({width:a},800, "linear");
if(a==1050){b=1;}
if(a==1100){b=2;}
if(a==1200){b=3;}
if(a==1300){b=4;}
setKuki('bodylinewidthkuki',b,365);
  });


});
</script>

<center><div style="text-align: center; font-size:10px;">Width:    <input type=submit id="posaljiwidth" value="Set">
<select id="selektwidth">
  <option selected>980</option>
  <option>1050</option>
  <option>1100</option>
  <option>1200</option>
  <option>1300</option>
</select>

Create new javascript and add this code
levy
levy
Hyperactive

Male Posts : 2632
Reputation : 350
Language : English, Romanian
Location : Romania

https://portofolio.goodforum.net/

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Arsalan3d June 27th 2013, 6:15 pm

Yes It Did But There Is Nothing Like As I asked For?
I Add This Code In Widget But Not Working
Arsalan3d
Arsalan3d
Forumember

Male Posts : 55
Reputation : 1
Language : English, Hindi
Location : India

http://saudatricks.forummotion.com

Back to top Go down

Width Widget Empty Re: Width Widget

Post by levy June 27th 2013, 6:50 pm

Code:
<script>jQuery(document).ready(function(){



jQuery("#posaljiwidth").click(function(){
var a=eval(document.getElementById("selektwidth").value);
var b=0;
jQuery("table.bodylinewidth").animate({width:a},800, "linear");
if(a==1050){b=1;}
if(a==1100){b=2;}
if(a==1200){b=3;}
if(a==1300){b=4;}
setKuki('bodylinewidthkuki',b,365);
  });


});
</script>

<center><div style="text-align: center; font-size:10px;">Width:    <input type=submit id="posaljiwidth" value="Set">
<select id="selektwidth">
  <option selected>980</option>
  <option>1050</option>
  <option>1100</option>
  <option>1200</option>
  <option>1300</option>
</select>

Try now , I missed something
levy
levy
Hyperactive

Male Posts : 2632
Reputation : 350
Language : English, Romanian
Location : Romania

https://portofolio.goodforum.net/

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Ultron's Vision June 27th 2013, 6:55 pm

Add these JavaScripts to a new Widget (Admin Panel -> Modules -> Portal & Widgets -> Forum Widget managements).

Code:

<script type="text/javascript">
function setKuki(c_name,value,exdays){var exdate=new Date();exdate.setDate(exdate.getDate()+exdays);var c_value=escape(value)+((exdays==null)?'':'; expires='+exdate.toUTCString());document.cookie=c_name+'='+c_value}

function getKuki(c_name){var i,x,y,ARRcookies=document.cookie.split(';');for(i=0;i<ARRcookies.length;i++){x=ARRcookies[i].substr(0,ARRcookies[i].indexOf('='));y=ARRcookies[i].substr(ARRcookies[i].indexOf('=')+1);x=x.replace(/^\s+|\s+$/g,'');if(x==c_name){return unescape(y)}}}

jQuery(document).ready(function(){

jQuery("#posaljiwidth").click(function(){
var a=eval(document.getElementById("selektwidth").value);
var b=0;
jQuery("table.bodylinewidth").animate({width:a},800, "linear");
if(a==1050){b=1;}
if(a==1100){b=2;}
if(a==1200){b=3;}
if(a==1300){b=4;}
setKuki('bodylinewidthkuki',b,365);
  });


});
</script>

<center><div style="text-align: center;"><input type=submit id="posaljiwidth" value="Set">
<select id="selektwidth">
  <option selected>980</option>
  <option>1050</option>
  <option>1100</option>
  <option>1200</option>
  <option>1300</option>
</select>
</div></center>
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Arsalan3d June 27th 2013, 7:09 pm

The Width Is Not Taking any action, It Might Be Because Of The Widget, It already have or Something?
Arsalan3d
Arsalan3d
Forumember

Male Posts : 55
Reputation : 1
Language : English, Hindi
Location : India

http://saudatricks.forummotion.com

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Ultron's Vision June 27th 2013, 7:29 pm

Are you using the script I provided and did you change anything?
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Arsalan3d June 28th 2013, 7:07 am

Yes, I am using the Script What You have posted But It's Not Working You Can Have a Look at My Forum http://saudatricks.forummotion.com
Arsalan3d
Arsalan3d
Forumember

Male Posts : 55
Reputation : 1
Language : English, Hindi
Location : India

http://saudatricks.forummotion.com

Back to top Go down

Width Widget Empty Re: Width Widget

Post by mangaka June 28th 2013, 7:15 am

Hello,

Try this:

Code:
<canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Text here</cufontext><cufon class="cufon cufon-canvas" alt="Forum " style="width: 38px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Text here</cufontext></cufon><cufon class="cufon cufon-canvas" alt="Options" style="width: 40px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>2nd text here</cufontext></cufon><span class="genmed  module-title"><cufon class="cufon cufon-canvas" alt="Forum " style="width: 38px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Forum </cufontext></cufon><cufon class="cufon cufon-canvas" alt="Options" style="width: 40px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Options</cufontext></cufon></span><td class="catLeft" height="25"><span class="genmed  module-title"><cufon class="cufon cufon-canvas" alt="Forum " style="width: 38px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Forum </cufontext></cufon><cufon class="cufon cufon-canvas" alt="Options" style="width: 40px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>2nd text here</cufontext></cufon></span></td><tr><td class="catLeft" height="25"><span class="genmed  module-title"><cufon class="cufon cufon-canvas" alt="Forum " style="width: 38px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Forum </cufontext></cufon><cufon class="cufon cufon-canvas" alt="Options" style="width: 40px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>2nd text here</cufontext></cufon></span></td></tr><tr><td class="row1" align="left"><script type="text/javascript">


jQuery(document).ready(function(){



jQuery("#posaljiwidth").click(function(){
var a=eval(document.getElementById("selektwidth").value);
var b=0;
jQuery("table.bodylinewidth").animate({width:a},800, "linear");
if(a==1050){b=1;}
if(a==1100){b=2;}
if(a==1200){b=3;}
if(a==1300){b=4;}
setKuki('bodylinewidthkuki',b,365);
  });


});
</script>

<center><div style="text-align: center; font-size:10px;">Width:    <input type="submit" id="posaljiwidth" value="Set">
<select id="selektwidth">
  <option selected="">980</option>
  <option>1050</option>
  <option>1100</option>
  <option>1200</option>
  <option>1300</option>
</select>
</div></center></td></tr><tbody><tr><td class="catLeft" height="25"><span class="genmed  module-title"><cufon class="cufon cufon-canvas" alt="Forum " style="width: 38px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Forum </cufontext></cufon><cufon class="cufon cufon-canvas" alt="Options" style="width: 40px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Options</cufontext></cufon></span></td></tr><tr><td class="row1" align="left"><script type="text/javascript">


jQuery(document).ready(function(){



jQuery("#posaljiwidth").click(function(){
var a=eval(document.getElementById("selektwidth").value);
var b=0;
jQuery("table.bodylinewidth").animate({width:a},800, "linear");
if(a==1050){b=1;}
if(a==1100){b=2;}
if(a==1200){b=3;}
if(a==1300){b=4;}
setKuki('bodylinewidthkuki',b,365);
  });


});
</script>

<center><div style="text-align: center; font-size:10px;">Width:    <input type="submit" id="posaljiwidth" value="Set">
<select id="selektwidth">
  <option selected="">980</option>
  <option>1050</option>
  <option>1100</option>
  <option>1200</option>
  <option>1300</option>
</select>
</div></center></td></tr></tbody><table class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0"><tbody><tr><td class="catLeft" height="25"><span class="genmed  module-title"><cufon class="cufon cufon-canvas" alt="Forum " style="width: 38px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Forum </cufontext></cufon><cufon class="cufon cufon-canvas" alt="Options" style="width: 40px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Options</cufontext></cufon></span></td></tr><tr><td class="row1" align="left"><script type="text/javascript">


jQuery(document).ready(function(){



jQuery("#posaljiwidth").click(function(){
var a=eval(document.getElementById("selektwidth").value);
var b=0;
jQuery("table.bodylinewidth").animate({width:a},800, "linear");
if(a==1050){b=1;}
if(a==1100){b=2;}
if(a==1200){b=3;}
if(a==1300){b=4;}
setKuki('bodylinewidthkuki',b,365);
  });


});
</script>

<center><div style="text-align: center; font-size:10px;">Width:    <input type="submit" id="posaljiwidth" value="Set">
<select id="selektwidth">
  <option selected="">980</option>
  <option>1050</option>
  <option>1100</option>
  <option>1200</option>
  <option>1300</option>
</select>
</div></center></td></tr></tbody></table><div style="height: 4px"></div>

Thanks Wink
mangaka
mangaka
Forumember

Female Posts : 121
Reputation : 5
Language : Indonesia
Location : Well

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Arsalan3d June 28th 2013, 7:28 am

Mangaka Your Script Is Pretty Much Messed, And It's Not Working Too :'(
Arsalan3d
Arsalan3d
Forumember

Male Posts : 55
Reputation : 1
Language : English, Hindi
Location : India

http://saudatricks.forummotion.com

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Ultron's Vision June 28th 2013, 8:48 am

Did you add the code in a new JavaScript page or as new Widget?

Also, try removing all scripts you've gotten here and theb replace it with the script I gave you.
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

Width Widget Empty Re: Width Widget

Post by mangaka June 28th 2013, 9:25 am

Arsalan3d wrote:Mangaka Your Script Is Pretty Much Messed, And It's Not Working Too :'(

Hhmm..My script was messed?Alright,alright.Here is the code:

Code:
<div style="height: 4px"></div>
<table class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0"><tbody><tr><td class="catLeft" height="25"><span class="genmed  module-title"><cufon class="cufon cufon-canvas" alt="Forum " style="width: 38px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Forum </cufontext></cufon><cufon class="cufon cufon-canvas" alt="Options" style="width: 40px; height: 15px;"><canvas width="46" height="17" style="width: 46px; height: 17px; top: 0px; left: 0px;"></canvas><cufontext>Options</cufontext></cufon></span></td></tr><tr><td class="row1" align="left"><script type="text/javascript">


jQuery(document).ready(function(){



jQuery("#posaljiwidth").click(function(){
var a=eval(document.getElementById("selektwidth").value);
var b=0;
jQuery("table.bodylinewidth").animate({width:a},800, "linear");
if(a==1050){b=1;}
if(a==1100){b=2;}
if(a==1200){b=3;}
if(a==1300){b=4;}
setKuki('bodylinewidthkuki',b,365);
  });


});
</script>

<center><div style="text-align: center; font-size:10px;">Width:    <input type="submit" id="posaljiwidth" value="Set">
<select id="selektwidth">
  <option selected="">980</option>
  <option>1050</option>
  <option>1100</option>
  <option>1200</option>
  <option>1300</option>
</select>
</div></center></td></tr></tbody></table>

This is a HTML code bwi
mangaka
mangaka
Forumember

Female Posts : 121
Reputation : 5
Language : Indonesia
Location : Well

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Ultron's Vision June 28th 2013, 9:35 am

@mangaka Appreciate it that you copy the source code from duelingcity, but the code won't work without the setKuki and the getKuki functions I provided. Well, at least not permanently.
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

Width Widget Empty Re: Width Widget

Post by Arsalan3d June 28th 2013, 1:05 pm

Bump
Arsalan3d
Arsalan3d
Forumember

Male Posts : 55
Reputation : 1
Language : English, Hindi
Location : India

http://saudatricks.forummotion.com

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum