Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6906425
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T08:18:30+00:00 2026-05-27T08:18:30+00:00

<div class=container> <h1>this is cool typograp right</h1> </div> so i want separate each h1

  • 0
<div class="container">
    <h1>this is cool typograp right</h1>
</div>

so i want separate each h1 word and styling them with list-item and dynamic size each word
it will be :

this
is
cool
typograp
right

lets say the container is 100px so each word wrap differently (“this” will be big enough to fill 100px of container, “is” is more bigger than “this” to fill 100px because just two letter right, and other same schematic)

lettering.js as far as i know just separate them, it easy if just styling static text.

thanks for ur time guys

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T08:18:31+00:00Added an answer on May 27, 2026 at 8:18 am

    This works pretty well:

    var words = $('h1').text().split(' ');
    $('.container').empty().append('<ul />');
    for (i=0;i<words.length;i++){
        $('<li />').text(words[i]).appendTo('.container ul');
    }
    

    JS Fiddle demo.

    Though be careful using classes and just element-names, since the above would apply to all h1 elements and all .container elements. An id based selector would be much more refined and less accident-prone.

    Although re-reading your question I fail to understand what you want, besides moving each word into its own list-item. Dynamically sizing and styling the words/elements? Based on what..?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This is my code : <div class=container> <a class=link href=http://www.website.com>My Link</a> </div> .container {
I'm unsure if this is classed as a child and parent div. <div class=container>
I have an image <div class='container'> <img src='../images.jpg' alt='images' /> </div> I want to
Sample html markup below <div class=container answer_comments> <p class=comment_text>Hey that's not cool.</p> <p class=comment_attribs>By
I have a two divs which have class name container. Each of this divs
Code on page: <div class='container'> <p> <b>Address:</b> Some address<br /> <b>Phone:</b> phone1, phone2<br />
Hi I've got something like the following HTML: <div class="container"> <img src="first.png" /> <img
I have an apparently easy problem which is: <div class=container> <div class=a></div> <div class=b></div>
I wrote function onclick of a element <div class=left_collapsed>Որոնում</div> <div class=container style=display: none;> <ul>
I have bits of horrible code I have to deal with ... <div class=container>

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.