jQuery steps won't render correctly
Asked Answered
S

1

6

The HTML:

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>TEsT</title>    
</head>
<body>
<div id="wizard">
    <h1>First Step</h1>
    <div>First Content</div>

    <h1>Second Step</h1>
    <div>Second Content</div>
</div>

    <script src="jquery-1.11.0.min.js"></script>
<script src="jquery.steps.min.js"></script>
<script src="homepage.js"></script>
    </body>
</html>

jQuery:

$(document).ready(function(){
$("#wizard").steps();
});

The (un-extraordinary) Rendition: jQuery Steps

Swordsman answered 30/4, 2014 at 18:41 Comment(7)
looks like you're missing some css github.com/rstaib/jquery-steps/blob/master/demo/css/…Furr
How should it be rendering? Is the jQuery code in the jquery.steps.min.js file? Can you setup a jsfiddle to demonstrate?Yeager
@JayBlanchard No jQuery code is included before the 'steps'.Swordsman
@andrew, you seem to be right, but I failed to find any mention of css on the plugin's website, neither was it included with the download.Swordsman
Where is the jQuery code that you wrote?Yeager
try changing the div tag inside #wizard to section tagBalikpapan
@JayBlanchard My code is in hompage.js, which is included. The code itself is posted above: $(document).ready(function(){ $("#wizard").steps(); });Swordsman
B
6

You should include following css file in your plugin:

https://github.com/rstaib/jquery-steps/blob/master/demo/css/jquery.steps.css

Also try changing the div tag inside #wizard to section tag

Balikpapan answered 30/4, 2014 at 18:49 Comment(2)
main.css was also needed.Swordsman
Had the same problem. It seems the main.css file came from the HTML5 Boilerplate.Islamism

© 2022 - 2024 — McMap. All rights reserved.