03111444734

  • How To Write An Essay For Css Exam

Nearpeer is Pakistan’s largest online learning platform. Download our apps to start learning

  • Privacy Policy

Quick Links

  • GOVERNMENT JOBS

Copyrights Nearpeer @ 2024

How to Write an Essay for CSS Exam

#

Written By Haider Ali       Aug 10, 2021

92% of candidates appearing in the CSS examinations, fail the English Essay section. Jarring isn’t it?

If you are planning on taking the dreaded written test soon, then this is a must read post for you. There is an extensive to-do list when it comes to writing an English essay that will get you into that top 8% in this section, and indeed all the strategies cannot be covered in just one short blog post.

What we can do however, to aid you in your journey, is to give you 5 crucial tips that you absolutely MUST follow, as starting guidelines on how to write an essay for CSS English exams.

How to select a topic for the CSS English Essay?

As with any piece of writing, topic selection is perhaps the most crucial aspect, especially if you have a limited amount of time (which you will), to complete a lengthy and well structured essay (which you will have to).

CSS essay topics can broadly fall into one of two categories:

  • Argumentative Essays (Expository Essays)
  • Issue Based Essays

Argumentative essays usually involve an open-ended prompt. You may be given an idea, a proverbial phrase or a quote from a famous personality, and be asked to analyse and assess its applicability.

Examples of argumentative CSS essays include “Gender Equality is a Myth”, “Beware the barrenness of life!” and “Every Cloud has a Silver Lining”, among many others.

Issue based CSS essays tend to focus on important events in the world today, and in that sense are more specific than the former. You may be asked to pen your thoughts on issues of national or global significance, and to suggest possible remedies for the problems at hand.

Examples of issue based essays in the CSS exams include, “Water Crisis and National Unity”, “Feminism is Not Really a Third World Issue” and “Is Colonial Legacy Impeding Pakistan’s Progress?” to name a few.

Your selection of topic could potentially determine from the very start, whether or not your essay will receive a passing grade. Needless to say, one must devise a strategy for doing so.

Our first tip, to help you write a CSS essay, is to know yourself! Sounds simple enough, but candidates often struggle in trying to assess their own strengths and weaknesses. In general keep the following questions in mind, when you’re deciding on which way to go:

For argumentative essays:

  • Do I have a wide breadth of knowledge on the topic? Need examples from different contexts.
  • Am I confident I interpreted the central idea, or meaning of the topic, correctly?
  • Have I practiced enough argumentative essays to appeal to the examiner’s literary/creative tastes?

For issue-based essays:

  • Do I have depth of knowledge on the topic? Need several specific examples for the issue at hand.
  • Do I need/want more room to write creatively, as opposed to such a narrow topic?
  • Do I have information from my studies for other CSS subjects that I can include here?

The Importance of Making a Detailed Outline

We can’t stress this enough, and yes we know you’ve already heard it, but we’re going to say it too: Don’t disregard the outline.

A detailed CSS essay outline consists of 5 or more sections, presented in the form of questions, along with sufficient pointers to build an argument to answer each of the questions. If you have this outline sketched out before your essay, with enough detail that an experienced examiner can get the gist of your arguments by just going through it, you significantly increase your chances of passing.

Oftentimes, with the sheer number of applicants, examiners are overburdened, and will probably not bother with a close reading of your actual essay, if your outline does not interest them, or is unclear. This means, that whether you pass or fail, literally hangs on the effort you put into structuring and writing your outline.

How to Start Your CSS English Essay: The Hook!

Needless to say, the introduction is the second most important structural element, after the outline. You will be rewarded for concisely summarizing your arguments, and laying out the logical flow of the essay here.

Our focus however, is on one particular aspect of the introduction; the “hook” so to speak. As you may have figured out by now, much about how to write a CSS English essay, centers on catching and maintaining the examiner’s attention. For this purpose, the opening line or paragraph of your essay must be impactful, and compel the reader to read on.

Though there are no hard and fast rules, there are 2 strategies for the hook, that we can suggest, based on the experience of successful candidates and our own seasoned CSS teaching faculty:

Start with a hypothetical or anecdotal statement that seeks to transport the reader to a context of your choosing.

  • Practicing descriptive writing can help a lot in this regard. Learn how to create vivid images in the mind of the reader.
  • The opening narration of documentaries can serve as a good example of what an anecdote might look like.
  • Example: “A lone forager cowers under the shade of a Banyan tree as the lightning cracks; trembling from fear, shaking from the cold, she looks out into the cold, desolate plains that stretch into an unforgivingly dark night. She hopes for respite, where there is none to be found...”

Alternatively, depending on your topic, your hook can also employ the use of some jarring statistics or any fact that has some shock value.

  • Remembering specific facts and figures that do not align with the general perceptions of people is useful.
  • Contrasting two seemingly contradictory facts is also a good technique.
  • Examples could include illiteracy statistics, budgetary allocations for particular government sectors, development goals/investment contrasted with actual outcome.

How to Conclude Your CSS English Essay

Your conclusion is also worth spending that extra bit of time on, not just so your essay leaves a lasting impression on the examiner. In fact, as was the case with the introduction and outline, it is quite possible that an examiner will actually read this part while skimming through your CSS essay.

However, unlike the previous two elements, the focus here is not on capturing attention, but on reiterating the logical structure of your arguments, and their links to your given examples. You must clearly delineate how they fit into your arguments and are sufficient to prove your points. That is the entire purpose of the conclusion; to make sure the examiner is convinced that your arguments make sense, and bring together everything of importance that has been discussed in the essay.

Examples for Your Arguments: A Must Have!

Without real world examples, your essay will be doomed to failure. Any claims you make, that are unsubstantiated by evidence, will be disregarded altogether. So think of examples as the stamp of authority on any argument you make.

The ones you can use, generally center around individuals, companies or countries, and can either be from the past, or more contemporary contexts. As long as the chosen example fits well into the argument, there should be no problem.

However, given the diversity of topics that you could encounter in the CSS English exam, it is crucial to know where to find such examples. Although there are potentially unlimited resources for this, a few good places to start are:

  • World History on YouTube.
  • Ted-Ed on Youtube.
  • Local and international news channels .
  • Local newspapers .
  • Official government, media and research institute, accounts on Twitter .

Last but not least, Nearpeer’s English Essay Courses .

CSS English Essay Writing Tips: 

English Essay CSS Syllabus:

Before start your English essay preparation, you first download the CSS English essay syllabus . It is a roadmap for the essay preparation. All Candidates that are appearing in the CSS exam must throughly study the syllabus.

English Essay CSS Past Papers:

Practice makes man perfect. While preparing the essay for the CSS exam you must evaluate yourselves by attempting the CSS English essay past papers . These past papers play very important role to let you know what topics are most commonly asked in the past papers. 

CSS Essay Solved:

Nearpeer is offering a course of CSS solved English past papers so that students can get good grades in their CSS English essay exam. 

The Answers You Need

Do i need to give headings in the css english essay.

No, you do not have to give headings or subheadings in the body of your essay. However, they should be included in the outline, and your essay should follow the structure you have laid out there.

Do I have to make the outline before starting the essay?

Yes. It is absolutely crucial that you make an outline, for reasons we have already discussed above.

Do the words in the outline count towards the word limit?

Yes. The entirety of your essay, outline included, is considered in the overall word count.

Do examiners check the CSS Essay outline?

Absolutely! In fact, in most cases, the outline, introduction and conclusion are the parts of your essay that the examiner will spend 80% of their time on. If your outline isn’t up to the mark, the rest of your essay will most likely not be checked.

Should we write a counter argument as well?

Yes. Part of making a convincing argument is addressing the counter-arguments or points of view that diverge from it. You should ideally dedicate at least 1 to 2 paragraphs on explaining and then logically refuting a counter-argument.

What should be the length of the CSS English essay?

Your essay, outline included, should ideally be between 2500-3000 words.

Does the quality of writing matter in the essay, or just the format?

Both are essential for you to pass your CSS English essay component. The format is one of the first things an examiner looks at. If there are formatting issues, your essay might, again, not be read at all.

However, if you get the format right, but your writing is poor in terms of logical coherence, legibility or language, you will still receive a low score. Focus on both!

Further Guidance

We hope this article gave you sufficient insight into how to begin writing an essay for the CSS exams. However, this is by no means all that you need to know. There is far more nuance to this particular test, and often months of practice and discussion are required to be well-equipped for it, so please do inquire further.

We wish you well on your journey to becoming a CSP officer; if you find yourself a little lost though, feel free to reach out to our round the clock free CSS counselling team at Neapeer.org !

"Enjoyed this article?"

