2016-05-16 8 views
0

を動作しません。フロートは、私はこちらのページを持っている

浮動していない理由はありますか?

ここで全体のコードです:

<div style="margin-top: 10px; float: left;"> 
<img src="http://www.iliveaccountable.com/mytestsite/wp-content/uploads/2016/05/tony-beatty.jpg" alt="tony-beatty" width="351" height="360" class="alignleft size-full wp-image-15670" style="margin-right: 15px; border: 1px solid #dedede; padding: 10px; -webkit-box-shadow: 3px 2px 5px 0px rgba(199,199,199,1); 
-moz-box-shadow: 3px 2px 5px 0px rgba(199,199,199,1); 
box-shadow: 3px 2px 5px 0px rgba(199,199,199,1);"/> 
</div> 

<div style="float: right; margin-top: 11px;"> 
<h3>TONY BEATTY/CHIEF OPERATIONS OFFICER</h3> 

Music Inc. Magazine calls Tony the <em>"Million Dollar Closer”</em> 

After 25 years mastering the art of selling Music Inc. Magazine calls Tony the "million dollar closer.” Tony is not 
only an extremely accomplished sales genius, but he considers himself a master story teller. Originally educated in 
Music and Acting, Tony’s passion for story selling was express on the theatrical stage. After more than 50 
productions his love of music and performance led him to small piano store in St. George Utah where he 
combined story telling with enrolling people into music making. 

In 2011, playing with video and Social Media, Tony was key in launching The Piano Guys YouTube Channel. To be 
excellent in his new craft of video production, Tony received a B.S. Degree in Digital Film Production from Dixie 
State University in 2013 which adds to his repertoire of talents. Talents he uses to enroll people into their own 
story, vision, and purpose. 

Because of Tony’s passion for learning the art of enrollment and personal development he has studied and trained 
with some of the most well-known personal educators and facilitators from around the country, such as; Tom 
Hopkins, Zig Ziglar, Brian Tracy and John Maxwell. Tony recognizes the behind every person is a story, likewise 
products and services that enhance our lives are created through stories. Magic happens when stories merge and 
fulfillment in life is achieved. 

After training with Michael Gardner, Tony’s story telling took on a whole new meaning. “Life is a story, the human 
story. Most peoples make up victim stories that get in the way who they truly are. Once we start recognizing the 
truth of our story, we can then finish our story.” 

Tony is energetic, enthusiastic and driven by people's success in life. He has comprehensive experience in human 
relations inside and outside the retail and services arena. He is characterized as considerate, dependable, 
honest, straightforward, hard-working, and personable, with strong management skills, including sales, marketing 
and customer relationship management experience develop throughout the last 25 years. 
Tony offers a combination of creative talents and a strong personal experience with people from all walks of life. 
He devotes time to people while drawing on their energy, experiences and vision to make a positive contribution in 
peoples lives. 

</div> 

<div style="clear: both; margin-bottom: 20px;"> </div> 


<div style="float: left; margin-top: 10px; border: 1px solid red;"> 
<img src="http://www.iliveaccountable.com/mytestsite/wp-content/uploads/2016/05/mike-gardner.jpg" alt="mike-gardner" width="351" height="360" class="alignleft size-full wp-image-15669" style="margin-right: 15px; border: 1px solid #dedede; padding: 10px; -webkit-box-shadow: 3px 2px 5px 0px rgba(199,199,199,1); 
-moz-box-shadow: 3px 2px 5px 0px rgba(199,199,199,1); box-shadow: 3px 2px 5px 0px rgba(199,199,199,1);"/> 
</div> 

<div style="float: right; margin-top: 11px; border: 1px solid red;"> 
<h3>MICHAEL GARDNER/CHIEF EXECUTIVE OFFICER</h3> 

Michael Gardner is known as the Master Trainer. 

Michael is able to train students at a new depth of knowledge that they have not experienced before, their lives 
truly changed. They are able to create a passion for life and newfound wealth. Gifted would be an understatement 
in referring to Michael Gardner. 

