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 7721373
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T03:54:31+00:00 2026-06-01T03:54:31+00:00

I am working on a website on which we have use parallax effect. In

  • 0

I am working on a website on which we have use parallax effect. In that there are some images which are triangle shaped, like this enter image description here

& the image is transparent because it overlaps the above DIV. I am trying so many things with css. but didn’t get the desired result. I achieve that desired result with fixed width. Check this http://jsfiddle.net/eJ7Sf/2/ but does not work with fluid width. Check what i still try but didn’t work

http://jsfiddle.net/ceGGN/3/

http://jsfiddle.net/eJ7Sf/1/

NOTE: i know about css3 MASK property but it’s not work in firefox previous browsers. I want the capability till firefox 3.6.13

  • 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-01T03:54:32+00:00Added an answer on June 1, 2026 at 3:54 am

    Updated Answer (Pure CSS3)

    Extreme requirements sometimes need extreme solutions. I’ve built upon my original answer (below) to make a pure css solution that works (and can be made to work better, if you want to invest the time in it). The current example is a bit “choppy” in rendering, which may be okay for you, but if not, you will need to extend the already obscene number of @media queries that are driving it (it would likely be much easier to implement using LESS or SASS; I put together a formula driven excel spreadsheet to help rapidly generate the numbers). It uses this code:

    HTML

    <div class="box">
       <img src="yourImage.jpg" />
    </div> 
    

    CSS

    .box{
        height:300px;  
        min-width: 100px; /*could be different, but you ought to have some min*/
        overflow:hidden;
    }
    
    .box img {
        height: 100%;
        width: 100%;   
        -ms-transform-origin: 100% 100%; /* IE 9 */
        -webkit-transform-origin: 100% 100%; /* Safari and Chrome */
        -moz-transform-origin: 100% 100%; /* Firefox */
        -o-transform-origin: 100% 100%; /* Opera */
        transform-origin: 100% 100%;
    }
    
    /*Sample... you need alot of these--my fiddle example has 51*/
    @media screen and (min-width:  100px) { 
      .box { 
        -ms-transform:skewY(45deg); 
        -moz-transform:skewY(45deg); 
        -webkit-transform:skewY(45deg); 
        -o-transform:skewY(45deg); 
        transform:skewY(45deg); 
      } 
      .box img { 
        -ms-transform:skewY(-90deg); 
        -moz-transform:skewY(-90deg); 
        -webkit-transform:skewY(-90deg); 
        -o-transform:skewY(-90deg); 
        transform:skewY(-90deg);
      }
    }
    

    Here’s how to calculate the degrees

    Assuming height: 300px with the narrow side approximately 100px tall and equal angles on the trapezoid. This means the upper and lower offset is (300px - 100px) / 2 = 100px. Then the .box angles are set off the @media query min-width amounts according to this formula:

    Angle = arctan(100/min-width) /*100 is the upper/lower offset as above*/
    

    For the .box img angle take the Angle and multiply by -2. So that will yield your .box and .box img media queries and transforms as this pseudocode:

    @media screen and (min-width: [your target min-width]) { 
      .box {transform: skewY(Angle)}
      .box img {transform: skewY(-2*Angle)}
    }
    

    How smooth it functions depends completely upon how micro scale you make your changes to min-width to get a new angle setting. As I stated in my comment in the CSS code above, my example uses 51 media query calls and still has some choppiness to it.

    Would it be better to use some javascript solution instead… probably, but that is totally up to the designer, so I offer this here as purely a proof of concept that it can be made to work with pure css.

    Original Answer

    This seems to be achieving a fluid width. I don’t know how much control you want of either how much or what part of the image is being shown, so it may not entirely fit your needs, but it does make a flexible width image using transforms to give it a fake perspective look.

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

Sidebar

Related Questions

I'm working on a shopping cart in a website and I have my items(which
I am working on a website that has a menu which behaves correctly on
I have been working on project, to make a website which read files(c/c++ text
I'm working on a website which handles large amounts of data. I have got
So this is pretty specific to a website I am working on. I have
I have just found a nice look that I would like to use for
I'm working on modifying a website which has a chart of FAQs which have
I am working on a website in which the client wishes to have users
I have been working on a multilingual website which has been developed in ASP.net
I'm working on a website which has advert banners which link to external pages.

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.