Jump to content
xt:Commerce Community Forum

Problem mit Java


CUULT

Recommended Posts

Hallo,

zusammen kann mir jedem man sagen (schreiben) wie solch ein script in einer page seite rein bekomme.

<script type="text/javascript">

$(function(){

// Dialog

$('#dialog').dialog({

autoOpen: false,

width: 600,

buttons: {

"Ok": function() {

$(this).dialog("close");

},

"Cancel": function() {

$(this).dialog("close");

}

}

});

// Dialog Link

$('#dialog_link').click(function(){

$('#dialog').dialog('open');

return false;

});

//hover states on the static widgets

$('#dialog_link, ul#icons li').hover(

function() { $(this).addClass('ui-state-hover'); },

function() { $(this).removeClass('ui-state-hover'); }

);

});

</script>

Link to comment
Share on other sites

Danke aber damit wird das Script auch nicht ausgeführt.

Es wird zwar die seite geladen aber das script wird nicht bearbeitet.

Hier kannst du es selber versuchen. Lade auf der jquery seite die neuen scripte herrunter und lade Sie im deine Seite und versuche mal folgende Dialog funktion in die seite ein zubauen.

Die Scripte selber werden geladen aber nicht das was man braucht im body tag.

<!DOCTYPE html>

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />

<title>jQuery UI Example Page</title>

<link type="text/css" href="css/ui-lightness/jquery-ui-1.8.4.custom.css" rel="stylesheet" />

<script type="text/javascript" src="js/jquery-1.4.2.min.js"></script>

<script type="text/javascript" src="js/jquery-ui-1.8.4.custom.min.js"></script>

<script type="text/javascript">

$(function(){

// Accordion

$("#accordion").accordion({ header: "h3" });

// Tabs

$('#tabs').tabs();

// Dialog

$('#dialog').dialog({

autoOpen: false,

width: 600,

buttons: {

"Ok": function() {

$(this).dialog("close");

},

"Cancel": function() {

$(this).dialog("close");

}

}

});

// Dialog Link

$('#dialog_link').click(function(){

$('#dialog').dialog('open');

return false;

});

// Datepicker

$('#datepicker').datepicker({

inline: true

});

// Slider

$('#slider').slider({

range: true,

values: [17, 67]

});

// Progressbar

$("#progressbar").progressbar({

value: 20

});

//hover states on the static widgets

$('#dialog_link, ul#icons li').hover(

function() { $(this).addClass('ui-state-hover'); },

function() { $(this).removeClass('ui-state-hover'); }

);

});

</script>

<style type="text/css">

/*demo page css*/

body{ font: 62.5% "Trebuchet MS", sans-serif; margin: 50px;}

.demoHeaders { margin-top: 2em; }

#dialog_link {padding: .4em 1em .4em 20px;text-decoration: none;position: relative;}

#dialog_link span.ui-icon {margin: 0 5px 0 0;position: absolute;left: .2em;top: 50%;margin-top: -8px;}

ul#icons {margin: 0; padding: 0;}

ul#icons li {margin: 2px; position: relative; padding: 4px 0; cursor: pointer; float: left; list-style: none;}

ul#icons span.ui-icon {float: left; margin: 0 4px;}

</style>

</head>

<body>

<!-- Dialog NOTE: Dialog is not generated by UI in this demo so it can be visually styled in themeroller-->

<h2 class="demoHeaders">Dialog</h2>

<p><a href="#" id="dialog_link" class="ui-state-default ui-corner-all"><span class="ui-icon ui-icon-newwin"></span>Open Dialog</a></p>

<h2 class="demoHeaders">Overlay and Shadow Classes <em>(not currently used in UI widgets)</em></h2>

<div style="position: relative; width: 96%; height: 200px; padding:1% 4%; overflow:hidden;" class="fakewindowcontain">

<p>Lorem ipsum dolor sit amet, Nulla nec tortor. Donec id elit quis purus consectetur consequat. </p><p>Nam congue semper tellus. Sed erat dolor, dapibus sit amet, venenatis ornare, ultrices ut, nisi. Aliquam ante. Suspendisse scelerisque dui nec velit. Duis augue augue, gravida euismod, vulputate ac, facilisis id, sem. Morbi in orci. </p><p>Nulla purus lacus, pulvinar vel, malesuada ac, mattis nec, quam. Nam molestie scelerisque quam. Nullam feugiat cursus lacus.orem ipsum dolor sit amet, consectetur adipiscing elit. Donec libero risus, commodo vitae, pharetra mollis, posuere eu, pede. Nulla nec tortor. Donec id elit quis purus consectetur consequat. </p><p>Nam congue semper tellus. Sed erat dolor, dapibus sit amet, venenatis ornare, ultrices ut, nisi. Aliquam ante. Suspendisse scelerisque dui nec velit. Duis augue augue, gravida euismod, vulputate ac, facilisis id, sem. Morbi in orci. Nulla purus lacus, pulvinar vel, malesuada ac, mattis nec, quam. Nam molestie scelerisque quam. </p><p>Nullam feugiat cursus lacus.orem ipsum dolor sit amet, consectetur adipiscing elit. Donec libero risus, commodo vitae, pharetra mollis, posuere eu, pede. Nulla nec tortor. Donec id elit quis purus consectetur consequat. Nam congue semper tellus. Sed erat dolor, dapibus sit amet, venenatis ornare, ultrices ut, nisi. Aliquam ante. </p><p>Suspendisse scelerisque dui nec velit. Duis augue augue, gravida euismod, vulputate ac, facilisis id, sem. Morbi in orci. Nulla purus lacus, pulvinar vel, malesuada ac, mattis nec, quam. Nam molestie scelerisque quam. Nullam feugiat cursus lacus.orem ipsum dolor sit amet, consectetur adipiscing elit. Donec libero risus, commodo vitae, pharetra mollis, posuere eu, pede. Nulla nec tortor. Donec id elit quis purus consectetur consequat. Nam congue semper tellus. Sed erat dolor, dapibus sit amet, venenatis ornare, ultrices ut, nisi. </p>

<!-- ui-dialog -->

<div class="ui-overlay"><div class="ui-widget-overlay"></div><div class="ui-widget-shadow ui-corner-all" style="width: 302px; height: 152px; position: absolute; left: 50px; top: 30px;"></div></div>

<div style="position: absolute; width: 280px; height: 130px;left: 50px; top: 30px; padding: 10px;" class="ui-widget ui-widget-content ui-corner-all">

<div class="ui-dialog-content ui-widget-content" style="background: none; border: 0;">

<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>

</div>

</div>

</div>

<!-- ui-dialog -->

<div id="dialog" title="Dialog Title">

<p>22Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>

</div>

</body>

</html>

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
  • Create New...