Jump to content

Search the Community

Showing results for tags 'CSS'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • W3Schools
    • General
    • Suggestions
    • Critiques
  • HTML Forums
    • HTML/XHTML
    • CSS
  • Browser Scripting
    • JavaScript
    • VBScript
  • Server Scripting
    • Web Servers
    • Version Control
    • SQL
    • ASP
    • PHP
    • .NET
    • ColdFusion
    • Java/JSP/J2EE
    • CGI
  • XML Forums
    • XML
    • XSLT/XSL-FO
    • Schema
    • Web Services
  • Multimedia
    • Multimedia
    • FLASH

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Languages

Found 884 results

  1. Hi! Im trying to design a view with 2 boxes : on the left 1 menu and in the right the main box. The menu should be vertical and relative, and with the main box I can do what I want. The problem is that this 2 boxes should fill all the space horizontally and vertically. But all the time that I change the width or the "position" I have 2 results: Part of the main box is hidden with the menu box The two boxes dont fill the space This is the css code of my boxes: .main-box{ background-color: #FFFFFF; font-size: 14px; color: #34495E; height:99%; min-width: 150px; line-height: 1.231; width: 94%; margin-left: 10%; margin-right: 0.5%; float: right; border-radius: 5px 5px 0 0; box-shadow: 0 1px 5px rgba(0, 0, 0, 0.65); } .menu{ position: fixed; left: 0; top: 0; bottom: 0; height: 100%; width: 7em; background-color: #333; } And this is the result. How can I solve it? Thanks!
  2. Hello guys, I´m currently creating a website and have to use some kind of a switch button (in iOS-Style). I already implemented the switch button, however I want the user to switch with the button between two upcoming photo galleries. Because documentation in the www is lacking, I would need your support. Because I´m pretty unexperienced in website coding, I used the W3school switch button (https://www.w3schools.com/howto/howto_css_switch.asp) I hope you could help and I´m sorry for being such unexperienced but having high demands.
  3. dkx4hws

    W3 CSS

    Hi the https://www.w3schools.com/w3css/4/w3.css doesn't appear to work in asp.net using forms is there a work around for this?
  4. Hey, I'm new to CSS and trying to figure something out. I want to have my search bar so when the user clicks it, the entire page fades except for the search bar. So although the bar itself doesn't change, it creates the effect of it being highlighted. If anyone could point me in the right direction that would be great! Thanks Dan
  5. PascalM

    Image Hover Overlay

    Hello everybody I recently found this simple Image Hover Effect on w3schools: Image Hover Overlay: https://www.w3schools.com/howto/howto_css_image_overlay.asp This even seems to work on mobile (iOS) devices (touch), as far as I could test in the tryout editor. I then saved the provided code and published it on my own hosting (https://hammermann.ch/test.html). It's still working on desktop, but not on mobile (and I haven't changed any code at all) Any Ideas how to solve that? Thank you and stay healthy! Pascal
  6. Hi, I made a website whit css bootstrap and so on... But if I test it with a google speedtest it results very speed on desktop while the for mobile it's very slow ! my question is: Can I load only the necessary css for mobile when viewing in small screens? what other precautions can I do? Of course I'm using a cms like wordpress. Regards, Giovanni
  7. Hi Guys. This is my first post here so apology in advance (if forum rules being ignore or posted into wrong category). I am trying to display elements on div hover. I had watched a lot of tutorials and practice a lot but still i am struggling with my problem that's why i come here so maybe someone (a Hero) help me. Even sort of direction mean a lot for me Explanation: Actually i am trying to create a something like Character Selector UI in case if you're looking some reference. I want to display hidden content at class="outputr1". If i hover img 1 then it show only hover content 1. And if i hover img 3 then it show hover content 3 and so on. I also want when i hover any div then it should stay active as difficult unless i hover other div like img 1, 2 or 3. it took a month but still i haven't figure it out howto achieve this. what i am missing? <!DOCTYPE html> <html> <head> <title>Display Hidden Content OnhoverEvent</title> <style> body { padding: 50px 10px; margin: 0 auto; max-width: 900px; } .hide { display: none; } .myDIV:hover + .hide { display: block; color: red; } </style> </head> <body> <div class"outputr1"> I want to display Hidden/hover content here </div> <br><br> <div class="myDIV"><img src="1.png" width="100px" height="100"> <div class="hide"> Hover content 1 </div> </div> <div class="myDIV"><img src="2.png" width="100px" height="100"> <div class="hide"> Hover content 2 </div> </div> <div class="myDIV"><img src="3.png" width="100px" height="100"> <div class="hide"> Display Hover content 3 </div> </div> <div class="hide"> I am Hover Content but i don't want this to display.</div> </div> </body> </html> Sorry about my good English. I am really new to this stuff so i am spending most of my quarantine time in web development skills
  8. <!DOCTYPE html> <html lang = "en"> <!--This is my first comment in my index page--> <head> <meta charset="utf-8"> <link rel="stylesheet" href="greentea.css"> <a href= "greentea.html"></a> </head> <header> <h1>Teaz Nuts</h1> </header> <!--This is the body of my page--> <body> <nav> <ul> <li><a href= "greentea.html"> Home </a></li> <li><a href="about.html">Login</a></li> <li><a href="Product.html">Product</a> </li> <li><a href="New User Signup.html">New User Signup</a></li> </ul> </nav> <main> <div class = "hippiegirl"> <image src = "hippiegirl.jpg" alt = "tranquility"></image> </div> <p>The properties of green tea are many and varied. Especially during an epidemic<br> we all need to be aware of what tea can do for us. Along with its antibiotic properties, it also<br> can cleanse the spirit and wash away our tensions. </p> </main> <footer> <br>&copy; <a href="mailto:jackcole861@gmail.com">Click to email Jack Cole</a> </footer> </body> </html> This is my css .hippiegirl { position:absolute; left:0; top:0; width:400%; height:auto; opacity:0.6; } body{ background-color: lightgreen; } ul { list-style-type: none; margin: 0; padding: 0; overflow: hidden; background-color: #333; } li { float: left; } li a { display: block; color: white; text-align: center; padding: 14px 16px; text-decoration: none; } /* Change the link color to #111 (black) on hover */ li a:hover { background-color: #111; }
  9. How do you include a .inc file in a .css file? I want to create a navigation bar with CSS, but it requires me to connect the head.inc to the css file. How do I do this?
  10. Hi everyone, I'm a complete newb to this, so I feel questions are a great way to get my feet wet, here we go. I am using a Laravel Website. It's very bland looking. There is a CSS section, and I will provide a screenshot...but I have no idea what should be entered....do i need to create CSS files, or...honestly i'm, clueless. But it would mean the world to me if you fine folks could not only help me, but point me to the correct resource to begin my learning adventure. Biggest thanks in advance Carson
  11. Here's the reference code: https://www.w3schools.com/howto/howto_js_image_comparison.asp I'd like to be able to get this to duplicate and have them appear side by side. Putting the HTML code into tables doesn't work. If I increase the size of the pictures they run over each other. I think the issue is within the CSS. Here's a sample of code: .img-comp-img { position: absolute; width: auto; height: auto; overflow: hidden; } I was able to move the snowy mountain picture by copying the code, changing the element selector to ".img-comp", changing position to relative, and changing width to 300px. After that I got stuck.
  12. Hi, I'm using a w3-css-theme. How do I make a stripped table look like the theme I chose? I use the example like so: <table class="w3-table-all"> When I added w3-theme-l2, nothing happened. Thanks
  13. Hello Folks, Newbie here, learning via w3schools.com. I think I'm missing something basic, but I can't figure it out.I'm using w3schools to create a hero image (via https://www.w3schools.com/howto/tryit.asp?filename=tryhow_css_hero_image), but when I upload that code to my host, and then using different screen resolutions, the image is distorted. Viewing it on 1024x600, I see the hero image of the guy holding a camera, but if I view it on a much higher resolution, the image is "zoomed in" to the top left area of the picture. Here's the code, any help would be most appreciated: <!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style> body, html { height: 100%; margin: 0; font-family: Arial, Helvetica, sans-serif; } .hero-image { background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url("https://www.w3schools.com/howto/photographer.jpg"); height: 50%; background-position: center; background-repeat: no-repeat; background-size: cover; position: relative; } .hero-text { text-align: center; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); color: white; } .hero-text button { border: none; outline: 0; display: inline-block; padding: 10px 25px; color: black; background-color: #ddd; text-align: center; cursor: pointer; } .hero-text button:hover { background-color: #555; color: white; } </style> </head> <body> <div class="hero-image"> <div class="hero-text"> <h1 style="font-size:50px">I am John Doe</h1> <p>And I'm a Photographer</p> <button>Hire me</button> </div> </div> <p>Page Content..</p> </body> </html>
  14. Hi, I was playing around with my website and I was trying to make a semi-transparent footer This is the code I used for the footer <footer class="footer galaxy-footer"> <div class="content has-text-centered"> <p> <script src="js/copyright.js"> </script>© 2018-2020, <strong>Company.</strong> </p> </div> </footer> And this is my css .galaxy-footer { background-color: rgba(25, 25, 25, .5); color: var(--white); // #ffffff } .galaxy-footer strong { color: var(--white); } The other classes are Bulma's classes and they seems not to be the issues What I get is an half transparent footer and a grey bar, which is the part that is not displayed when the page loads because the content pushes the footer down Is this a known issue or did I forget something?
  15. Trying to modify this for different pages using page ID. Working well for the site, but I need to have different backgrounds on different pages. body { background-image: url("paper.gif"); } New to this and could use some help making it work. Thanks to anyone.
  16. JoanaN

    CSS Animation

    Hi, I have these comic PNG images and I want to animate them using CSS. I want to rotate any resize them; how can I do that? Do you have any other animation ideas that work well with comic style? Thank you!
  17. Noob here. I have been playing around with W3.css, in particular the w3-row-padding, however I would like to set up five columns, with some padding. Can anyone advise me how I might go about this (I'm guessing it will involve nesting some containers?) Many thanks.
  18. Hi The guide on making a scrolling header is great, but it relies on javascript running every time you scroll. That is really expensive (resource-wise) and contributes to a laggy an unresponsive website. I think the guide should be updated to use sticky css-elements instead of js. This method does not have the same performance issues, and I'd argue it's an easier and more elegant solution. The new guide is pretty much already written here. The support for sticky elements is not perfect, so there is a discussion to be had about whether to prioritize browser support or performance, but i think at the very least the page should have a yellow box, mentioning that the sticky element is a better solution.
  19. Hi, I did animated leafs on my web-page and after that my links did'n work. I tried to set the animation to run just one time, but it didn't help. Is just so, that animations and links don't work at the same page? Animation is made with @keyframes.
  20. I'm trying to set up a template for a website, with a responsive top border with dropdowns in the navigation bar. I thought I had it all working at one time, but have gone back to previous files to no avail. The menu is responsive, and goes down into a hamburger icon, but clicking on the hamburger icon does nothing. I'm trying to do this without using too many external files. I think the problem must be in the javascript function combined with the media queries, but I haven't been able to see the problem. I used the W3Schools responsive navbar with dropdowns, from https://www.w3schools.com/howto/tryit.asp?filename=tryhow_js_responsive_navbar_dropdown as a basis for this. The files I have are index.htm, a top border file, top.htm in the folder _borders, and 2 css files in a css folder: mystyles.css and topnav.css. This is the basic code from index.htm. I excluded site-identifying code and content. I've attached the other 3 files - didn't know how to paste them here separately. In the top.htm and index.htm I've commented out references to the mystyles.css file and it doesn't make any difference. I'm using Brackets for this, and using Live Preview. If I just open the index file directly in Chrome or Firefox, there is no formatting, no nav bar or menu. But it looks just lovely in the Brackets Live Preview (other than the hamburger icon not responding. With my working website, I can open the index file in Chrome or Firefox and all is good. If someone can provide some direction I'd really appreciate it! <!DOCTYPE html> <html lang="en-us"> <head> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="Content-Type" content="text/html; charset=windows-1252"> <meta name="author" content="USTaxTips.net"/> <link rel="stylesheet" href="../css/mystyles.css"> <link rel="shortcut icon" href="/favicon.ico"> </head> <body> <div w3-include-html="_borders/top.htm"></div> <script> includeHTML(); </script> <div id="container"> </div> </body> </html> mystyles.css topnav.css top.htm
  21. Hi, Can someone please help with some code I am trying to have the numbers *clicked* & stay blue in color and then display over on the right side in the ? circles only allowing each number to be used once photo is attached of my web page
  22. I finished studying html, and i started CSS but its same as html. should i skip css and just go to JS? i have a background in c (arduino and raspberry pi ), am not interested in the whole front-end code (its like making a power-point presentation more than coding). when am going through css its like a am going through html yet again. i could finish it in a week probably (since i finished studying html and since it seems like css is the style sheet of html). am just feeling like am wasting my time. I have this bad habit, if i start reading something, i don't feel completed if i don't go from cover to cover. PS: even if i got a comment to skip CSS, i would probably do the contrary and finish it (i just don't feel its that important for a person who is interested in the back-end programming ). i have got this bad habit of following numbers and steps even if its so repetitive.
  23. i cant make background color fully the entire page with fixed sidebar, can you help me to give the background color fully in main side bar. sorry for my bad english :) This the link fixed sidebar
  24. Could you please run the following html test case, to help figure out how to make bootstrap 4 tooltip go away when a button is disabled while the tooltip is over the button? All the details concerning my question are in the source code for display when the HTML is displayed. Any help appreciated. Thanks <!DOCTYPE html> <html lang="en"> <head> <title>Bootstrap 4 Tooltip Persists, Looks Terrible</title> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta http-equiv="Content-Type" content="text/html"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"> <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js"></script> <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js"></script> </head> <body> <div class="container"> <h3>Bootstrap 4 Tooltip Persists, Looks Terrible</h3> <br> "Other button disabled" scenario works fine. <br> First, hover over buttons. Look at tooltips while hovering. <br> Then, click button A to disable button B. Works fine: <br> - Button B is disabled, and no tooltip. <br> - Tooltip still works correctly on button A. <br> <br> <button type="button" id="button_a" class="btn btn-primary" data-toggle="tooltip" data-trigger="hover" title="Disables Button B" onclick='change_button ("button_b", true);'> Button A </button> <button type="button" id="button_b" class="btn btn-primary" data-toggle="tooltip" data-trigger="hover" title="Disabled by Button A"> Button B </button> <br> <br> <hr> <br> "Same button disabled" scenario fails. <br> First, hover over Button C. Look at the tooltip. <br> Then, click button C to disable button C. Messes up: <br> - Button C is disabled, so that part is OK. <br> - But Button C tooltip persists, looks terrible. <br> <br> <button type="button" id="button_c" class="btn btn-primary" data-toggle="tooltip" data-trigger="hover" title="Disables Button C" onclick='change_button ("button_c", true);'> Button C </button> <button type="button" id="button_d" class="btn btn-primary" data-toggle="tooltip" data-trigger="hover" title="Enables Button C" onclick='change_button ("button_c", false);'> Button D </button> <br> <br> <hr> <br> So if a button is disabled while the cursor is hovering over it, the tooltip persists. <strong> Could you please explain how to make tooltip go away when Button C is disabled? </strong> I would prefer if tooltip went away when Button C disabled, since that is default behavior of bootstrap disabled buttons. And disabled button may later get enabled again, so I do not want to delete title attribute. Basically I want bootstrap to behave the same way as when Button B is disabled. I have looked around and cannot find how to fix this problem, and have tried various things, with no success. There are real instances where a button carries out an action, and then the button needs to be disabled, so I appreciate the help. Thanks </div> <script> $(document).ready(function(){$('[data-toggle="tooltip"]').tooltip();}); function change_button (button_id, bool_val) { var button_obj = document.getElementById (button_id); button_obj.disabled = bool_val; } </script> </body> </html>
  25. MOTIVATION: It is sometimes said that time heals all. With this in mind I am hoping that the W3Schools community has advanced since the last time that I communicated and has found a solution to the following problem. BACKGROUND: Recently I created a new webpage that can be found at www.publiustwo.com/ali. If you open this page in an iPhone with a vary narrow viewport such as my own, you will observe that filling in any of the form items that require text input, and in several cases even those that do not, causes the width of the document to increase beyond the size of the available viewport and does not return it to its former size after the input has been completed. QUESTION: It would appear that there are two solutions to this problem: one, prevent the size of the page from expanding in the first place; two, cause the size of the page to retract after the entry has been completed. Has anyone found a solution to this problem" Roddy
×
×
  • Create New...