Offered courses.

  • University Courses
  • University Entry Test

CSS Updates Logo

How to Prepare English Essay for CSS & PMS

How to prepare english essay for css.

Essay Preparation For CSS: Essay writing is one of the essential papers, used to determine a candidate’s total CSS Exam result. However, most candidates score lower on this paper due to a lack of literary and intellectual writing skills. An essay paper contains ten topics from which applicants must select one. In this article, we will discuss essay preparation for CSS, word limit, structure, format & how to make notes for English essays.

Essay Word Limit in CSS

The CSS Essay word limit ranges from 2500 to 3500 words on topic.

The Important Points OF ESSAY Writing

Candidates must ensure the following requirements for producing a high-scoring CSS Essay:

  • The essay’s structure.
  • Ideas expressed: The fundamentals of a typical essay.
  • The framework of an essay.
  • Grammar correctness and a broad vocabulary in English are required.

The Format of Essay in CSS

The CSS exam is more than merely scribbling notes and drafting odd ideas. Moreover, A standard essay consists of the following parts:

  • Overview and Context: The introduction tells the reader and introduces the topic.
  • Body Of the Topic: The candidate should write one paragraph regarding one facet of the issue in the body.
  • Summary: The final one or two paragraphs must summarize the entire essay, emphasizing the main points.

How to Make Notes for English Essay for CSS

  • Now that we’ve covered the principles and framework for an essay, the issue remains: how do you collect material for a CSS essay? These are some of the resources for the CSS Essay.
  • Moreover, essays from professionals were published in renowned periodicals and publications. Thus, Recognize and understand the structure of the “Introduction” and “Conclusion” passages. Make notes for your CSS essay by jotting down the key topics.
  • Candidates should review official papers such as the Economic Survey of Pakistan, SBP Quarterly Reports, treaties, and agreements to gather information for their CSS Essay.
  • Candidates should take notes from reports submitted by international institutions such as the World Bank, IMF, ADB, UN, and USAID to score well on the CSS Essay.
  • Candidates can read and take notes on CSS Essays relating to Islamic topics through  Dawn News.
  • The bimonthly print journal Current Affairs covers politics, culture, and the arts. The magazine features intelligent reporting and analysis in every issue.

Want to Buy Top 30 Essay Book? Click here

Similar Posts

CSS International Relations Syllabus

CSS International Relations Syllabus – CSS Syllabus 2025

CSS International Relations Syllabus In this article, we will discuss the CSS International Relations Syllabus in detail. CSS international relations syllabus 2025. CSS IR Syllabus 2025. Syllabus of International Relations in CSS. You can read CSS IR’s latest syllabus. You can also download the CSS International Relations Syllabus from our website in PDF for free….

CSS General Science and Ability Syllabus pdf

Syllabus of CSS General Science and Ability pdf: CSS Syllabus

CSS General Science and Ability Syllabus This article will discuss the CSS general science and ability syllabus in detail. We will also mention the marks allotted for any section in the paper. You can read and get ideas about the CSS general science and ability syllabus. You can also download the pdf syllabus for CSS…

Challenges in CSS Exam

What are the Challenges in the CSS Exam

There are many challenges in CSS exam preparation. The first step to overcome the challenges in the CSS Exam towards a renowned civil service career may appear daunting.

What is PMS Exam in Pakistan

What is PMS Exam?

The Provincial Management Service (PMS) is an essential part of Pakistan’s provincial administration. The PMS exam includes six compulsory subjects, each carrying…

CSS MPT Past Paper 2022

CSS MPT Past Paper 2022: Download CSS MPT Papers

Download CSS MPT Past Paper 2022 CSS MPT Past Paper 2022: The MPT Stands for MCQ-Based Preliminary Test. The CSS (Central Superior Services) MPT is a vital exam for candidates aspiring to join Pakistan’s civil services. The MPT exam consists of 200 marks. This exam is conducted before the main written exam every year. The…

CSS MPT Past Paper 2023 PDF

CSS 2023 MPT Past Paper: CSS MPT

CSS MPT Past Paper 2023 PDF Download If you’re looking for the CSS MPT past paper of 2023, you’re in the right place. The CSS MPT Test 2023 is available here. That will help you prepare for the MPT screening test. You’ll find the syllabus, past papers for compulsory and elective subjects, and more. All…

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Save my name, email, and website in this browser for the next time I comment.

CSS Aspirants

  • CSS Syllabus
  • CSS Past Papers

How to Write an Essay for CSS?

length of essay in css

Writing an essay is obliviously a difficult part of the CSS exam. Most candidates fail in the composition part of the CSS exam because they don’t understand the requirement of the essay. FPSC syllabus provides a detailed understanding of what an examiner wants you to write. Therefore, aspirants have to analyze the given topics and write upon them critically. Writing an essay will be an art if you are able to solve the problems asked by the examiner. Before explaining the mechanics of an essay, let’s have to understand the definition of an essay.

According to Wikipedia, “The word  essay  derives from the French infinitive  essayer , “to try” or “to attempt”. In English  essay  first meant “a trial” or “an attempt”, and this is still an alternative meaning. The Frenchman Michel de Montaigne (1533–1592) was the first author to describe his work as essays; he used the term to characterize these as “attempts” to put his thoughts into writing.”

This means that an essay is a writer’s attempt to solve a problem or issue he is asked for. Or, an essay can be the name of expressing your thoughts on a topic based on a single subject matter. It often gives a personal opinion of the author.

To write an excellent essay, you have to focus on the four components mentioned and explained below. Let us explore and understand them one by one.

This is an essential part of an essay. You can understand the structure, learn grammar and use it accurately, but you would never be able to write an outstanding essay if you lack useful content. A writer without content is like a soldier without a gun. As mentioned earlier, the essay explains the problem and its solution. For this, you have to make your ideas broader, and you have to think out of the box. Then and only then, you would critically analyze a problem and jot it down on a piece of paper.

Read books that you find subject-oriented to your topics. Read magazines, newspapers, and research papers. These sources will help you build the content which is required for an essay later. 

Remember! Do not read books only. Those who read and accept are called consumeristic mindsets. They never come out of the box; rather, they acknowledge what they have read or seen. Instead, be a critical and keen observer while reading. It will make you competitive, critical, and creative enough that you would see unseen as well.

Structure 

The second essential component of writing an essay is its structure. An essay cannot be written randomly without any structure; instead, it needs to be fixed in a frame that gives a systematic view to a reader. The structure of an essay has three main parts: the introduction, the body, and the conclusion, and let us understand each one individually.

Introduction (10% of an essay)

This is the first paragraph of an essay. The introduction of an essay introduces the topic that has to be explained later; it has two jobs to do. First, it tells the reader or examiner what the essay is all about. Second, it grabs the reader’s or examiner’s attention at the very beginning of an essay so that he stays till last.

There are three additional elements to be focused on in the introduction: the motivator/hook, bridge, and thesis statement.

A motivator or hook  is a statement that a writer uses to attract his reader or examiner. He uses quotations, famous sayings, questions, proverbs, facts, or short stories that win the reader’s interest.

The element in an introduction is called  a bridge . It helps the writer to connect his motivator or hook to the main idea. He brings the reader to the point where he is going to explain his opinion. In short, it brings the reader towards the exact topic.

The last element in the introduction of an essay is called  Thesis Statement . This statement offers the purpose and concise summary of an overall essay, and it shows a road map to the reader that he will go through in the body of an essay. Briefly explain in one or two statements what your essay is all about and the purpose of your essay.

Remember! A good introduction will always give you a good essay. 

Body (80% of an essay)

After you have written a wonderful introduction, now is the time to expand your introduction into greater detail. The body is composed of paragraphs that support the main idea you have introduced at the start of your essay.

Each paragraph should have a  clincher statement  at the end, and it resolves whatever questions or claims were previously put forth. It should not end the topic ultimately; rather, it should connect the upcoming paragraph in a way that the reader thinks that the previous paragraph was a prerequisite of the next one.

You can support your main idea with facts and figures, reasons, references, case studies, etc. there is another formula used for supporting the main idea, which is called  FRIES.  Here, “F” stands for the facts that you can provide to your topic, “R” stands for reasons, “I” stands for incidence, “E” stands for examples, and “S” stands for statistics. All these elements or some of them can help you strengthen your reasoning in an essay. Use them gently and be authentic.

Indeed, the primary goal of solving a problem or issue given in the topic should not be forgotten.

Conclusion (10% of an essay)

