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.

i need to change the position of this code

3 posters

Go down

Solved i need to change the position of this code

Post by Michael_vx 22/3/2014, 00:01

i need to change the position of this code the code right now is apper on the Top right i want to place to any where else like before the fotter or in a box and not the top of the page

Code:
$("head").append('<link rel="stylesheet" type="text/css" id="tstyle" />');

    if(my_getcookie("sstyle")) { $("#tstyle").attr("href", my_getcookie('sstyle')); }

    function addstyle(nom,lien) { $("#sstyle").append('<option value="'+lien+'">'+nom+'</option>'); }

    $(function(){

      $("#frame_chatbox").load(function(){
        $("#frame_chatbox").contents().find("head").append($("#tstyle").clone());
      });

      $("iframe[name=smilies]").load(function(){
        $("iframe[name=smilies]").contents().find("head").append($("#tstyle").clone()).append('<style type="text/css">body{margin:100!important;}</style>');
      });

      $("body").prepend('<select id="sstyle" onChange="my_setcookie(\'sstyle\',$(\'#tstyle\')[0].href=this.value,1,0);$(\'#frame_chatbox,iframe[name=smilies]\').contents().find(\'#tstyle\').attr(\'href\',this.value);this.selectedIndex=0;"><option>اختر ستايل</option></select>');

      addstyle("ابيض جميل","http://micsoft.xp3.biz/css/anime-rose.css");
      addstyle("اصفر رائع","http://micsoft.xp3.biz/css/dangan-ronpa.css");
      addstyle("وردى مميز","http://micsoft.xp3.biz/css/karneval.css");
      addstyle("احمر ممتاز","http://micsoft.xp3.biz/css/chihayafuru.css");
      addstyle("بنفسجى قاتم","http://micsoft.xp3.biz/css/blast-of-tempest.css");
      addstyle("نيلى جميل","http://www.anime-rose.com/vb/anime-rose_color/senyuu.css");
      addstyle("برتقالى تحفة","http://www.anime-rose.com/vb/anime-rose_color/kuroko-no-basuke.css");
      addstyle("اخضر فاتح","http://www.anime-rose.com/vb/anime-rose_color/uta-no-prince-sama-maji-love.css");
      addstyle("ستايل مميز","http://www.anime-rose.com/vb/anime-rose_color/rdg.css");
      addstyle("الغاء الاستايل","");

    });


Last edited by Michael_vx on 22/3/2014, 08:34; edited 1 time in total
Michael_vx
Michael_vx
Forumember

Male Posts : 664
Reputation : 29
Language : Arabic and some English
Location : Egypt

Back to top Go down

Solved Re: i need to change the position of this code

Post by Michael_vx 22/3/2014, 07:45

hello is any one here can find the way to change the box place ?
i need to make that code apper before footer not the top right
Michael_vx
Michael_vx
Forumember

Male Posts : 664
Reputation : 29
Language : Arabic and some English
Location : Egypt

Back to top Go down

Solved Re: i need to change the position of this code

Post by Ange Tuteur 22/3/2014, 08:30

Hello Michael_vx,

Try this :
Code:
   $("head").append('<link rel="stylesheet" type="text/css" id="tstyle" />');

        if(my_getcookie("sstyle")) { $("#tstyle").attr("href", my_getcookie('sstyle')); }

        function addstyle(nom,lien) { $("#sstyle").append('<option value="'+lien+'">'+nom+'</option>'); }

        $(function(){

          $("#frame_chatbox").load(function(){
            $("#frame_chatbox").contents().find("head").append($("#tstyle").clone());
          });

          $("iframe[name=smilies]").load(function(){
            $("iframe[name=smilies]").contents().find("head").append($("#tstyle").clone()).append('<style type="text/css">body{margin:100!important;}</style>');
          });

          $("body").append('<select id="sstyle" onChange="my_setcookie(\'sstyle\',$(\'#tstyle\')[0].href=this.value,1,0);$(\'#frame_chatbox,iframe[name=smilies]\').contents().find(\'#tstyle\').attr(\'href\',this.value);this.selectedIndex=0;"><option>اختر ستايل</option></select>');

          addstyle("ابيض جميل","http://micsoft.xp3.biz/css/anime-rose.css");
          addstyle("اصفر رائع","http://micsoft.xp3.biz/css/dangan-ronpa.css");
          addstyle("وردى مميز","http://micsoft.xp3.biz/css/karneval.css");
          addstyle("احمر ممتاز","http://micsoft.xp3.biz/css/chihayafuru.css");
          addstyle("بنفسجى قاتم","http://micsoft.xp3.biz/css/blast-of-tempest.css");
          addstyle("نيلى جميل","http://www.anime-rose.com/vb/anime-rose_color/senyuu.css");
          addstyle("برتقالى تحفة","http://www.anime-rose.com/vb/anime-rose_color/kuroko-no-basuke.css");
          addstyle("اخضر فاتح","http://www.anime-rose.com/vb/anime-rose_color/uta-no-prince-sama-maji-love.css");
          addstyle("ستايل مميز","http://www.anime-rose.com/vb/anime-rose_color/rdg.css");
          addstyle("الغاء الاستايل","");

        });

If it is not what you wanted, then please provide a link to your forum.

Thanks.
Ange Tuteur
Ange Tuteur
Forumaster

Male Posts : 13246
Reputation : 3000
Language : English & 日本語
Location : Pennsylvania

https://fmdesign.forumotion.com

Back to top Go down

Solved Re: i need to change the position of this code

Post by Michael_vx 22/3/2014, 08:33

thanks for the great help
now its where i want it to be thanks so much
Michael_vx
Michael_vx
Forumember

Male Posts : 664
Reputation : 29
Language : Arabic and some English
Location : Egypt

Back to top Go down

Solved Re: i need to change the position of this code

Post by SLGray 22/3/2014, 08:34

Is this solved?

To all members, please reply if your issues/question has been solved/answered.


i need to change the position of this code Slgray10

When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
SLGray
SLGray
Administrator
Administrator

Male Posts : 51489
Reputation : 3519
Language : English
Location : United States

https://forumsclub.com/gc/128-link-directory/

Back to top Go down

Solved Re: i need to change the position of this code

Post by Michael_vx 22/3/2014, 08:35

solved
Michael_vx
Michael_vx
Forumember

Male Posts : 664
Reputation : 29
Language : Arabic and some English
Location : Egypt

Back to top Go down

Solved Re: i need to change the position of this code

Post by SLGray 22/3/2014, 08:39

Thanks.

Problem solved & topic archived.


i need to change the position of this code Slgray10

When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
SLGray
SLGray
Administrator
Administrator

Male Posts : 51489
Reputation : 3519
Language : English
Location : United States

https://forumsclub.com/gc/128-link-directory/

Back to top Go down

Back to top

- Similar topics

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