Hi,
ich habe hier aus dem Forum ein Tooltip-Snippet gefunden, dass fast genau meine Vorstellungen erfüllt. Siehe hier:
im Rollover
PHP-Code:
//Tooltipp
_root.createEmptyMovieClip("mc_tooltip", _root.getNextHighestDepth() );
var tx = _root.mc_tooltip.createTextField("tooltip", 1, _xmouse+10, _ymouse+10, 135, 75);
//Textfeld der Überschrift
tx.border = true;
tx.background = true;
tx.html = true;
tx.backgroundColor = 0xFFE800;
tx.selectable = false;
tx.autoSize = true;
tx.multiline = true;
tx.wordWrap = true;
tx.htmlText = headline;
tx.embedFonts = true;
tooltip_format = new TextFormat();
tooltip_format.bold = false;
tooltip_format.size = 18;
tooltip_format.align = "center";
tooltip_format.font = "LTWiesbadenSwing";
tx.setTextFormat(tooltip_format);
_root.mc_tooltip.startDrag();
_root.mc_tooltip._alpha = 90;
So nun brauche ich aber ein zweites Textfeld im MC und dabei mache ich irgendwas falsch. Ich habe folgendes probiert:
PHP-Code:
//Tooltipp
_root.createEmptyMovieClip("mc_tooltip", _root.getNextHighestDepth() );
var tx = _root.mc_tooltip.createTextField("tooltip", 1, _xmouse+10, _ymouse+10, 135, 75);
//Textfeld der Überschrift
tx.border = true;
tx.background = true;
tx.html = true;
tx.backgroundColor = 0xFFE800;
tx.selectable = false;
tx.autoSize = true;
tx.multiline = true;
tx.wordWrap = true;
tx.htmlText = headline;
tx.embedFonts = true;
tooltip_format = new TextFormat();
tooltip_format.bold = false;
tooltip_format.size = 18;
tooltip_format.align = "center";
tooltip_format.font = "LTWiesbadenSwing";
tx.setTextFormat(tooltip_format);
//Textfeld des Poptextes
var tx2 = _root.mc_tooltip.createTextField("tooltip2", 1, _xmouse+10, _ymouse+30, 135, 75);
tx2.border = true;
tx2.background = true;
tx2.html = true;
tx2.backgroundColor = 0xFFFFFF;
tx2.selectable = false;
tx2.autoSize = true;
tx2.multiline = true;
tx2.wordWrap = true;
tx2.htmlText = pop_text;
tx2.embedFonts = true;
tooltip_format2 = new TextFormat();
tooltip_format2.bold = false;
tooltip_format2.size = 12;
tooltip_format2.align = "center";
tooltip_format2.font = "Arial";
tx2.setTextFormat(tooltip_format2);
_root.mc_tooltip.startDrag();
_root.mc_tooltip._alpha = 90;
Sieht vielleicht jemand den Fehler?