Last but not least is the conclusion of an essay. Your conclusion should do two jobs. First, it should provide a summarized view of the essay. In other words, it should reflect what you have introduced in the beginning. Second, it should predict the future aspects. If your essay didn’t solve a problem or express a topic with the writer’s opinion, it should not be called an essay. The conclusion of an essay should briefly show the prediction of the topic.

Grammar 

The third essential component of an essay is grammar. You should have sound grammar to use in your writing. If you don know good grammar, you would be unable to write an excellent essay. You would never know what you have written correctly and what you have written wrong. There are some grammar topics that we recommend you improve one by one.

Tenses:  This is the first area of grammar that provides you with an understanding of the time perspective of a sentence. Learn them first of all as they are heavily used in the best part of the grammar.

Parts of Speech:   Many aspirants take them easy. Some of them just read them and cram the definition of parts of speech. Remember! There is a difference between one who knows the definition and one who knows the actual use. Be the latter one so that you use them conceptually.

Narrations:  Writing heavily deals with narration. You should have a great command of direct and indirect narration, and it will help you to use them whenever required in writing correctly.

Conditionals:  Most people get confused when they are using conditionals. Remember that each conditional has syntax semantics and pragmatics, and use them correctly when writing.

Types of sentences:  You should improve the types of sentences. For example, affirmative, optative, imperative, interrogative, and explanatory sentences will help you have a better understanding of them while writing.

Forms of the sentence:  There are four primary forms of a sentence: simple, compound, complex and compound-complex. This is the most essential part of written communication. Sometimes, aspirants think that they have written an outstanding essay without any grammatical mistakes, but they are unable to rectify structural mistakes.

Phrases:  Phrases are important to be studied. They are used as different parts of speech, and learning them will prevent you from committing mistakes in big units.

Clauses:  Clauses provide a real understanding of a sentence. If you have a great command of clauses, you will use them correctly without any structural mistakes.

Punctuations:  Punctuations can give a great sense or can completely destroy the meanings. Knowing punctuation for writing an essay is very necessary, and you can inspire your examiner or reader if you know the great use of punctuation.

These areas of grammar must be good enough for writing a brilliant essay. If you know them yourself, you can easily take out your mistakes.

Instructions to be followed while writing an essay

The fourth essential component of an essay is the instructions that serve as necessary principles in an essay. Below are some principles or instructions that should be understood while writing an essay.

Objective approach

When you start writing an essay, you first deal with the title of an essay. Capturing the exact meanings in the beginning is very important. Have an objective approach so that you stay on track.

Unity 

This refers to the oneness. All paragraphs in an essay should be related, and it must show that the paragraphs written in an essay come from one family.

Coherence 

Chaining between sentences is called coherence. Each sentence should be accurately connected with one another in a meaningful manner, and every previous sentence should look like it was a pre-requisite for the next one. To gain coherence, use transitional words.

Order 

Write all ideas in a logical order. Your reader should see the most important points in the beginning and the weaker ones later. You should have a chronological order of ideas in your essay.

Varity 

Variety refers to the change of words, examples, and thoughts for one topic. It often bores the readers when you repeatedly use the exact words, ideas, or examples for one topic again and again.

Writing three thousand words in the CSS exam would never mean that you should exaggerate unnecessary words. In other words, it refers to the addition of adverbs and adjectives that are unnecessarily coming in your writing. Be brief. You can add a variety of examples but not too many adjectives and adverbs. The more you write a brief, the clearer it will be to the readers.

All these are the tips and tricks that can help you write an excellent essay. Read books because they will always broaden your ideas. Look at sample essays or books of essays that provide a better understanding of the expert’s work. If you need CSS books , or even past papers and FPSC Syllabus that can build your content for the CSS exam, contact us now , and we will deliver them free of cost.

' src=

A fresh graduate, With a mindset to bring ease to all of those Aspirants who want to be CSPs! Not that boring, I love to eat, travel, and have fun with mates too :)

2 thoughts on “ How to Write an Essay for CSS? ”

' src=

It’s very helpful 👍 thanks alot. I need css books and syllabus and past papers please help me.

' src=

I am glad you enjoyed this quick guide, Rukhsana. For Books, Syllabus & Past papers please check our main menu or directly contact us on WhatsApp. Thank You!

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Save my name, email, and website in this browser for the next time I comment.

Username or email address  *

Password  *

Remember me Log in

Lost your password?

  • Privacy Policy
  • Our Authors
  • Subscribe Us
  • Google Plus

CSS Times

How to Prepare English Essay for CSS / PMS? By: Iqra Shaukat (46th CTP)

How to Prepare English Essay for CSS PMS By Iqra Shaukat (46th CTP)

Essay means ‘attempt’ to translate your ideas into words. There is a myth before writing actual essay we must be well versed in the hard-core knowledge of contemporary topics , but the reality is; it is skill which can be learned from practice only. Now the BIG QUESTION is how to practice it, especially in case of non-availability of evaluator, for this I recommend better to start from scratch through the 3-body essay , i.e. introduction, body and conclusion . You can find this sort of short essay on daily basis from daily diaries ( DAWN, EXPRESS TRIBUNE or THE NEWS INTERNATIONAL ) in form of editorials and opinions. The only way to learn it at your own is to paraphrase it on daily basis. I guarantee this will serve the purpose well. Through this regular exercise your expression will improve, you will learn new vocabulary words and the usage of words both in connotative and denotative. You must consult one basic English grammar book (I consulted ‘ To the point English by Mian Aftab ’ in the beginning later on I consulted ‘ Exploring the world of English by Sadaat ), while practicing you must know the basic rules of grammar. The bottom line is; one paragraph on daily basis – the mixture of theory and practice- can be handy to horn your English writing skill .

Secondly, for well-structured essay you need to learn, how to formulate outlines ? The art of outlines writing would help you to get coherence, organization, and clarity. In order to get command on the outlines, you must know the skill of mind maps. For outlines formulation, read detailed articles from magazines and make outlines from it. There must be structure in your essay outlines . Outlines of essay must be start from introduction followed by body of essay where sub-headings of body paragraph and lastly conclusion. I used to divide my outlines in three heads:

1. Introduction a. Preface b. What is what c. Historical perspective d. Current essay

2. Body of essay a. Establishment of facts b. Causes c. Impacts

3. Conclusion a. Steps already taken b. Further measures c. Concluding lines

Last but not the least, you no longer need to write full length essay of 3000 words on regular basis. What you need to do is to write introduction, outlines, establishment of facts and conclusion. Do this practice from past papers and get it checked from senior or your mentor on regular basis.

In case of any question leave message here.

About the author

length of essay in css

Iqra Shaukat

The writer has passed css 2017 and got allocation in IRS- Inland Revenue Service. She did her BSc (Hons.). in Applied Management from GCU and MA english literature from Punjab university, with specialisation in linguistic. Currently , she is teaching CSS English Essay at Ensemble CSS Academy.

You may also like

Daily DAWN News Vocabulary with Urdu Meaning (03 Apr 2024)

