Skip to main content

Addition of lightbox to my blogger template

Since i have started regularly blogging, i have felt the need for a small subpage or popup kind of feature where i can briefly explain things that do not need a dedicated blog post and where links to external pages would be 'a bit too much'.

I decided to use the lightbox effect for this. It would be the perfect solution to my problems. After a little googling, i came up with 2 amazing and simple implementations, one by Abhinay Rathore, this uses CSS and javascript, and the other is by Emanuele Feronato, which almost all css and even the minimal js is used to manipulate the css.

As I am extremely lazy and also was not entirely happy with both the implementations, i decided to mix the 2 and get my own lightbox. Abhinay's solution was something i found unnecessarily complex and Emanuele's solution was not elegant enough. My own solution is midway between these two and is satisfactory for personal reasons.( Yeah, click on the link. I already found a use for my new addition. )

Code's here.
and here is an example
Do play with those.
As always, do comment on the post and tell me if something can be made better.

Comments

Popular posts from this blog

In the right direction, perhaps ?

i've been toying around with a PHP framework called symfony . actually i wanted to know what MVC ( Model-View-Controller ) was, and i am really comfortable with PHP, so downloaded a copy and made a sandbox on my xampp htdocs directory. after i started playing around it just hit me that how much programming has simplified over the 12 years since i wrote my "hello world" program in c. where 150 people were needed to code a simple website back then, that too in about a year, now things can be done with just one or two programmers in about a fortnight. i think thats awesome. computers are finally doing what they were invented to do - to reduce human work. one really interesting thing is the askeet tutorial. here they guide you through making a replica of their site over 24 days, with each tutorial taking not more than one and a half hours to completely understand and implement. Also the symfony site itself is created on symfony, and that's really cool. ok, what hit me

Mind and Friendships

This post seems to be ( atleast in my mind ) a long one. but before i write about the topic of the blog post, i would like to describe my opinions of connected topics which will lead to the actual post. First let us look at the growth of the mind as a graph covering fixed points, each of which are a topic of knowledge. A person's mind, at the beginning of life is like a line ( connecting 2 points, hunger and mother's breast ) which comes into existence only at some points and otherwise is simply a blank. after a few months, the lines become more permanent and stressed. after some more time, as the child grows and learns and understands more things, some more points add to this. if we imagine our mind to be the space enclosed in these points, then we would have a multidimensional graph. (think a really very weirdly shaped object.). However, the " The mind, once expanded to the dimensions of larger ideas, never returns to its original size. " - Oliver Wendell

a keeper from kiterunner

today was watching kiterunner. awesome movie. it was this dialog that hit me hard - "Now, no matter what the mullah teaches, there is only one sin, only one. And that is theft. Every other sin is a variation of theft... When you kill a man, you steal a life. You steal his wife's right to a husband, rob his children of a father. When you tell a lie, you steal someone's right to the truth. When you cheat, you steal the right to fairness... There is no act more wretched than stealing, Amir."