Ist kein weiteres JS vorhanden. Und auch nach nochmaligem längeren Probieren funktioniert es nicht.
Gibt es denn keine "Schritt für Schritt" Anleitung?
chgallery und pmkslimbox zum Laufen bringen
So, jetzt habe ich eine komplett leere Typo3-Seite erstellt, also nur die Slimbox zum probieren eingefügt. Funktioniert wieder nicht. Hier mal der Quelltext der ausgegeben wird:
<!DOCTYPE html
PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<!--
This website is brought to you by TYPO3 - get.content.right
TYPO3 is a free open source Content Management Framework created by Kasper Skaarhoj and licensed under GNU/GPL.
TYPO3 is copyright 1998-2005 of Kasper Skaarhoj. Extensions are copyright of their respective owners.
Information and contribution at http://www.typo3.com
-->
<title>Homepage</title>
<meta name="generator" content="TYPO3 3.8 CMS" />
<script type="text/javascript">
/*<![CDATA[*/
<!--
browserName = navigator.appName;
browserVer = parseInt(navigator.appVersion);
var msie4 = (browserName == "Microsoft Internet Explorer" && browserVer >= 4);
if ((browserName == "Netscape" && browserVer >= 3) || msie4 || browserName=="Konqueror" || browserName=="Opera") {version = "n3";} else {version = "n2";}
// Blurring links:
function blurLink(theObject) { //
if (msie4) {theObject.blur();}
}
// -->
/*]]>*/
</script>
<link rel="stylesheet" href="typo3conf/ext/chgallery/res/gallery.css" type="text/css" />
</head>
<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td bgcolor="#009900"> </td>
<td width="50%" bgcolor="#CC0000"><a name="4"></a>
<!--
BEGIN: Content of extension "chgallery", plugin "tx_chgallery_pi1"
-->
<div class="tx-chgallery-pi1">
<!--<span class="links"><a href="index.php?id=1&no_cache=1&tx_chgallery_pi1[single]=1">Page 1</a></span> start -->
<div class="pagebrowser">
<div class="prev"> </div>
<div class="text"><span class="result">Page <span class="chgcurrent">1</span> of <span class="chgtotal">1</span></span></div>
<div class="next"></div>
<div class="clr"></div>
</div>
<!--<span class="links"><a href="index.php?id=1&no_cache=1&tx_chgallery_pi1[single]=1">Page 1</a></span> end -->
<div class="single" >
<div class="img">
<div class="align">
<a href="showpic.php?file=fileadmin%2Fuser_upload%2Ftestbilder%2Fimage-1.jpg&md5=eba25fb27a2cbdfb558d24a711c60d4e" target="thePicture"><img src="typo3temp/pics/db324da611.jpg" width="139" height="104" border="0" alt="bild1" title="bild1" /></a>
</div>
</div>
<span>bild1 <!-- 1 --><small>49 Kb</small><!-- 1 --></span>
</div>
<div class="single" >
<div class="img">
<div class="align">
<a href="showpic.php?file=fileadmin%2Fuser_upload%2Ftestbilder%2Fimage-2.jpg&md5=cf91b6e9cdac7f278a57d59982b0773d" target="thePicture"><img src="typo3temp/pics/a0afd5cd58.jpg" width="139" height="104" border="0" alt="bild2" title="bild2" /></a>
</div>
</div>
<span>bild2 <!-- 1 --><small>46 Kb</small><!-- 1 --></span>
</div>
<div class="single" >
<div class="img">
<div class="align">
<a href="showpic.php?file=fileadmin%2Fuser_upload%2Ftestbilder%2Fimage-3.jpg&md5=9539558f5ea0b8bb25e0099e69d08196" target="thePicture"><img src="typo3temp/pics/6f6276f7c1.jpg" width="139" height="104" border="0" alt="bild3" title="bild3" /></a>
</div>
</div>
<span>bild3 <!-- 1 --><small>47 Kb</small><!-- 1 --></span>
</div>
<div class="clr"></div>
<!--<span class="links"><a href="index.php?id=1&no_cache=1&tx_chgallery_pi1[single]=1">Page 1</a></span> start -->
<div class="pagebrowser">
<div class="prev"> </div>
<div class="text"><span class="result">Page <span class="chgcurrent">1</span> of <span class="chgtotal">1</span></span></div>
<div class="next"></div>
<div class="clr"></div>
</div>
<!--<span class="links"><a href="index.php?id=1&no_cache=1&tx_chgallery_pi1[single]=1">Page 1</a></span> end -->
</div>
<!-- END: Content of extension "chgallery", plugin "tx_chgallery_pi1" -->
<img src="clear.gif" width="1" height="10" border="0" class="spacer-gif" alt="" title="" /><br /></td>
<td bgcolor="#0000FF"> </td>
</tr>
</table>
</body>
</html>
Ich sehe hier kein Slimbox JS, welches eingebunden wurde!
Gruß
Michael
Ich habe die Slimbox bei Include static (from extensions): eingebunden. Anschließend auch den Cache geleert. Was muss ich denn machen damit das JS der Slimbox eingebunden wird?
Folgende Extensions sind installiert:
chgallery 2.5.0
pmkslimbox 3.1.0
rgfolderselector 0.0.3
Das ist schon richtig so, aber anscheinend wird das evt. irgendwie wieder überschrieben oder ist nicht für den Bereich Deiner Galerie gültig. Irgendwo hängt's also noch.
Das muss im header auftauchen, sonst geht da nichts:
<link rel="stylesheet" href="typo3conf/ext/pmkslimbox/res/styles/slimbox.css" type="text/css" media="screen" />
<script type="text/javascript" src="typo3temp/javascript_0b12553063.js"></script>
<script type="text/javascript" src="typo3conf/ext/pmkslimbox/res/scripts/mootools-1.2.1.js"></script>
<script type="text/javascript" src="typo3conf/ext/pmkslimbox/res/scripts/slimbox.js"></script>
<script type="text/javascript">
/*<![CDATA[*/
<!--
Slimbox.scanPage = function() {var links = $$("a").filter(function(el) {return el.rel && el.rel.test(/^lightbox/i);});$$(links).slimbox({resizeDuration: 400, resizeTransition: Fx.Transitions.Sine.easeInOut, opacity: 0.8, opacityDuration: 500, loop: 1, initialWidth: 250, initialHeight: 250, animateCaption: 1, showCounter: 1,counterText: 'Seite {x} von {y}', psScriptPath: 'typo3conf/ext/pmkslimbox/savefile.php'}, null, function(el) {return (this == el) || ((this.rel.length > 8-) && (this.rel == el.rel));});};window.addEvent("domready", Slimbox.scanPage);
// -->
/*]]>*/
</script>
Gruß
Michael
Hallo,
jetzt sieht der Code im HEAD-Bereich so aus, aber das gleiche Spiel, es öffnet sich nur ein weiteres Fenster:
<!DOCTYPE html
PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<!--
This website is brought to you by TYPO3 - get.content.right
TYPO3 is a free open source Content Management Framework created by Kasper Skaarhoj and licensed under GNU/GPL.
TYPO3 is copyright 1998-2005 of Kasper Skaarhoj. Extensions are copyright of their respective owners.
Information and contribution at http://www.typo3.com
-->
<title>Homepage</title>
<meta name="generator" content="TYPO3 3.8 CMS" />
<script type="text/javascript">
/*<![CDATA[*/
<!--
browserName = navigator.appName;
browserVer = parseInt(navigator.appVersion);
var msie4 = (browserName == "Microsoft Internet Explorer" && browserVer >= 4);
if ((browserName == "Netscape" && browserVer >= 3) || msie4 || browserName=="Konqueror" || browserName=="Opera") {version = "n3";} else {version = "n2";}
// Blurring links:
function blurLink(theObject) { //
if (msie4) {theObject.blur();}
}
// -->
/*]]>*/
</script>
<script type="text/javascript" src="typo3conf/ext/pmkslimbox/res/scripts/mootools-1.2.1.js"></script>
<script type="text/javascript" src="typo3conf/ext/pmkslimbox/res/scripts/slimbox.js"></script>
<script type="text/javascript">
/*<![CDATA[*/
<!--
Slimbox.scanPage = function() {var links = $$("a").filter(function(el) {return el.rel && el.rel.test(/^lightbox/i);});$$(links).slimbox({resizeDuration: 400, resizeTransition: Fx.Transitions.Sine.easeInOut, opacity: 0.8, opacityDuration: 500, loop: 1, initialWidth: 250, initialHeight: 250, animateCaption: 1, showCounter: 1, defaultIframeWidth: {$plugin.pmkslimbox.defaultIframeWidth}, defaultIframeHeight: {$plugin.pmkslimbox.defaultIframeHeight}, iframeScrolling: '{$plugin.pmkslimbox.iframeScrolling}', enablePrintButton: 0, enableSaveButton: 0,counterText: 'Page {x} of {y}', psScriptPath: 'typo3conf/ext/pmkslimbox/savefile.php'}, null, function(el) {return (this == el) || ((this.rel.length > 8-) && (this.rel == el.rel));});};window.addEvent("domready", Slimbox.scanPage);
// -->
/*]]>*/
</script>
<link rel="stylesheet" href="typo3conf/ext/chgallery/res/gallery.css" type="text/css" />
</head>
Vielleicht kann mir ja jeamnd mal eine TS-Konfiguration einer funktionierenden Installation zeigen.
Ist eigentlich diser Pfad in der Ausgabe richtig?
<a href="showpic.php?file=fileadmin%2Fuser_upload%2Ftestbilder%2Fimage-1.jpg&md5=eba25fb27a2cbdfb558d24a711c60d4e" target="thePicture"><img src="typo3temp/pics/db324da611.jpg" width="139" height="104" border="0" alt="Bild 4" title="Bild 4" /></a>
Diese "showpic.php" finde ich etwas blöd.
So, letzter Versuch meinerseits das Ding zum Laufen zu bringen.
Habe jetzt eine komplett neue Typo3-Installation geschaffen mit folgenden Versionen:
Typo3 4.2.4
chgallery 2.1.1
pmkslimbox 2.3.2
Mein TS:
# TS Code
plugin.tx_chgallery_pi1 {
gallery.image {
file {
maxW = 139
maxH = 110
}
imageLinkWrap = 1
imageLinkWrap {
enable = 1
typolink {
title.field= tx_chgalleryTitle
parameter.override.cObject = IMG_RESOURCE
parameter.override.cObject.file.import.data = TSFE:lastImageInfo|origFile
parameter.override.cObject.file.maxW = 800
parameter.override.cObject.file.maxH = 600
# used lightbox is pmkslimbox
ATagParams = rel="lightbox"
ATagParams.override = rel="lightbox[sb{field:uid}]"
ATagParams.insertData = 1
}
}
}
}
plugin.tx_chgallery_pi1.single.image < plugin.tx_chgallery_pi1.gallery.image
seite = PAGE
seite{
headerData.10 = TEXT
typeNum = 0
bodyTag = <body>
10 = TEMPLATE
10.template = FILE
10.template.file = fileadmin/index.htm
10.workOnSubpart = DOKUMENT
includeCSS{
file1 = typo3conf/ext/pmkslimbox/res/styles/slimbox.css
}
1230 = COA
1230 {
10 = USER
10.userFunc = user_slimbox->addJS
10.jsfile.dataWrap = {$plugin.pmkslimbox.mootoolsJS}
20 = USER
20.userFunc = user_slimbox->addJS
20.jsfile.dataWrap = {$plugin.pmkslimbox.slimboxJS}
30 = USER
30.userFunc = user_slimbox->addJS
30.jsdata.cObject = COA
30.jsdata.cObject {
1 = TEXT
1.value = Slimbox.scanPage = function() {var links = $$("a").filter(function(el) {return el.rel && el.rel.test(/^lightbox/i);});
2 = TEXT
2.value = $$(links).slimbox({resizeDuration: {$plugin.pmkslimbox.resizeDuration}, resizeTransition: Fx.Transitions.{$plugin.pmkslimbox.resizeTransition}, opacity: {$plugin.pmkslimbox.opacity}, opacityDuration: {$plugin.pmkslimbox.opacityDuration}, loop: {$plugin.pmkslimbox.loop}, initialWidth: {$plugin.pmkslimbox.initialWidth}, initialHeight: {$plugin.pmkslimbox.initialHeight}, animateCaption: {$plugin.pmkslimbox.animateCaption}, showCounter: {$plugin.pmkslimbox.showCounter}, defaultIframeWidth: {$plugin.pmkslimbox.defaultIframeWidth}, defaultIframeHeight: {$plugin.pmkslimbox.defaultIframeHeight}, iframeScrolling: '{$plugin.pmkslimbox.iframeScrolling}', enablePrintButton: {$plugin.pmkslimbox.enablePrintButton}, enableSaveButton: {$plugin.pmkslimbox.enableSaveButton},
3 = TEXT
3.value = counterText: '{LLL:EXT:pmkslimbox/locallang.xml:counterText}', psScriptPath: '{TSFE:baseUrl}{path:EXT:pmkslimbox/savefile.php}'
3.insertData = 1
4 = TEXT
4.value = }, null, function(el) {return (this == el) || ((this.rel.length > 8-) && (this.rel == el.rel));});};window.addEvent("domready", Slimbox.scanPage);
}
}
headerData.1230 = TEXT
headerData.1230.dataWrap (
<link rel="stylesheet" href="{path:{$plugin.pmkslimbox.slimboxCSS}}" type="text/css" media="screen" />
)
10.marks{
### Inhalte ausgeben ###
INHALT = CONTENT
INHALT {
table = tt_content
}
renderObj = COA
renderObj {
10 = TEXT
10.field = header
10.wrap = |
}
}
}
Die Quelltextausgabe der betrffenden seite:
<!DOCTYPE html
PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<!--
This website is powered by TYPO3 - inspiring people to share!
TYPO3 is a free open source Content Management Framework initially created by Kasper Skaarhoj and licensed under GNU/GPL.
TYPO3 is copyright 1998-2008 of Kasper Skaarhoj. Extensions are copyright of their respective owners.
Information and contribution at http://typo3.com/ and http://typo3.org/
-->
<link rel="stylesheet" type="text/css" href="typo3temp/stylesheet_8192c2092f.css" />
<link rel="stylesheet" href="typo3conf/ext/pmkslimbox/res/styles/slimbox_ex.css" type="text/css" media="screen" />
<title>Homepage</title>
<meta name="generator" content="TYPO3 4.2 CMS" />
<script type="text/javascript" src="typo3temp/javascript_93077bb238.js"></script>
<link rel="stylesheet" href="typo3conf/ext/chgallery/res/gallery.css" type="text/css" />
<script type="text/javascript" src="typo3conf/ext/pmkslimbox/res/scripts/mootools.v1.1.js"></script>
<script type="text/javascript" src="typo3conf/ext/pmkslimbox/res/scripts/slimbox_ex.js"></script>
<script type="text/javascript">
/*<![CDATA[*/
<!--
Slimbox.scanPage = function() {var links = $$("a").filter(function(el) {return el.rel && el.rel.test(/^lightbox/i);});$$(links).slimbox({resizeDuration: 400, resizeTransition: Fx.Transitions.sineInOut, opacity: 0.8, opacityDuration: 500, loop: {$plugin.pmkslimbox.loop}, initialWidth: 250, initialHeight: 250, animateCaption: 1, showCounter: {$plugin.pmkslimbox.showCounter}, defaultIframeWidth: 500, defaultIframeHeight: 300, iframeScrolling: 'auto', enablePrintButton: 0, enableSaveButton: 0,counterText: '', psScriptPath: 'typo3conf/ext/pmkslimbox/savefile.php'}, null, function(el) {return (this == el) || ((this.rel.length > 8-) && (this.rel == el.rel));});};window.addEvent("domready", Slimbox.scanPage);
// -->
/*]]>*/
</script>
</head>
<body>
<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="31%"> </td>
<td width="45%">
<!-- CONTENT ELEMENT, uid:1/list [begin] -->
<a id="c1"></a>
<!-- Plugin inserted: [begin] -->
<!--
BEGIN: Content of extension "chgallery", plugin "tx_chgallery_pi1"
-->
<div class="tx-chgallery-pi1">
<!--<span class="links"><a href="index.php?id=1&no_cache=1&tx_chgallery_pi1[single]=1&tx_chgallery_pi1[]=1" >Page 1</a></span> start -->
<div class="pagebrowser">
<div class="prev"> </div>
<div class="text"><span class="result">Page <span class="chgcurrent">1</span> of <span class="chgtotal">1</span></span></div>
<div class="next"></div>
<div class="clr"></div>
</div>
<!--<span class="links"><a href="index.php?id=1&no_cache=1&tx_chgallery_pi1[single]=1&tx_chgallery_pi1[]=1" >Page 1</a></span> end -->
<div class="single" >
<div class="img">
<div class="align">
<a href="fileadmin/user_upload/testbilder/bild_1.jpg" title="Bild 1" rel="lightbox[sb1]"><img src="typo3temp/pics/21b7803f3b.jpg" width="139" height="104" border="0" alt="Bild 1" title="Bild 1" /></a>
</div>
</div>
<span>Bild 1 <!-- 1 --><small>236 Kb</small><!-- 1 --></span>
</div>
<div class="single" >
<div class="img">
<div class="align">
<a href="fileadmin/user_upload/testbilder/bild_2.jpg" title="Bild 2" rel="lightbox[sb1]"><img src="typo3temp/pics/95b685c321.jpg" width="139" height="104" border="0" alt="Bild 2" title="Bild 2" /></a>
</div>
</div>
<span>Bild 2 <!-- 1 --><small>245 Kb</small><!-- 1 --></span>
</div>
<div class="single" >
<div class="img">
<div class="align">
<a href="fileadmin/user_upload/testbilder/bild_3.jpg" title="Bild 3" rel="lightbox[sb1]"><img src="typo3temp/pics/bad91a373b.jpg" width="139" height="104" border="0" alt="Bild 3" title="Bild 3" /></a>
</div>
</div>
<span>Bild 3 <!-- 1 --><small>239 Kb</small><!-- 1 --></span>
</div>
<div class="clr"></div>
<!--<span class="links"><a href="index.php?id=1&no_cache=1&tx_chgallery_pi1[single]=1&tx_chgallery_pi1[]=1" >Page 1</a></span> start -->
<div class="pagebrowser">
<div class="prev"> </div>
<div class="text"><span class="result">Page <span class="chgcurrent">1</span> of <span class="chgtotal">1</span></span></div>
<div class="next"></div>
<div class="clr"></div>
</div>
<!--<span class="links"><a href="index.php?id=1&no_cache=1&tx_chgallery_pi1[single]=1&tx_chgallery_pi1[]=1" >Page 1</a></span> end -->
</div>
<!-- END: Content of extension "chgallery", plugin "tx_chgallery_pi1" -->
<!-- Plugin inserted: [end] -->
<!-- CONTENT ELEMENT, uid:1/list [end] -->
</td>
<td width="24%"> </td>
</tr>
</table>
</body>
</html>
Was passt hier nicht, habe Urlaub und sitze hier nun schon seit 3 (!) Tagen an dem Problem.
Danke für jegliche Hilfe!
Wenn schon T3 neu, dann doch aktuelle Version 4.2.8! Und bitte keine Tabellen-Layouts mehr #paralyzed#
Ok, ins Root-Template include static (from extension) -> SlimBox (pkslimbox) die restlichen der slimbox brauchst Du erst mal nicht!
Und dann das ins Setup:
### EXT: chgallery ###
plugin.tx_chgallery_pi1 {
pathToCSS = fileadmin/css/gallery.css
gallery.image {
file {
maxW = 100
maxH = 75
}
imageLinkWrap = 1
imageLinkWrap {
enable = 1
typolink {
title.field= tx_chgalleryTitle
parameter.override.cObject = IMG_RESOURCE
parameter.override.cObject.file.import.data = TSFE:lastImageInfo|origFile
parameter.override.cObject.file.maxW = 800
parameter.override.cObject.file.maxH = 600
# used lightbox is pmkslimbox
ATagParams = rel="lightbox"
ATagParams.override = rel="lightbox[sb{field:uid}]"
ATagParams.insertData = 1
}
}
}
}
plugin.tx_chgallery_pi1.image < plugin.tx_chgallery_pi1.gallery.image
Hab hier aber wie Du sehen kannst an pathToCSS = fileadmin/css/gallery.css ein eigenes CSS verwendet.
Damit muss das 100% klappen.
Viel Glück!
Michael
Hallo,
danke zunächst mal für die Hilfe!
Ich habe es jetzt soweit hinbekommen das es im Prinzip funktioniert, und jetzt noch so ein paar Feinarbeiten nötig sind.
Es gibt ja bei der Slimbox 4 Varianten:
- SlimBox
- SlimBoxPlus
- MediaBox
- SlimBoxMagnify
Bei mir funktioniert es nur mit den Versionen "SlimboxPlus" und "MediaBox".
Ich möchte gerne innerhalb des Lightboxeffectes diese Leiste mit der Bilderanzahl haben. Also soll dort z.B. "1 2 3 4 5 6 7 8" stehen.
Was muss ich denn da noch anpassen?