Daily DAWN News Vocabulary with Urdu Meaning (04 Apr...

Daily DAWN News Vocabulary with Urdu Meaning (26 Mar 2024)

Daily DAWN News Vocabulary with Urdu Meaning (26 Mar...

Daily DAWN News Vocabulary with Urdu Meaning (14 Feb 2024)

Daily DAWN News Vocabulary with Urdu Meaning (14 Feb...

10 Habits for CSS Toppers Ace the CSS Smoothly

10 Habits for CSS Toppers: Ace the CSS Smoothly

Daily Top-10 Current Affairs MCQs / News (January 20 2024) for CSS

Daily Top-10 Current Affairs MCQs / News (January 20...

Essay Outline: Electoral Reforms in Pakistan: Necessity and Challenges

Essay Outline: Electoral Reforms in Pakistan:...

Leave a comment x.

One and half page

Based on facts

CSS Tutorial

Css advanced, css responsive, css examples, css references.

You can test your CSS skills with W3Schools' Quiz.

The test contains 25 questions and there is no time limit. 

The test is not official, it's just a nice way to see how much you know, or don't know, about CSS.

Count Your Score

You will get 1 point for each correct answer. At the end of the Quiz, your total score will be displayed. Maximum score is 25 points.

Start the Quiz

Start the CSS Quiz ❯

If you don't know CSS, we suggest that you read our CSS Tutorial from scratch.

Kickstart your career

Get certified by completing the course

Get Certified

COLOR PICKER

colorpicker

Contact Sales

If you want to use W3Schools services as an educational institution, team or enterprise, send us an e-mail: [email protected]

Report Error

If you want to report an error, or if you want to make a suggestion, send us an e-mail: [email protected]

Top Tutorials

Top references, top examples, get certified.

SuperiorExams

Online Preparation Of Government Jobs Examination

CSS PMS English Essay Complete Preparation Material

CSS PMS English Essay holds the key, to get success in competitive exams. In fact, most of the students get failed in CSS or PMS in English Essay, even the candidates who have done Masters’s in English Literature. The question comes why?

Besides, writing correct English, passing the essay paper requires writing technique, skill, and practice. Most CSS or PMS candidates do not acquire competent guidelines, as a result, their dream not come true to become a bureaucrat.

Table of Contents

Types of CSS PMS English Essay?

Writing is a skill, and without mastering the skill no one can claim the surety of success. In most cases, CSS or PMS candidates consider that passing the English Essay paper depends upon luck, but this is not the reality. One also has to master English Precis & Composition in order to understand better English Essays.

Remember that, in competitive exams mostly three types of essays are asked; Argumentative , Explanatory , and Quotation .

An argumentative essay requires complete evidence and you must support your answer with logical reasons and claims. This type of essay needs evidence in the shape of fact, figure, example, or explanation.

The explanatory essay does not require evidence and support, you just need to give a general examples and detailed writing on the given topic.

A quotation topic essay requires a piece of detailed knowledge and material about the specific quote, and usually after few pages the content of the candidate dries.

Why do Candidates fail CSS PMS English Essay?

First of all, understanding the topic is the most important thing which is not done by most of the candidates. In case if you know the content about two topics then it is better to write down the outlines of two essays and then finalize which one is to be attempted.

“Global Warming, a fact or fiction.” (CSS 2008)

If you encounter an essay such as stated above in the exam, you need to support one logic; either fact or fiction. Do not try to prove both, because in the statement there is “or”. Furthermore, you must support your answer by presenting facts, figures, and logical reasoning to claim your point of view.

Sometimes, essays like “Democracy is a culture rather than a process (CSS 2012) come into the exam. This kind of topic needs content proving democracy is a culture in developing countries and it is a process in developed countries. There is a great chance that you may differ a lot in your opinions and your essay might be full of controversial statements. So, it is better to avoid these kinds of essays.

In 2013, “Meaning and purpose of education” was the hot topic written by most of the candidates. A lot of students failed because somehow they wrote the crammed essay based on causes and effects but the examiner had asked them to write about the meaning and purpose of education.

CSS PMS English Essay Preparation Material

Foreign Author Books
Bertrand Russel’s Sceptical Essays
How To Write Great Essays By Lauren Starkey
Essay writing for English Test By Gabi Duigu
Essay Writing A Students Guide by MunLing Shields
Human Rights & Democracy
CSS PMS English Essay Material
CSS PMS Essay Material
Essay Material for CSS PMS
List Of Important Topics of CSS PMS Essays
Contemporary CSS PMS English Essay
Winning Essays For CSS & PMS
How To Write A CSS PMS Comparative Essay
Pakistan’s Institutions: An Outlook
Literature Is The Best Criticism OF Life
Judicial Activism OR Democratic Consolidation
Evolution OF Judicial System In Pakistan
Democracy And Judicial Conflict In Pakistan
Critical Analysis of Education System In Pakistan
Are Modern Wars Holy Wars?

How To Pass CSS PMS English Essay?

A good CSS PMS English Essay contains;

  • No grammatical errors.
  • Every relevant aspect of the topic should be discussed.
  • Proper paragraphing. (Every next paragraph should take the discussion forward. Do not explain the same point repeatedly).
  • Proper coherence and cohesion between the paragraphs and ideas.
  • Organized and united content presentation. (It should not be haphazard written work, its different parts should be joined to form a beautiful structure).
  • Do not negate your arguments in the middle of the essay or in the end. (You should be reasonable where ever you have to prove a point to express an opinion).
  • Avoid repetition of words, sentences, and ideas.
  • Use minimum words which can express an idea.
  • Your writing should be idiomatic.

Best Structure For A CSS PMS English Essay

Every CSS PMS English Essay paper invariably contains such kinds of topics on which a reasonable candidate can write an essay, such as; a current affair topic, literary topic, or a past paper look-alike topic. After selecting the topic, think hard to ascertain its true meaning. The incorrect meaning will surely lead you to write an irrelevant essay.

Remember that an essay has three parts; An introduction , a main body , and a conclusion . An outline shall be made to give an overall view of all of your content.

How To Make An Outline?

It is a structure that shows the content in paraphrased sentences for each paragraph. This is how you mentally capture the entire essay from start to finish. A simple causes and effects essay can have an outline such as;

“Energy Crisis: Causes and Effects”

Introduction

  • Energy, a lifeline.
  • Demand and supply gap.
  • No major projects were undertaken by previous governments.
  • Failure to increase the generating capacity.
  • The problem of circular debt.
  • Closure of industrial units.
  • Unemployment.
  • Effects on the social and economic condition of the country.

Suggestions

  • Resolving the circular debt.
  • Building small power plants.
  • The capital cost of new plants.

Sometimes, essay like “Country life is better than city life” was asked. In this case, you must make an outline having two major headings; one is country life and another one is city life. These main headings must have pros and cons of living life there as subheadings.

How To Write an Introduction?

  • The argumentative essay starts with a starter and thesis statement at the start of an essay. The thesis statement, short and precise, is the idea of what the student is going to prove in his/her essays. Most of the time in an argumentative essay, where there are causes, effects, and suggestions, students can write these causes, effects, and suggestions in their thesis statement.
  • For example, the thesis statement of the poverty essay can be: Poverty in Pakistan is a multifaceted problem deeply rooted in its socio-political and economic structure of governance. The lack of effective political and economic governance is adversely hampering efforts to cut rising poverty. ·
  • Another example of a starter of a Corruption essay can be: Corruption exists in one form or another in all societies. The major difference in the case of Pakistan (or perhaps South Asia) is the extent of its pervasiveness and its implications for governance and the value system in general and the political culture in particular.
  • After that, explain it and the length of an essay should be one page of A4 size.

How To Write Body of An Essay?

  • After writing an introduction, students need to write the causes in each paragraph. If the essay is Poverty, causes, effects, and suggestions then you must write down the cause of poverty first.
  • For example, the first cause of poverty is feudalism. In this paragraph, write such type of start-up paragraph which student can easily justify in his paragraph.
  • For feudalism, you can write the opening sentence of a paragraph as; Since the independence of Pakistan, feudal lords hijack this country by exerting their influence in all fields of life as they are MPAs, MNAs, Ministers, P.Ms, and Presidents.
  • After writing the opening paragraph, you have the option to give a fact or figure with an example or explain this idea. For example, you can justify by saying that: More than 60-70% of our land is occupied by feudal lords (22 families) while the rest population (190m) has 20-30% land resulting in the shape of equal distribution of income. That is why poverty is increasing day by day as our major income is in the hands of 22 families who hold 60-70 % of our land.
  • Similarly, you are supposed to write other causes in different paragraphs.
  • After writing causes in 7 or 8 paragraphs then students need to write effects in 4 to 5 paragraphs as effects paragraphs do not have an argument and its justification.
  • After that, give suggestions in 3 to 4 paragraphs by using different words like should, must, ought to, it is the need of the hour, it is high time, etc.

How To Write The Conclusion Of An Essay

  • In the conclusion, write with the words such as Finally, Lastly, In conclusion, To conclude this, To summarise, In summary, In sum, etc.
  • In the conclusion, paraphrase your thesis statement and justify your argument which you have developed in the introduction.
  • The end of the paragraph should be very positive as one hopes, one wishes, one prays that Pakistan will be able to overcome this problem if practical policies are implemented.

Explanatory Essays

  • These are those essays that do not need argument and justification.
  • Such essays consist of prerequisites, general examples, and more focus on explanation.
  • Essays such type can be:
  • Country life is better than city life .
  • Meaning and purpose of education.
  • The pleasures of reading.
  • All humans are born equal in dignity and rights but they are m shackles everywhere.
  • Dialogue is the best course to combat terrorism.
  • Such essays should be solved according to their key terms. For example, if there is an essay on The pleasure of Reading then those students can write who have the habit of book reading and they know what are its benefits, how it contributes towards knowledge increase, etc.

Techniques How To Deal with Different Topics of CSS PMS English Essay

  • Essay like Dialogue is the best course to combat terrorism or great nations win without fighting (CSS-2014) need to elaborate on the importance of dialogue as it is necessary because it avoids bloodshed, wastage of resources, weakening economy, loss of human being, damage to infrastructure as nations have to conclude dialogue even at the end of the war. !fit is necessary at the end why there is a need for war’?
  • In this way, students after writing and developing the significance of dialogue can write the examples of the world like the Soviet Union, and the US withdrawal from Afghanistan.
  • In such essays, the student has to convince the examiners of the role of dialogue rather than launching a war.
  • Essay like Can the Third World War be prevented? (CSS-2008) or Can women be equal to men in Pakistan? (CSS-2010). The student has the option to prove it that is possible or not. If yes, then give your argument in a logical way, only take one side of the picture, and do not try to prove both sides.
  • In 20 l 4, an Essay on dialogue was asked. The context was the withdrawal of the US from Afghanistan and there were a number of articles in Dawn about Dialogue and Peace. Such questions appear in Newspapers like Dawn where students can prepare easily.
  • In 2015, Human rights violation and the war on terror was asked. Students of International Law can attempt it because they have read it in their syllabus. In short, the Top 30 Essay books and Newspaper before 4 to 5 months of the exams can be beneficial to get higher marks.

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Save my name, email, and website in this browser for the next time I comment.

[ Placeholder content for popup link ] WordPress Download Manager - Best Download Management Plugin

  • Stack Overflow for Teams Where developers & technologists share private knowledge with coworkers
  • Advertising & Talent Reach devs & technologists worldwide about your product, service or employer brand
  • OverflowAI GenAI features for Teams
  • OverflowAPI Train & fine-tune LLMs
  • Labs The future of collective knowledge sharing
  • About the company Visit the blog

Collectives™ on Stack Overflow

Find centralized, trusted content and collaborate around the technologies you use most.

Q&A for work

Connect and share knowledge within a single location that is structured and easy to search.

Get early access and see previews of new features.

Limit text length to n lines using CSS

Is it possible to limit a text length to "n" lines using CSS (or cut it when overflows vertically).

text-overflow: ellipsis; only works for 1 line text.

original text:

Ultrices natoque mus mattis, aliquam, cras in pellentesque tincidunt elit purus lectus, vel ut aliquet, elementum nunc nunc rhoncus placerat urna! Sit est sed! Ut penatibus turpis mus tincidunt! Dapibus sed aenean, magna sagittis, lorem velit

wanted output (2 lines):

Ultrices natoque mus mattis, aliquam, cras in pellentesque tincidunt elit purus lectus, vel ut aliquet, elementum...
  • 4 Just a note: text-overflow ellipsis isn't supported on Firefox, see bugzilla.mozilla.org/show_bug.cgi?id=312156 –  Joril Commented Jan 12, 2011 at 11:11
  • doesn't work on IE10. It works on 11. –  user2060451 Commented Apr 21, 2014 at 7:10
  • @GauravShah Thank you. It works on IE10 as well. Most of the solutions here are not cross browser. –  user2060451 Commented Apr 21, 2014 at 7:17
  • 1 Related: stackoverflow.com/questions/5269713/css-ellipsis-on-second-line –  AlikElzin-kilaka Commented Dec 9, 2015 at 11:21
  • @GauravShah 's link doesn't work anymore. (and it's not foundable on the main web archives) Here is the closest alternative that's I've found (it says it's based on aforementioned link) github.com/ericdrowell/Pure-CSS-Multiline-Ellipsis –  tuxayo Commented Aug 10, 2017 at 9:26

21 Answers 21

There's a way to do it using unofficial line-clamp syntax, and starting with Firefox 68 it works in all major browsers.

body { margin: 20px; } .text { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; /* number of lines to show */ line-clamp: 2; -webkit-box-orient: vertical; } <div class="text"> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam consectetur venenatis blandit. Praesent vehicula, libero non pretium vulputate, lacus arcu facilisis lectus, sed feugiat tellus nulla eu dolor. Nulla porta bibendum lectus quis euismod. Aliquam volutpat ultricies porttitor. Cras risus nisi, accumsan vel cursus ut, sollicitudin vitae dolor. Fusce scelerisque eleifend lectus in bibendum. Suspendisse lacinia egestas felis a volutpat. </div>

Unless you care about IE users, there is no need to do line-height and max-height fallbacks.

  • 4 for example, with certain font-size to line-height, you can see part of the next line also with text-align:justify, the ellipsis is not at the end of the last line, but overlaps the text at the position, it would be, if the text was aligned to left –  Matus Commented Nov 15, 2013 at 14:13
  • 7 here's the fiddle: jsfiddle.net/csYjC/1122 while I was preparing it, I found out, that part of last line is only visible when there is padding –  Matus Commented Nov 16, 2013 at 9:25
  • 2 Well, nobody said this non-standard webkit-only black magic is going to work perfectly all the time. You can use padding on some other, perhaps parent, container. Wripping text in <p> tag makes perfect sense: jsfiddle.net/csYjC/1129 –  Evgeny Commented Nov 18, 2013 at 20:50
  • 7 Note that, as of this comment, -webkit-line-clamp does not respect visibility: hidden. This cost me a few hours debugging. Here's a supporting bug report: bugs.webkit.org/show_bug.cgi?id=45399 . –  Kevin Commented Oct 29, 2014 at 12:50
  • 9 If you're having issues with -webkit-box-orient: vertical; being hidden when compiling scss try this /* autoprefixer: ignore next */ -webkit-box-orient: vertical; –  Salam Commented Jan 10, 2019 at 11:39

What you can do is the following:

.max-lines { display: block;/* or inline-block */ text-overflow: ellipsis; word-wrap: break-word; overflow: hidden; max-height: 3.6em; line-height: 1.8em; } <p class="max-lines">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc vitae leo dapibus, accumsan lorem eleifend, pharetra quam. Quisque vestibulum commodo justo, eleifend mollis enim blandit eu. Aenean hendrerit nisl et elit maximus finibus. Suspendisse scelerisque consectetur nisl mollis scelerisque.</p>

where max-height: = line-height: × <number-of-lines> in em .

  • 54 Is working like text-overflow: clip, as its not showing (...) –  rishiAgar Commented Jul 26, 2016 at 13:56
  • 1 Seems to be the best possible solution for me also, but as @rishiAgar noted does not end with ellipsis. Continues to function like clip. –  David Carrigan Commented Oct 12, 2016 at 3:04
  • 8 I believe you'll have to add the attributes display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; to make the ellipsis appear. But this will only work in Chrome. For solution that work on Firefox as well, look here: stackoverflow.com/a/20595073/1884158 And here is a helpful tutorial on the subject: css-tricks.com/line-clampin –  modulitos Commented Aug 30, 2017 at 23:02
  • 2 Too bad the ellipsis is not working with your solution... –  Medhi Commented Apr 21, 2022 at 16:58
  • Adding white-space property will make the ellipsis appear see: stackoverflow.com/questions/7993067/… , however it can only work with 1 line of text. –  Jared Rice Commented Jan 12 at 21:18

Working Cross-browser Solution

This problem has been plaguing us all for years.

To help in all cases, I have laid out the CSS only approach, and a jQuery approach in case the css caveats are a problem.

Here's a CSS only solution I came up with that works in all circumstances, with a few minor caveats.

The basics are simple, it hides the overflow of the span, and sets the max height based on the line height as suggested by Eugene Xa.

Then there is a pseudo class after the containing div that places the ellipsis nicely.

This solution will always place the ellipsis, regardless if there is need for it.

If the last line ends with an ending sentence, you will end up with four dots....

You will need to be happy with justified text alignment.

The ellipsis will be to the right of the text, which can look sloppy.

Code + Snippet

.text { position: relative; font-size: 14px; color: black; width: 250px; /* Could be anything you like. */ } .text-concat { position: relative; display: inline-block; word-wrap: break-word; overflow: hidden; max-height: 3.6em; /* (Number of lines you want visible) * (line-height) */ line-height: 1.2em; text-align:justify; } .text.ellipsis::after { content: "..."; position: absolute; right: -12px; bottom: 4px; } /* Right and bottom for the psudo class are px based on various factors, font-size etc... Tweak for your own needs. */ <div class="text ellipsis"> <span class="text-concat"> Lorem ipsum dolor sit amet, nibh eleifend cu his, porro fugit mandamus no mea. Sit tale facete voluptatum ea, ad sumo altera scripta per, eius ullum feugait id duo. At nominavi pericula persecuti ius, sea at sonet tincidunt, cu posse facilisis eos. Aliquid philosophia contentiones id eos, per cu atqui option disputationi, no vis nobis vidisse. Eu has mentitum conclusionemque, primis deterruisset est in. Virtute feugait ei vim. Commune honestatis accommodare pri ex. Ut est civibus accusam, pro principes conceptam ei, et duo case veniam. Partiendo concludaturque at duo. Ei eirmod verear consequuntur pri. Esse malis facilisis ex vix, cu hinc suavitate scriptorem pri. </span> </div>

jQuery Approach

In my opinion this is the best solution, but not everyone can use JS. Basically, the jQuery will check any .text element, and if there are more chars than the preset max var, it will cut the rest off and add an ellipsis.

There are no caveats to this approach, however this code example is meant only to demonstrate the basic idea - I wouldn't use this in production without improving on it for a two reasons:

1) It will rewrite the inner html of .text elems. whether needed or not. 2) It does no test to check that the inner html has no nested elems - so you are relying a lot on the author to use the .text correctly.

Thanks for the catch @markzzz

Code & Snippet

setTimeout(function() { var max = 200; var tot, str; $('.text').each(function() { str = String($(this).html()); tot = str.length; str = (tot <= max) ? str : str.substring(0,(max + 1))+"..."; $(this).html(str); }); },500); // Delayed for example only. .text { position: relative; font-size: 14px; color: black; font-family: sans-serif; width: 250px; /* Could be anything you like. */ } <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> <p class="text"> Old men tend to forget what thought was like in their youth; they forget the quickness of the mental jump, the daring of the youthful intuition, the agility of the fresh insight. They become accustomed to the more plodding varieties of reason, and because this is more than made up by the accumulation of experience, old men think themselves wiser than the young. </p> <p class="text"> Old men tend to forget what thought was like in their youth; </p> <!-- Working Cross-browser Solution This is a jQuery approach to limiting a body of text to n words, and end with an ellipsis -->

  • 6 Your css solution is not so good, becouse what about case that text is not overflow? it is also show "..."... –  user5260143 Commented Dec 26, 2016 at 9:08
  • But also the jQuery version adds dots if the text is shorter: jsfiddle.net/o82opadm/35 –  markzzz Commented Aug 11, 2017 at 14:45
  • @markzzz - thanks for that, no idea how I missed it :-) I revised it now, but it's not something I would use in production without a bit more work. But at least the basic idea is laid out. –  asimovwasright Commented Oct 13, 2017 at 8:24
  • 1 I found that the CSS-only solution seems to work well, but only if you use only pixel measurements. EMs and percentages got me into trouble. And I added the ellipsis as an <a> styled to position:absolute in the bottom right for those who want to click the link and read more. In my case I knew the text would always overflow, so jQuery was not necessary. Thanks for the useful CSS solution! –  Mentalist Commented Oct 23, 2018 at 0:23

The following CSS class restricts text to two lines, and inserts an ellipsis to indicate overflowing text.

.two-line-ellipsis { overflow: hidden; width: 100%; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; } <div class="two-line-ellipsis">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec in ex sit amet diam efficitur pellentesque. Mauris posuere scelerisque libero, nec pretium mauris molestie non. Nulla aliquam sollicitudin egestas. Fusce aliquet elit vitae mi volutpat vehicula. Vestibulum vel sapien enim. Nulla eu volutpat ex, ac faucibus urna. Etiam mattis rutrum ullamcorper. Ut sagittis, erat sit amet vulputate commodo, nisl lacus aliquet magna, vel condimentum ante felis rutrum nibh. Suspendisse ut lorem rutrum, molestie velit eget, hendrerit lorem. Vivamus rutrum nunc elit, nec lacinia risus viverra ut.</div>

As far as I can see, this would be possible only using height: (some em value); overflow: hidden and even then it wouldn't have the fancy ... at the end.

If that is not an option, I think it's impossible without some server side pre-processing (difficult because text flow is impossible to predict reliably) or jQuery (possible but probably complicated).

  • 17 This seems to work for any font-size .mytext { overflow:hidden; line-height: 1.2em; max-height: 2.4em; } –  Peter Commented Oct 13, 2010 at 10:44
  • 1 @Pedro yeah. You might be able to run through each .mytext using jQuery, find out whether it has more content than is visible, and add a ... manually. That way, you are compatible to clients with no JS, and clients with JS can have the decoration. Maybe worth a separate question for a jQuery Guru to answer; might be possible to do relatively easily –  Pekka Commented Oct 13, 2010 at 10:52

2024 UPDATE: Shorter Approach

This is according to Tailwind CSS 3.4+ wherein you can use the utility line-clamp-* but below is the css version.

div { width: 200px; } p { overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; } <div> <p> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore </p> <div>

Browser-safe approach with fallbacks:

div { width: 200px; } p { display: block; /* Fallback for non-webkit */ display: -webkit-box; height: 2.6em; /* Fallback for non-webkit, line-height * 2 */ line-height: 1.3em; -webkit-line-clamp: 2; /* if you change this, make sure to change the fallback line-height and height */ -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis; } <div> <p> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore </p> <div>

  • 2 This is really the best way, as it seems to support any number of lines. –  machineghost Commented Apr 5 at 23:10

The solution from this thread is to use the jquery plugin dotdotdot . Not a CSS solution, but it gives you a lot of options for "read more" links, dynamic resizing etc.

For React users, with inline styles:

Currently you can't, but in future you will be able to use text-overflow:ellipis-lastline . Currently it's available with vendor prefix in Opera 10.60+: example

  • 5 That doesn't work for multiline strings, as it requires also to set white-scace: nowrap. See here . –  Sebastian Noack Commented Dec 13, 2011 at 9:34

I have a solution which works well but instead an ellipsis it uses a gradient. It works when you have dynamic text so you don't know if it will be long enough to need an ellipse. The advantages are that you don't have to do any JavaScript calculations and it works for variable width containers including table cells and is cross-browser. It uses a couple of extra divs, but it's very easy to implement.

blog post: http://salzerdesign.com/blog/?p=453

example page: http://salzerdesign.com/test/fade.html

As of (almost) 2023, some older css rules are no longer needed.

These show the minimum required, and work cross browser despite the prefixed syntax:

There was a case in which this next solution worked for me in a span where I needed to cut long emails short:

If you are running into horizontal text clipping issues, it probably has to do with the use of overflow: hidden combined with line-height . Try using this min-height solution below, that uses CSS variables with calc to dummy-proof it a little.

NOTE: This is not vertically responsive. Meaning, that it has a set height, and if the text content is less than the --lines , the container will not shrink accordingly.

I really like line-clamp, but no support for firefox yet.. so i go with a math calc and just hide the overflow

now lets say you want to remove and add this class via jQuery with a link, you will need to have an extra pixel so the max-height it will be 63 px, this is because you need to check every time if the height greather than 62px, but in the case of 4 lines you will get a false true, so an extra pixel will fix this and it will no create any extra problems

i will paste a coffeescript for this just to be an example, uses a couple of links that are hidden by default, with classes read-more and read-less, it will remove the ones that the overflow is not need it and remove the body-overflow classes

  • by the way, don't add line-clamp to this, it will set the height to 62px(for this case) and you will not have the jquery comprabation –  Alexis Commented Apr 21, 2015 at 14:13

If you want to focus on each letter you can do like that, I refer to this question

function truncate(source, size) { return source.length > size ? source.slice(0, size - 1) + "…" : source; } var text = truncate('Truncate text to fit in 3 lines', 14); console.log(text);

If you want to focus on each word you can do like that + space

const truncate = (title, limit = 14) => { // 14 IS DEFAULT ARGUMENT const newTitle = []; if (title.length > limit) { title.split(' ').reduce((acc, cur) => { if (acc + cur.length <= limit) { newTitle.push(cur); } return acc + cur.length; }, 0); return newTitle.join(' ') + '...' } return title; } var text = truncate('Truncate text to fit in 3 lines', 14); console.log(text);

If you want to focus on each word you can do like that + without space

const truncate = (title, limit = 14) => { // 14 IS DEFAULT ARGUMENT const newTitle = []; if (title.length > limit) { Array.prototype.slice.call(title).reduce((acc, cur) => { if (acc + cur.length <= limit) { newTitle.push(cur); } return acc + cur.length; }, 0); return newTitle.join('') + '...' } return title; } var text = truncate('Truncate text to fit in 3 lines', 14); console.log(text);

enter image description here

  • 1 Please read How do I write a good answer? . While this code block may answer the OP's question, this answer would be much more useful if you explain how this code is different from the code in the question, what you've changed, why you've changed it and why that solves the problem without introducing others. –  Saeed Zhiany Commented Jun 19, 2022 at 4:17

Basic Example Code, learning to code is easy. Check Style CSS comments.

table tr { display: flex; } table tr td { /* start */ display: inline-block; /* <- Prevent <tr> in a display css */ text-overflow: ellipsis; white-space: nowrap; /* end */ padding: 10px; width: 150px; /* Space size limit */ border: 1px solid black; overflow: hidden; } <table> <tbody> <tr> <td> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla egestas erat ut luctus posuere. Praesent et commodo eros. Vestibulum eu nisl vel dui ultrices ultricies vel in tellus. </td> <td> Praesent vitae tempus nulla. Donec vel porta velit. Fusce mattis enim ex. Mauris eu malesuada ante. Aenean id aliquet leo, nec ultricies tortor. Curabitur non mollis elit. Morbi euismod ante sit amet iaculis pharetra. Mauris id ultricies urna. Cras ut nisi dolor. Curabitur tellus erat, condimentum ac enim non, varius tempor nisi. Donec dapibus justo odio, sed consequat eros feugiat feugiat. </td> <td> Pellentesque mattis consequat ipsum sed sagittis. Pellentesque consectetur vestibulum odio, aliquet auctor ex elementum sed. Suspendisse porta massa nisl, quis molestie libero auctor varius. Ut erat nibh, fringilla sed ligula ut, iaculis interdum sapien. Ut dictum massa mi, sit amet interdum mi bibendum nec. </td> </tr> <tr> <td> Sed viverra massa laoreet urna dictum, et fringilla dui molestie. Duis porta, ligula ut venenatis pretium, sapien tellus blandit felis, non lobortis orci erat sed justo. Vivamus hendrerit, quam at iaculis vehicula, nibh nisi fermentum augue, at sagittis nibh dui et erat. </td> <td> Nullam mollis nulla justo, nec tincidunt urna suscipit non. Donec malesuada dolor non dolor interdum, id ultrices neque egestas. Integer ac ante sed magna gravida dapibus sit amet eu diam. Etiam dignissim est sit amet libero dapibus, in consequat est aliquet. </td> <td> Vestibulum mollis, dui eu eleifend tincidunt, erat eros tempor nibh, non finibus quam ante nec felis. Fusce egestas, orci in volutpat imperdiet, risus velit convallis sapien, sodales lobortis risus lectus id leo. Nunc vel diam vel nunc congue finibus. Vestibulum turpis tortor, pharetra sed ipsum eu, tincidunt imperdiet lorem. Donec rutrum purus at tincidunt sagittis. Quisque nec hendrerit justo. </td> </tr> </tbody> </table>

  • 6 The OP is looking for a multiple line solution. This only works on single lines of text. –  asimovwasright Commented Nov 17, 2016 at 18:28

I've been looking around for this, but then I realize, damn my website uses php!!! Why not use the trim function on the text input and play with the max length....

Here is a possible solution too for those using php: http://ideone.com/PsTaI

  • 22 You cannot safely use server-side processing because you cannot know in advance how much space the text will take in the page. It depends on font size, browser text size settings, browser zoom level, etc. –  ermannob Commented Jun 26, 2013 at 7:46

Not the answer you're looking for? Browse other questions tagged css text overflow ellipsis or ask your own question .

  • The Overflow Blog
  • The world’s largest open-source business has plans for enhancing LLMs
  • Looking under the hood at the tech stack that powers multimodal AI
  • Featured on Meta
  • Join Stack Overflow’s CEO and me for the first Stack IRL Community Event in...
  • User activation: Learnings and opportunities
  • What does a new user need in a homepage experience on Stack Overflow?
  • Announcing the new Staging Ground Reviewer Stats Widget

Hot Network Questions

  • What does "either" refer to in "We don't have to run to phone booths anymore, either"?
  • Removing undermount sink
  • Class and macro with same name from different libraries
  • Can noun phrase have only one word?
  • A certain solution for Sine-Gordon Equation
  • Determining Entropy in PHP
  • A word like "science/scientific" that can be used for ALL academic fields?
  • Is it ethical to request partial reimbursement to present something from my previous position?
  • Fantasy novel where a brother and sister go to a fantasy and travel with a one-armed warrior
  • Can I use a machine washing to clean neoprene wetsuits/socks/hoods/gloves if I use cold water, no spinning, no bleach and a gentle detergent?
  • How to translate the letter Q to Japanese?
  • Xcode 16.0 : unexpected service error: The Xcode build system has crashed
  • Rules on Feats When Creating Custom Backgrounds with Player's Handbook (2024)
  • LTspice Pulse Help
  • How to rectify a mistake in DS 160
  • Is there a "hard problem of aesthetics?"
  • Apple IIgs to VGA adapter
  • Counting the number of meetings
  • My math professor is Chinese. Is it okay for me to speak Chinese to her in office hours?
  • Would a scientific theory of everything be falsifiable?
  • How am I supposed to solder this tiny component with pads UNDER it?
  • Count squares in my pi approximation
  • Confusion about the definition of strict epimorphism
  • How to react to a rejection based on a single one-line negative review?

length of essay in css

Animate to height: auto; (and other intrinsic sizing keywords) in CSS

Use the interpolate-size property or the calc-size() function to enable smooth transitions and animations from lengths to intrinsic sizing keywords and back.

Bramus

Introduction

An often requested CSS feature is the ability to animate to height: auto . A slight variation of that request is to transition the width property instead of the height , or to transition to any of the other intrinsic sizes represented by keywords like min-content , max-content , and fit-content .

For example, in the following demo it would be nice if the labels would smoothly animate to their natural width when hovering the icons.

The CSS used is the following:

Even though a transition is declared to transition the width property, and width: auto is declared on :hover , no smooth transition happens. Instead, the change is abrupt.

Animate to and from intrinsic sizing keywords with interpolate-size

Browser Support

The CSS interpolate-size property gives you control over whether animations and transitions of CSS intrinsic sizing keywords should be allowed or not.

Its default value is numeric-only which does not enable interpolation. When setting the property to allow-keywords , you opt-in to interpolations from lengths to CSS intrinsic sizing keywords in the cases where the browser can animate those keywords.

As per spec :

  • numeric-only : An <intrinsic-size-keyword> cannot be interpolated.
  • allow-keywords : Two values can be interpolated if one of them is an <intrinsic-size-keyword> and the other is a <length-percentage> . […]

Because the interpolate-size property is one that inherits, you can declare it on :root to enable transitioning to and from intrinsic sizing keywords for the entire document. This is the recommended approach.

In the following demo, this rule is added to the code. As a result, the animations to and from width: auto work fine (in browsers with support):

Limit the reach of the opt-in by narrowing down the selector

If you want to limit the allow-keywords opt-in to only a subtree of your document, adjust the selector from :root to only the element that you want to target. For example, in case the <header> of your page is not compatible with these type of transitions, you could limit the opt-in to only the <main> element and its descendants as follows:

Why not allow animation to and from sizing keywords by default?

A common piece of feedback on this opt-in mechanism is that browsers should just allow transitions and animations from intrinsic sizing keywords to lengths by default .

The option to enable this behavior was researched during the development of the feature. The working group discovered that enabling this by default is not backward compatible because many style sheets assume that intrinsic sizing keywords (such as auto or min-content ) cannot be animated. You can find the details in this comment on the relevant CSS Working Group issue .

Therefore the property is an opt-in. Thanks to its inheritance trait, opting in an entire document is merely a interpolate-size: allow-sizes declaration on :root as detailed previously.

Animate to and from intrinsic sizing keywords with calc-size()

Another way to enable interpolation to and from intrinsic sizing keywords is to use the calc-size() function . It allows mathematics to be performed on intrinsic sizes in a safe, well-defined way.

The function accepts two arguments, in order:

  • A calc-size basis , which can be an <intrinsic-size-keyword> but also a nested calc-size() .
  • A calc-size calculation , which lets you perform calculations using the calc-size basis. To refer to the calc-size basis, use the size keyword.

Here are some examples:

Adding calc-size() to the original demo, the code looks like this:

Visually, the outcome is exactly the same as when using interpolate-size . So in this specific case you should use interpolate-size .

Where calc-size() does shine is its ability to do calculations, which is something that can't be done with interpolate-size :

For example, if you want all paragraphs on a page to be sized to the nearest multiple of 50px , you can use the following:

What calc-size() also lets you do is to interpolate between two calc-size() s when both their calc-size bases are identical. This too is something that can't be achieved with interpolate-size .

Why not allow <intrinsic-size-keyword> in calc() ?

A question that commonly pops up with calc-size() is why the CSS Working Group didn't adjust the calc() function to support intrinsic sizing keywords.

One of the reasons for this is that you are not allowed to mix and match intrinsic sizing keywords when doing calculations. For example, you could be tempted to write calc(max-content - min-content) which looks valid, but in reality it is not. calc-size() enforces correctness because it, unlike calc() , accepts only one single <intrinsic-size-keyword> as its first argument.

Another reason is context-awareness. Some layout algorithms have a special behavior for specific intrinsic sizing keywords. calc-size() is explicitly defined to represent an intrinsic size, not a <length> . Thanks to this, those algorithms are able to treat calc-size(<intrinsic-size-keyword>, …) as the <intrinsic-size-keyword> , maintaining its special behavior for that keyword.

Which approach to use?

In most cases, declare interpolate-size: allow-keywords on :root . It's the easiest way to enable animation to and from intrinsic sizing keywords as it's essentially a one-liner.

This piece of code is a nice progressive enhancement, as browsers that don't support it will fall back to using no transitions.

When you need finer grained control over things–such as doing calculations–or you want to use a behavior only calc-size() can do, you can resort to using calc-size() .

However, using calc-size() in your code will require you to include fallbacks for browsers that don't support calc-size() . For example, adding extra size declarations, or falling back to feature detection using @supports .

Here are some more demos that use interpolate-size: allow-keywords to their advantage.

Notifications

The following demo is a fork of this @starting-style demo . The code was adjusted to allow items with varying heights to be added.

To achieve this, the whole page opts in to size keyword interpolation and the height on each .item element is set to auto . Otherwise, the code is exactly the same as from before forking.

Animate the <details> element

A typical use-case where you'd want to use this type of interpolation is to animate a disclosure widget or an exclusive accordion as it opens. In HTML, you use the <details> element for this.

With interpolate-size: allow-keywords you can get pretty far:

As you can see, though, the animation only runs when the disclosure widget is opening. To cater for this, Chrome is working on the ::details-content pseudo which will ship in Chrome later this year (and which will be covered in a future post). Combining interpolate-size: allow-keywords and ::details-content , you can get an animation in both directions:

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2024-09-17 UTC.

IMAGES

  1. Css Essay, Outline And How to Achieve Required Length? RR Lectures

    length of essay in css

  2. CSS Length Units Lesson

    length of essay in css

  3. Css-Absolute length units

    length of essay in css

  4. How to Write an Essay in CSS

    length of essay in css

  5. CSS Length Units Lesson

    length of essay in css

  6. Html css text length

    length of essay in css

VIDEO

  1. CSS Essay Writing Skills & Techniques for CSS

  2. CSS Essay Writing Made Easy by Prof. Hasnain Jilani

  3. How to Collect Data For English Essay

  4. Examiner's Views on CSS English Essay? Dr.Noor ul Huda

  5. CSS Essay Writing Lectures 4

  6. CSS Essay Writing Course| To the point approach in CSS PMS Essay

COMMENTS

  1. How to Write an Essay for CSS Exam

    What should be the length of the CSS English essay? Your essay, outline included, should ideally be between 2500-3000 words. Does the quality of writing matter in the essay, or just the format? Both are essential for you to pass your CSS English essay component. The format is one of the first things an examiner looks at.

  2. Essay Preparation For CSS & PMS

    The Format of Essay in CSS. The CSS exam is more than merely scribbling notes and drafting odd ideas. Moreover, A standard essay consists of the following parts: Overview and Context: The introduction tells the reader and introduces the topic. Body Of the Topic: The candidate should write one paragraph regarding one facet of the issue in the body.

  3. Guidelines for Essay Writing for CSS / PMS Exam

    Avoid repetition of ideas. Avoid informal language for expressing your ideas. Apart from the above points, here are some basic principles of writing a standard essay: Unity: Your entire essay should be a composite reflection of the topic. There should be uniformity in the whole essay.

  4. Mastering CSS Essay Strategies: A Complete Guide by the ...

    Unlock the secrets to acing your essays in CSS essay writing! Join us on this informative podcast as we share expert advice on how to write high-scoring essa...

  5. How to Write an Essay for CSS? {Explained By Experts}

    According to Wikipedia, "The word essay derives from the French infinitive essayer, "to try" or "to attempt".In English essay first meant "a trial" or "an attempt", and this is still an alternative meaning.The Frenchman Michel de Montaigne (1533-1592) was the first author to describe his work as essays; he used the term to characterize these as "attempts" to put his ...

  6. PDF CSS, PMS & OTHER Techniques, Outlines and Complete Essays ...

    The word essay originally means an attempt or a try at some topic, but technically it usually means a comprehensive piece of writing on a specic topic. The purpose and given time of an essay determines its length and for students of CSS and PMS its length is 2500-3000 words or 20-25 paragraphs or 250-300 sentences. Every essay has four major

  7. How to Prepare English Essay for CSS / PMS? By: Iqra Shaukat

    c. Concluding lines. Last but not the least, you no longer need to write full length essay of 3000 words on regular basis. What you need to do is to write introduction, outlines, establishment of facts and conclusion. Do this practice from past papers and get it checked from senior or your mentor on regular basis.

  8. How to Write a CSS Essay Outline

    This video provides a structure and guideline on how to create an outline for the CSS essay exam.Link to our Facebook page (we will be sharing links of video...

  9. The Art of Essay Writing

    The Art of Essay Writing | CSS Essay | Step by step explanation with full length essay topicIn this video the art of essay writing is explained and after wat...

  10. Shanza Faiq

    August 2, 2019 ·. As promised, here are my tips on how to tackle the CSS english essay! 1. Ask the examiner for a second answer booklet and open its last page. Take a pencil, and write 'rough work' on top of the last page and do your brainstorming over here. Make a rough outline here, and it's completely okay to take 2-3 pages for rough work.

  11. Shanza Faiq

    Write each argument in a separate paragraph, but only ONE argument per paragraph. I would recommend a length of not more than half a page, or three-quarters of a page for one paragraph. ... As promised, here are my tips on how to tackle the CSS english essay! 1. Ask the examiner for a second answer booklet and open its last page. Take a...

  12. What should be the length of the essay

    The essays length should be minimum 2500. well, the questions pops up in everymind who just incline towards giving an attempt for CSS. Remember one thing, English essay is CSS counts more for the quality than quantity. But quantity shouldn't be undervalued. As this is a competitive exam ,one must put up all of his rational thoughts in best ...

  13. CSS Quiz

    W3Schools offers free online tutorials, references and exercises in all the major languages of the web. Covering popular subjects like HTML, CSS, JavaScript, Python, SQL, Java, and many, many more.

  14. CSS PMS English Essay Complete Preparation Material

    In most cases, CSS or PMS candidates consider that passing the English Essay paper depends upon luck, but this is not the reality. One also has to master English Precis & Composition in order to understand better English Essays. Remember that, in competitive exams mostly three types of essays are asked; Argumentative, Explanatory, and Quotation.

  15. Css Essay, Outline And How to Achieve Required Length? RR Lectures

    Essay, Outline And How to Achieve Required Length? RR Lectures.https://cssexamdesk.com/english-essay-syllabus-for-css-2022/.#essay#cssessay#essaywriting #how...

  16. Limit text length to n lines using CSS

    Is it possible to limit a text length to "n" lines using CSS (or cut it when overflows vertically). text-overflow: ellipsis; only works for 1 line text. original text: Ultrices natoque mus mattis, aliquam, cras in pellentesque tincidunt elit purus lectus, vel ut aliquet, elementum nunc nunc rhoncus placerat urna! Sit est sed!

  17. CSS , PMS English Essay/ How to write English Essay for CSS ...

    *Title:* Mastering CSS PMS Essay Writing: Structure, Parts, and Kinds*Description:*In this comprehensive video, we will guide you through the essential eleme...

  18. CSS World

    #LENGTH_OF_ESSAY Approaximate Length of Essay is usually asked, however that 'approximate has a liberal definition and any minor excess or shortage is usually not taken into account. Nonetheless...

  19. CSS Essay Introduction and Thesis Statement by Essay Topper Zariya

    Zariya Mushtaq's DMC: https://drive.google.com/file/d/1iVtDg6nAVBdhietbZodnp0jYTLJhi6zH/view?usp=sharingZariya Mushtaq's CSS Essay Introduction Notes in PDF:...

  20. Animate to height: auto; (and other intrinsic sizing keywords) in CSS

    The CSS interpolate-size property gives you control over whether animations and transitions of CSS intrinsic sizing keywords should be allowed or not.. Its default value is numeric-only which does not enable interpolation. When setting the property to allow-keywords, you opt-in to interpolations from lengths to CSS intrinsic sizing keywords in the cases where the browser can animate those ...

  21. CSS English Essay

    This video discusses how many Paragraphs a CSS English Essay should contain.#css #pmspunjab #englishessay

  22. Essay length in CSS Exam

    All CSS, PMS, and Tehsildar Exam Aspirants from Pakistan are advised to watch it if you want to enjoy learning a comprehensive approach to English Essay for...