• Страница 1 из 1
  • 1
Модератор форума: dotbot  
Привязать ссылку к картинке
Madness6479
Сообщений: 25
Репутация: 0

Сообщение # 1 | 20:22:38
Сайт http://kadavrq1.ucoz.ru

Видите внизу четыре одинаковых картинки?Здесь вопрос.
Как сделать так,что бы при нажатии на на одну такую картинку пользователя кидало на указанный адрес?
P.S. как менять картинку и текст в ней я знаю.Не знаю лишь как прибить ссылку.
Как и гарантировал,прилагаю исходный код этого блока (зовется он ROTATOR)

Code
<!-- Rotator -->
<div class="rokintroscroller-container" style="position: relative; ">
<div id="isr_left" onclick="isr_left()" class="rokintroscroller-leftarrow" style="position: absolute; cursor: pointer; top: 83.5px; left: 0px; visibility: visible; zoom: 1; opacity: 1; "></div>
<div class="rokintroscroller-wrapper">
<div id="rokintroscroller" class="" style="width: 2835px; height: 178px; ">
<div style="display:none">
<div id="box1">
<div style="float: left;margin: 0px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
</div>
<div id="box2">
<div style="float: left;margin: 0px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
</div>
</div>
<div id="isr_outer" onmouseover="isr_hover_on()" onmouseout="isr_hover_off()">
<div id="middle_outer" style="height: 178px; width: 940px;">
<div id="isr_middle" style="height: 178px; width: 940px;">
<div style="float: left;margin: 0px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
</div>
</div>
</div>
<script type="text/javascript">
var isr_displaytime = 20000;
var isr_chrome;
</script>
<script language="javascript" type="text/javascript" src="/js/rotator.js"></script>
</div>
</div>
<div id="isr_right" onclick="isr_right()" class="rokintroscroller-rightarrow" style="position: absolute; cursor: pointer; top: 83.5px; right: 0px; visibility: visible; zoom: 1; opacity: 1; "></div>
</div>
<!-- /Rotator -->

http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg это и есть данная картинка,там же и текст выше можно поменять.А как привязать ссылку...
Сообщение отредактировал webanet - Воскресенье, 24 Июн 2012, 21:24:45
Rostislav
Сообщений: 2396
Репутация: 591

Сообщение # 2 | 21:01:14
Madness6479,

Quote (Madness6479)
Как сделать так,что бы при нажатии на на одну такую картинку пользователя кидало на указанный адрес?


Quote (Madness6479)
А как привязать ссылку...


Вот так:

Code
<a href="АДРЕС_ССЫЛКИ"><img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /></a>


wink

Madness6479
Сообщений: 25
Репутация: 0

Сообщение # 3 | 21:54:13
Умно,но не могли бы вы мне показать куда именно вставлять?Ну место что ли....
Deadshot
Сообщений: 412
Репутация: 524

Сообщение # 4 | 22:01:31
Madness6479, куда надо?
Если вы используете ВВ коды то учите html от тут . . .

Пум-пурум-пурум-пум-пум!
DIREN
Сообщений: 660
Репутация: 792