Michael has spent the past 25 years challenging and inspiring over 10,000 people to discover that they are more 
powerful than they believe. As a result, he is the premier trainer and coach and his field. Michael's direct 
approach, results driven training and coaching has been experienced by CEOs, entrepreneurs, small business 
owners, network marketing founders and distributors, athletes, entertainers, students and parents, and anyone 
who has a desire to discover they are more powerful than they believe. 

Michael has one purpose and one purpose only. That is to support his students to get what they want and more. 
His students and clients discover that Michael is very direct, honest and focused. His passion is to change and 
support them in their pursuits of self discovery. 

Michael has a unique ability to point out the lies and stories people tell themselves to justify where they have fallen short. Even those who have achieved amazing levels of success in life are surprised by how much greater the 
results they create are as a result of participating in Michael's training. Past students and clients share a greater sense of power in their lives, as well as becoming more effective in their careers, and a greater sense of peace and fulfillment in their lives. 

The main focus of Michael's training and coaching are: accountability, commitment, current pension, honesty, 
integrity and trust. 

Whether you feel you are successful in your personal life or not, whether you feel you are already fulfilled and life is good, you will benefit exponentially to Michael's training and coaching. 

If you are serious about shifting in your life, getting honest about where you are, what is in your way and are 
committed to accelerate your life to new levels, then Michael and iLiveAccountable trainings are the perfect fit for you. 

</div> 

<div style="clear: both;"> </div> 
+1

あなたは幅を使用していません。両方の列に幅を与えようとすると1行に収まるでしょうが、1つのdivで両方のdivを取ると、モバイルでもよく見えるようになります。 –

+0

そして、HTMLタグにスタイルを追加する代わりにCSSを使用してください。 – Frutis

+0

@Frutisあなたは外部のCSSファイルを意味しましたか? –

答えて

0

あなたの問題によると、私はあなたのために役立つことが、それは(質問では必要ありません)応答ではありませんように注意してくださいますあなたのコードを表示してみましょう:

<div style="width:80%;margin-left:auto;margin-right:auto;"> 
     <div style="margin-top: 10px; float: left;width:30%"> 
<img src="http://www.iliveaccountable.com/mytestsite/wp-content/uploads/2016/05/tony-beatty.jpg" alt="tony-beatty" width="351" height="360" class="alignleft size-full wp-image-15670" style="margin-right: 15px; border: 1px solid #dedede; padding: 10px; -webkit-box-shadow: 3px 2px 5px 0px rgba(199,199,199,1); 
-moz-box-shadow: 3px 2px 5px 0px rgba(199,199,199,1); 
box-shadow: 3px 2px 5px 0px rgba(199,199,199,1);"/> 
</div> 

     <div style="float: right; margin-top: 11px;width:60%;"> 
<h3>TONY BEATTY/CHIEF OPERATIONS OFFICER</h3> 

Music Inc. Magazine calls Tony the <em>"Million Dollar Closer”</em> 

After 25 years mastering the art of selling Music Inc. Magazine calls Tony the "million dollar closer.” Tony is not 
only an extremely accomplished sales genius, but he considers himself a master story teller. Originally educated in 
Music and Acting, Tony’s passion for story selling was express on the theatrical stage. After more than 50 
productions his love of music and performance led him to small piano store in St. George Utah where he 
combined story telling with enrolling people into music making. 

In 2011, playing with video and Social Media, Tony was key in launching The Piano Guys YouTube Channel. To be 
excellent in his new craft of video production, Tony received a B.S. Degree in Digital Film Production from Dixie 
State University in 2013 which adds to his repertoire of talents. Talents he uses to enroll people into their own 
story, vision, and purpose. 

Because of Tony’s passion for learning the art of enrollment and personal development he has studied and trained 
with some of the most well-known personal educators and facilitators from around the country, such as; Tom 
Hopkins, Zig Ziglar, Brian Tracy and John Maxwell. Tony recognizes the behind every person is a story, likewise 
products and services that enhance our lives are created through stories. Magic happens when stories merge and 
fulfillment in life is achieved. 

