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

  • Home
  • SEARCH
  • 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 8263257
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T04:02:11+00:00 2026-06-08T04:02:11+00:00

in CSS , how do i achieve the following: My attempt: <div id=slope></div> #slope{

  • 0

in CSS , how do i achieve the following:
enter image description here

My attempt:

<div id="slope"></div>

#slope{
    width: 100px;
    border-top: 20px solid #000;
    border-right: 90px solid #fff;
}

But then i’m stuck with how to make the thing look like a line instead of a solid

I’ve tried raphael JS, it works but i need to incorporate this element with jQuery’s animation, raphael uses SVG and doesn’t seems to play well with jQuery

css3/html5 is ok, as long as safari/chrome supports it then it’s fine

and i need to be able to modify where the slope section is placed.(Ex: move the slope section in the middle a bit to the left).

  • 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-06-08T04:02:13+00:00Added an answer on June 8, 2026 at 4:02 am

    Use html5 canvas. Here’s my fiddle example.

    JS:

    var canvas = document.getElementById('mycanvas');
    if (canvas.getContext)
    { 
        // use getContext to use the canvas for drawing
        var ctx = canvas.getContext('2d');
    
        ctx.lineWidth = 2;
        ctx.beginPath();
        ctx.moveTo(10,10);
        ctx.lineTo(100,10);
        ctx.lineTo(120,30);
        ctx.lineTo(220,30);
        ctx.stroke();
    } 
    else 
    {
        alert('Not supported');
    }
    ​
    

    HTML:

     <canvas id="mycanvas"></canvas>​
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using the following CSS to achieve a rounded border on my DIV: border:
I have the following css. #lll { float:left; max-width:1000px; border:1px solid; } #rrr {
How to achieve the following with CSS? -------------------------------------------------- | DIV 1: 50px | DIV
How can I achieve this view with CSS: ------------------TITLE or TITLE------------------ I have <div
I'm having an CSS problem, i need to achieve this article div#comments-wrapper ul.sub-comment:before {
What's the simplest way to achieve the following with HTML/CSS: +---------+---------------------------------------------------+ | my |
is there a simple css way to achieve the following layout?: here you can
I want to achieve following layout: with following code: <div class=m> <div class=l></div> <div
I want to achieve the following: Main div and sidebar div should have same
It it possible to achieve the following layout in CSS using a <ul></ul> and

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.