Jump to content

Jquery Fill-Text Plug-in Multiple spans


syngod
Go to solution Solved by kicken,

Recommended Posts

Hey guys,

 

  Im kind of a newbie when it comes to javascript and i am trying to use a fill-text jquery plugin Found here https://github.com/jquery-textfill/jquery-textfill

 

what i need to do is have multiple spans on the page expand to a certain size but im not sure how to do this with this plugin or if it is even possible.

 

here is the page i have.

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script src="http://jquery-textfill.github.io/jquery-textfill/jquery.textfill.min.js"></script>

<title></title>
</head>

<div id="visitorNotice" >
    <div id="text" class="textfill">
	    <span>Testing</span>
		<div id="visitors" class="stextfill">
		    <span>Testing</span>
		<div>
	</div>
</div>
<script>
$(function() {
  $('.textfill').textfill({ maxFontPixels:99});
});
</script>
<script>
$(funtion() {
  $('.stextfill').textfill({ maxFontPixels:80});
  });
 </script>
<body>

you can see what i tried to do, to get this to work.  But this does not work and im not sure exactly how to make it work.

 

Can anyone give me ideas on how to make this work.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.