After training with Michael Gardner, Tony’s story telling took on a whole new meaning. “Life is a story, the human 
story. Most peoples make up victim stories that get in the way who they truly are. Once we start recognizing the 
truth of our story, we can then finish our story.” 

Tony is energetic, enthusiastic and driven by people's success in life. He has comprehensive experience in human 
relations inside and outside the retail and services arena. He is characterized as considerate, dependable, 
honest, straightforward, hard-working, and personable, with strong management skills, including sales, marketing 
and customer relationship management experience develop throughout the last 25 years. 
Tony offers a combination of creative talents and a strong personal experience with people from all walks of life. 
He devotes time to people while drawing on their energy, experiences and vision to make a positive contribution in 
peoples lives. 

</div> 
<div style="clear:both;"></div> 
    </div> 
    <div style="margin-bottom: 20px;width:80%;margin-left:auto;margin-right:auto;"> 


    <div style="float: left; margin-top: 10px; border: 1px solid red;width:30%;"> 
<img src="http://www.iliveaccountable.com/mytestsite/wp-content/uploads/2016/05/mike-gardner.jpg" alt="mike-gardner" width="351" height="360" class="alignleft size-full wp-image-15669" style="margin-right: 15px; border: 1px solid #dedede; padding: 10px; -webkit-box-shadow: 3px 2px 5px 0px rgba(199,199,199,1); 
-moz-box-shadow: 3px 2px 5px 0px rgba(199,199,199,1); box-shadow: 3px 2px 5px 0px rgba(199,199,199,1);"/> 
</div> 

    <div style="float: right; margin-top: 11px; border: 1px solid red;width:60%;"> 
<h3>MICHAEL GARDNER/CHIEF EXECUTIVE OFFICER</h3> 

<p>Michael Gardner is known as the Master Trainer.</p> 

<p>Michael is able to train students at a new depth of knowledge that they have not experienced before, their lives 
truly changed. They are able to create a passion for life and newfound wealth. Gifted would be an understatement 
in referring to Michael Gardner.</p> 

<p>Michael has spent the past 25 years challenging and inspiring over 10,000 people to discover that they are more 
powerful than they believe. As a result, he is the premier trainer and coach and his field. Michael's direct 
approach, results driven training and coaching has been experienced by CEOs, entrepreneurs, small business 
owners, network marketing founders and distributors, athletes, entertainers, students and parents, and anyone 
who has a desire to discover they are more powerful than they believe. 

Michael has one purpose and one purpose only. That is to support his students to get what they want and more. 
His students and clients discover that Michael is very direct, honest and focused. His passion is to change and 
support them in their pursuits of self discovery. 

Michael has a unique ability to point out the lies and stories people tell themselves to justify where they have fallen short. Even those who have achieved amazing levels of success in life are surprised by how much greater the 
results they create are as a result of participating in Michael's training. Past students and clients share a greater sense of power in their lives, as well as becoming more effective in their careers, and a greater sense of peace and fulfillment in their lives. 

The main focus of Michael's training and coaching are: accountability, commitment, current pension, honesty, 
integrity and trust. 

Whether you feel you are successful in your personal life or not, whether you feel you are already fulfilled and life is good, you will benefit exponentially to Michael's training and coaching. 

If you are serious about shifting in your life, getting honest about where you are, what is in your way and are 
committed to accelerate your life to new levels, then Michael and iLiveAccountable trainings are the perfect fit for you.</p> 

</div> 

<div style="clear: both;"> </div> 
</div> 

上記のコードは、あなたの質問の解決策です。しかし、フロートを使用したり、構造を作成したりするときはいつでも、親divでそれらをバインドして、それに従って作業してください。

浮動小数点数(左と右)を持つ2つのdivをバインドしてからdiv要素として幅を与え、幅を指定して幅を固定します(pxまたは%で) floatを使用して1行になるようにします。 (ただし、上記のコードイメージでは、応答しなかったため、テキストは上書きされます)。また、float要素の後にclearを使用してみてください。ただし、コンテナ内にあるかどうかは問題を引き起こします。それが助けてくれることを願って。あなたに問題がある場合は教えてください:)

関連する問題