Имею потребность в вызове Colorbox из текста страницы. Все найденные видео-уроки относятся к прикрепленным картинкам.
На родных example'ах есть примеры с вызовом из HTML через jscript.
<head>
<script>
$(document).ready(function(){
$("a[rel='example1']").colorbox();
});
$("#click").click(function(){
$('#click').css({"background-color":"#f00", "color":"#fff", "cursor":"inherit"}).text("Open this window again and this message will still be here.");
return false;
});
});
</script>
</head>
<body>
<p><a href="../content/ohoopee1.jpg" rel="example1" title="Me and my grandfather on the Ohoopee.">Grouped Photo 1</a></p>
</body>
<script>
$(document).ready(function(){
$("a[rel='example1']").colorbox();
});
$("#click").click(function(){
$('#click').css({"background-color":"#f00", "color":"#fff", "cursor":"inherit"}).text("Open this window again and this message will still be here.");
return false;
});
});
</script>
</head>
<body>
<p><a href="../content/ohoopee1.jpg" rel="example1" title="Me and my grandfather on the Ohoopee.">Grouped Photo 1</a></p>
</body>
Вопрос, какой нормальный вызов Colorbox из FullHTML?
Представляю, что можно вставить кусок скрипта в тему и вручную привязать "rel" к ссылке на картинку.
А диалоговые инструменты для вызова есть?
Комментарии
Для вызова colorbox-а главное условие, чтоб у элемента в классах было прописано "colorbox" в rel можно любую инфу пихать. по rel колорбокс групирует картинки.
Суперски! Пасибки!
Class'но работает!
Пожалуйста)