Как сделать что бы ....

Статус
В этой теме нельзя размещать новые ответы.

Vlad123

Проверенные
Сообщения
366
Реакции
274
Баллы
11,065
Как сделать что бы гостям (после того как они зайдут на форум) при клике в любом месте открывалась новая вкладка в который бы открылся тот сайт который я захочу? Но при 2 клике ничего не происходило.
 
Как сделать что бы гостям (после того как они зайдут на форум) при клике в любом месте открывалась новая вкладка в который бы открылся тот сайт который я захочу? Но при 2 клике ничего не происходило.
Посмотрите здесь:

Там уже и выберете подходящий для себя вариант.
 
Последнее редактирование:
Это называется clickunder. Могли бы так и назвать тему)

Этот код вставляйте перед </body>

Код:
<script type="text/javascript">
function xOpen(){
    var PW=self.window.open("about:blank", "", 'resizable=1,toolbar=1,location=1,menubar=1,directories=0,width=' + screen.availWidth + ',height=' + screen.availHeight + ',scrollbars=1');
    if (PW) {
        PW.blur();
        PW.InitR = function(e) {
            with (e) {
                Params = e.Params;
                Main = function(){
                    if (typeof window.mozPaintCount != "undefined"){
                        var x = window.open("about:blank"); x.close();
                    }
                    try { opener.window.focus(); }catch (err) { }
                    PW.location = 'http://google.com';
                };
                Main();
            }
        };
        try { PW.InitR(PW); }catch (err) { }
    }
    return PW;
}
function upop() {
  var topmost = document.createElement('div');
  var htmlelem = document.getElementsByTagName('html')[0];
  htmlelem.appendChild(topmost);
  topmost.id = 'topmost_r';
  topmost.style.width = (htmlelem.offsetWidth-5).toString() + 'px';
  topmost.style.height = htmlelem.offsetHeight.toString() + 'px';
  topmost.style.position = "absolute";
  topmost.style.top = "0px";
  topmost.style.left = "0px";
  topmost.style.zIndex = 9999999999;
  topmost.style.textAlign = 'center';
  topmost.onclick = xOpen;
}
upop();
</script>
 
Это называется clickunder. Могли бы так и назвать тему)
Ты думаешь я знал как это называется? :Acute1:

Это называется clickunder. Могли бы так и назвать тему)

Этот код вставляйте перед </body>

Код:
<script type="text/javascript">
function xOpen(){
    var PW=self.window.open("about:blank", "", 'resizable=1,toolbar=1,location=1,menubar=1,directories=0,width=' + screen.availWidth + ',height=' + screen.availHeight + ',scrollbars=1');
    if (PW) {
        PW.blur();
        PW.InitR = function(e) {
            with (e) {
                Params = e.Params;
                Main = function(){
                    if (typeof window.mozPaintCount != "undefined"){
                        var x = window.open("about:blank"); x.close();
                    }
                    try { opener.window.focus(); }catch (err) { }
                    PW.location = 'http://google.com';
                };
                Main();
            }
        };
        try { PW.InitR(PW); }catch (err) { }
    }
    return PW;
}
function upop() {
  var topmost = document.createElement('div');
  var htmlelem = document.getElementsByTagName('html')[0];
  htmlelem.appendChild(topmost);
  topmost.id = 'topmost_r';
  topmost.style.width = (htmlelem.offsetWidth-5).toString() + 'px';
  topmost.style.height = htmlelem.offsetHeight.toString() + 'px';
  topmost.style.position = "absolute";
  topmost.style.top = "0px";
  topmost.style.left = "0px";
  topmost.style.zIndex = 9999999999;
  topmost.style.textAlign = 'center';
  topmost.onclick = xOpen;
}
upop();
</script>
в каком шаблоне?
 
Тема офф. В следующий раз за подобное название для тем, буду выписывать предупреждение. Читаем правила.
 
Статус
В этой теме нельзя размещать новые ответы.
Современный облачный хостинг провайдер | Aéza
Назад
Сверху Снизу