HI i am building a site with genesis and dynamik. On the Home page with dynamik at the top there are 3 widgets. I created 3 more underneath the top three.
My problem is when I hover on any one of the elements the rest "jumps" around. All that the hover does is to adjust the element size from 300px to 350px.
How do I manage it that only the "active" element being hover on reacts and the other 5 stays static?
I might have found a solution BUT i am still lost. Bit too new at this I believe.
The two lines of code
Does this go into a html file? I am using Wordpress and these 6 fields are populated using widgets.
From the solution I understand that I have to create first-hover to six-hover with six of the lines of code linking the images to the class.
And the using the position:absolute;
If my take on this is correct please let me know and just advice me how do I do the
code and where.
Thx
You should set the css in \wp-content\themes\the-theme-you-use\style.css, for example it could be like this:
.dynamik-widget-area.feature {
position: absolute;
}
Just place this anywhere at the end of the file.
Another solution is to add style="position: absolute" to the first <div> element in the following part:
<div style="position: absolute" id="ez_feature_6" class="widget-area dynamik-widget-area ez feature 6">
<section id="black-studio-tinymce-39" class="widget widget_black_studio_tinymce">
<div class="widget-wrap">
<div class="textwidget"><p style="text-align: center;"><img class="alignnone size-medium wp-image-64" src="http://new.bluprintwebsolutions.co.za/wp-content/uploads/2015/02/diy1billboard-300x300.jpg" alt="diy1billboard" width="300" height="300"></p>
</div></div></section>
</div>
However note that this will solve the overlapping problem, but in return you'll have to reposition the elements.
Repositioning can be done using css too, using for example left attribute. Something like:
.second{
left: 100px;
}
then add second to the classes of that
<div style="position: absolute" id="ez_feature_2" class="widget-area dynamik-widget-area ez feature 6 second">
Related
I'm trying to embed a Power BI report to my website in Wordpress using the HTML tool. Since when using the embedding version of the report of Power Bi, a button to share the report appears (and it really can't in this case), I found a solution here on how to "cut" the HTML element so that the down part wouldn't appear. I'm saying this just to explain why maybe the code down can look more complicated than needed. My problem now is that I'm trying to center this element on the page, but I don't know why I can't make it work in all PCs, since in mine it appears centered but in others that I tried it didn't.
This is the code that I have until now
<div id="content">
<div class="row-fluid">
<div class="aligncenter">
<div style="height:500px;width:400px">
<iframe width="600" height="400" src="LinkOfReport" frameborder="0" style="position: absolute; clip:rect(0px,1000px,344px,0px);
; zoom:162%;allowFullScreen=" true=""></iframe>
</div>
</div>
</div></div>
I don't understand much of HTML or CSS so if someone could explain me what I'm doing wrong I would appreciate it a lot!
I managed to understand what was happening. Basically, I copied part of the code from the question I mentioned in the post, since I needed to crop the HTML element. I understood that a part of it was forcing the element to start more to the left (the part of <div style="height:500px;width:400px">) and another one to keep the element fixed in the same place, independently of the size of the window (position: absolute)
I also changed the type of clip I was using, since from what I read, clip property is exclusive to absolutely positioned elements. So now I'm using clip-path property.
Summing up, this is my final code:
<div class="row-fluid">
<div class="aligncenter">
<iframe width="600" height="400" src="https://app.powerbi.com/view?r=eyJrIjoiYjE4ZDExNGQtNjgwYS00OTUwLTkzYjYtNjM1YjNjMGJkMjU4IiwidCI6ImU0YmQ2OWZmLWU2ZjctNGMyZS1iMjQ3LTQxYjU0YmEyNDkwZSIsImMiOjh9&pageName=ReportSection" frameborder="0" style="clip-path: inset(0 0 38px 0); zoom:162%"> </iframe>
</div>
</div>
Hope these explanations help anyone that is trying to start in HTML and CSS
This question already has an answer here:
How can I overlay logo over a image? using css
(1 answer)
Closed 3 years ago.
I retrieved a Bootstrap template and I am trying to modify it a little bit in order to add a logo over a background image (back_img.jpg in my code example), in the top left of it. I insist on the fact that I really want the logo to be covering part of the background picture. Moreover, I have already seen some solutions to do it, but as far as possible, I would like to change the least possible the source code of the template.
Here is the code :
<!-- Page Header -->
<header class="masthead" style="background-image: url('img/back_img.jpg')">
<div class="overlay"></div>
<div class="container">
<div class="row">
<div class="col-lg-8 col-md-10 mx-auto">
<div class="site-heading">
<h1><font style="font-family: American Typewriter", color="#FAFF5A">Title here</font></h1>
</div>
</div>
</div>
</div>
<header/>
This can be done in many ways.
method 1:use float property to float log
method 2:using position attributes
method 1
add logo (using img tag) inside your considering background image, then write a CSS below.
img
{
float: left;
}
To learn about it, use this link
enter link description here
method 2
your considering background should be added position attribute as relative and your logo should be position as absolute, keep in mind that when you adding the absolute keyword to this your logo is out of normal document flow. after using absolute property, automatically you can use top, left, right attribute
EX: Let's say you want to position your logo to the top of your considering background and left it from 15px, code is below
img{
position:absolute;
top:0px;
left:15px;
}
If you want to learn more absolute keyword.use this link
enter link description here
I'm new to html and css. I've gotten a college assignment to create a webpage and i went somewhat overboard on the design something that was supposed to be simple has gotten somewhat complicated.
I'm currently trying to list the cast of a tv show down the left hand side of my page.
->Wire-frame example <-
Everything I have tried has failed, I'm feeling beaten here is an example of what I've managed to do trying methods i know or have found online hoping it would do the trick.
->Current Progress<-
->Link to current HTML<-
As you can see in the wire-frame, I'm ideally wanting their names centred under the pictures, which is my struggle.
Any ideas?
Thanks.
The problem you're having is that the label and the image belonging to one actor are not grouped. Put them inside a <div> container.
<div>
<div class="actor">
<img src="Pictures/willingham.jpg" class="actor-image">
<div class="actor-label">Travis</div>
</div>
<div class="actor">
<img src="Pictures/willingham.jpg" class="actor-image">
<div class="actor-label">Laura</div>
</div>
</div>
Here's the new CSS:
.actor {
display: inline-block;
}
.actor-image {
width: 86px;
}
.actor-label {
font-weight: bold;
}
Note that I also improved a lot of other things like removing unnecessary code or using CSS to style elements instead of HTML (cause that's what CSS is for). If you want the labels to look different just change/add the properties inside the .actor-label selector.
I have an image and I want to add the title of it and a basic description of it, to the right of the image. I tried using position: relative, absolute. padding & margin: 0px.
The link is: URL
The game "Rock, Paper, Scissors", and "Miji", game titles should be on the top of the image to the right, then under that I will add the game description.
Thanks!
Hello As per my understanding your trying for something like this below
https://jsfiddle.net/up1v5j0z/28/
<ul>
<li><div class="content"><img src="http://i.stack.imgur.com/FZVih.jpg?s=328&g=1" height="200px";><h4>Roshan Padole </h4><p>Senior Software Engineer and DigitalMarketing Experts</br>Management of the manpower with effective positive results. </p></div><br style="clear:both"></li>
</ul>
.content img {float:left}
[https://jsfiddle.net/up1v5j0z/28/][1]
Hope this will help you
A simple way for playing items on your page without having to mess around with specific margining and padding (which can get messy on busy pages) is by choosing your position (relative, absolute, etc) and then use left, right, and top to move it around the page.
For example
.exampleClass {
position: relative;
left: 20px;
top: 5px;
}
Play around with the numbers and position type until you have a good understanding about how they effect the items and you should have no problem tweaking the placement of the objects on your page.
<img src="Games/RPS.jpg" width="15%" height="15%" alt="Rock, Paper, Scissors">
Take these two tags first
<span id="gameTitle">Rock, Paper, Scissors, Shoot</span>
Alternate these positions two tags!
<span id="gameTitle" style=" float: left;">Rock, Paper, Scissors, Shoot</span>
Style the span to style="float: left";
Add <br/>between these <a href.... and <span id=....
Your output will be then http://myslambook.pe.hu/demo.png
There is a set of images (more than 3):
<img src="http://path.to/my/img1.jpg">
<img src="http://path.to/my/img2.jpg">
<img src="http://path.to/my/img323.jpg">
<img src="http://path.to/my/img99.jpg">
<img src="http://path.to/my/img2.jpg">
<img src="http://path.to/my/img323.jpg">
<img src="http://path.to/my/img99.jpg">
If you don't apply any styles, they go in a row (if space allows to). That's fine, however I want the last 3 images always appear on the next line. Is it possible to make it using pure css?
I've found a close solution:
img:nth-last-child(3){display:block;}
However, it breaks the images in three lines (that makes sense as it is display:block for third image from the end).
jsFiddle example
Looking for a pure css solution.
Thank you.
use
clear:both in css for last three images
img {
float:left;
}
img:nth-last-child(3) {
clear:both;
}
DEMO