Сообщение # 5 | 22:30:43
Madness6479,
Quote (Madness6479)
<!-- Rotator -->
<div class="rokintroscroller-container" style="position: relative; ">
<div id="isr_left" onclick="isr_left()" class="rokintroscroller-leftarrow" style="position: absolute; cursor: pointer; top: 83.5px; left: 0px; visibility: visible; zoom: 1; opacity: 1; "></div>
<div class="rokintroscroller-wrapper">
<div id="rokintroscroller" class="" style="width: 2835px; height: 178px; ">
<div style="display:none">
<div id="box1">
<div style="float: left;margin: 0px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"><a href="АДРЕС_ССЫЛКИ"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /></a> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
</div>
<div id="box2">
<div style="float: left;margin: 0px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
</div>
</div>
<div id="isr_outer" onmouseover="isr_hover_on()" onmouseout="isr_hover_off()">
<div id="middle_outer" style="height: 178px; width: 940px;">
<div id="isr_middle" style="height: 178px; width: 940px;">
<div style="float: left;margin: 0px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
<div style="float: left;margin-left: 17px;position: relative;">
<div class="scroller-title" style="bottom: 23px;left: 5px;position: absolute;width: 212px;">
<h2 style="font-size: 120%;margin: 0px;padding: 8px 5px;text-align: center;">Ваш текст</h2>
</div>
<div class="feature-img-surround"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /> </div>
</div>
</div>
</div>
</div>
<script type="text/javascript">
var isr_displaytime = 20000;
var isr_chrome;
</script>
<script language="javascript" type="text/javascript" src="/js/rotator.js"></script>
</div>
</div>
<div id="isr_right" onclick="isr_right()" class="rokintroscroller-rightarrow" style="position: absolute; cursor: pointer; top: 83.5px; right: 0px; visibility: visible; zoom: 1; opacity: 1; "></div>
</div>
<!-- /Rotator -->


Вот вам более подробный пример!
Синим это ваши картинки... Красным код который нужно добавить чтоб картинки стали кликаберными.


Сайт пранка 18+ :)
Сообщение отредактировал DIREN - Воскресенье, 24 Июн 2012, 22:31:49
Madness6479
Сообщений: 25
Репутация: 0

Сообщение # 6 | 22:42:30
Все работает.Сделал.Но а как можно привязать уже не просто ссылку,а видео из yоutube например?
DIREN
Сообщений: 660
Репутация: 792

Сообщение # 7 | 22:46:20
Madness6479, подробнее...
Что именно хотим чтоб было? Текст вашего ответа должен начинаться так:
- "я хочу чтоб, кликая на картинку происходило..."


Сайт пранка 18+ :)
Madness6479
Сообщений: 25
Репутация: 0

Сообщение # 8 | 22:48:05
происходило переход на видео на ютюбе.

Ммм выглядит прям как у Джина по желанию :))
DIREN
Сообщений: 660
Репутация: 792

Сообщение # 9 | 22:50:36
Madness6479,

Quote (DIREN)
<div class="feature-img-surround"><a href="http://youtu.be/bevu7lKk9l4" target="_blank"> <img class="feature-img" alt="" src="http://kadavrq1.ucoz.ru/geforce-gtx-680-performance-revealed-1.jpg" /></a> </div>


target="_blank" - это код позволяющий открывать ссылку в новой вкладке(это чтоб ваш сайт не закрывался, а оставался открытым.Видео будет открыто в новой вкладке)


Сайт пранка 18+ :)
Сообщение отредактировал DIREN - Воскресенье, 24 Июн 2012, 22:54:00
Madness6479
Сообщений: 25
Репутация: 0

Сообщение # 10 | 23:07:46
Благодарю.Ну?а вы на сайте ужи заметили?возле поиска есть popup module.Как его активировать,ну шоб вспывало окошко...?
DIREN
Сообщений: 660
Репутация: 792

Сообщение # 11 | 23:17:33
Quote (Madness6479)
Ну?а вы на сайте ужи заметили?возле поиска есть popup module.Как его активировать,ну шоб вспывало окошко...?

тут я вас вообще не понял.


Сайт пранка 18+ :)
Madness6479
Сообщений: 25
Репутация: 0

Сообщение # 12 | 23:27:53
Опечатка.У меня на сайте http://kadavrq1.ucoz.ru/ ниже картинок,правее поиска есть надпись popup module.Вот как его активировать?
В коде что я давал в моем вопросе он есть прописан.
  • Страница 1 из 1
  • 1
Поиск:
Telegram
Будьте в курсе всех обновлений: подпишитесь на наш официальный Telegram-канал uCoz и задавайте вопросы в чате сообщества!