Detect CMYK in Browser


 CMKY is supported in CSS3, but many browsers don’t provide support for it – and hence a problem if you have images rendered in it. CMKY as we well know, is used by designers and printing houses for it’s ease of use. As of CSS3 there is new color support; (with accompanying api calls) as below:

  1. HSL – hsl(hue, saturation, lightness)
  2. CMYK – cmyk(cyan, magenta, yellow, black)
  3. HSLA – hsla(hue, saturation, lightness, alpha)
  4. RGBA – rgba(red, green, blue, alpha)

A question in this direct context was asked on StackOverflow on how to detect CMYK support in the browser. 

Now there is three ways to resolve this:

  1. Server-Side Code (Asp.Net – Bitmap Api or Php – getImageSize – by looking at the image properties and maybe converting it to RGB to avoid this whole mess
  2. Browser Detection (jQuery/HTML Directive)  – mark those browsers that don’t support it, predominantly IE.
    1. if($.browser.msie && parseInt($.browser.version,10)<=8){}
      <!--[if IE 8]> <![endif]-->
  3. Javascript – validation by using the API and throwing an exception to validate it’s existence

I am going to be looking at the last method, number 3, as the prior two are real hacks and lead Alice down a Rabbit Hole she really shouldn’t traverse;




var IS_CMYK_SUPPORTED = (function(){

var value =‘cmyk(1%,1%,1%,0.5%)’,

el = document.createElement(‘p’),

result = false;

try { = value;

result = /^cmyk/.test(;

} catch(e) { }

el = null;

return result;




<bodyonLoad=‘alert(“IS CMYK Supported:” + IS_CMYK_SUPPORTED)’>



Simplistically, all that is happening here is a creation of an element to which we then try and set a color using the CMYK api. If the support is there we will return a valid result, if not the result will be false (via the exception thrown).
Hope this helps.
Reference the following URL for added information
Don't be shellfish...Share on FacebookShare on Google+Tweet about this on TwitterShare on LinkedInShare on TumblrEmail this to someone

God’s Truth: Dead To Sin

“Now the LORD is that Spirit: and where the Spirit of the Lord is, there is liberty” (2 Corinthians 3:17)


God’s Truth: Dead To Sin

If there is a stumbling block or hindrance to Christian growth and maturity, it is that of ‘sin’. Many people struggle with their sin, particularly ‘habitual sin’ as it leaves them defeated but more so ‘guilt-ridden’ to such an extent, they become paralyzed in their relationship with Jesus. How then does a Christian gain the victory over the giant that appears impossible to defeat? Let’s find the answer in scripture.


Wrong Kind of Thinking:

The reason why we behave in a particular manner, is a reflection of our thoughts as to how we see God. If a person see’s God as all loving (a Santa Clause), then that person’s life will reflect just that, but it may also speak further to that person’s relaxed attitude towards sin. Perhaps one of the reasons Christian’s struggle so much with habitual sin (pornography, masturbation, sexual immorality, sex before marriage), is because they believe Freudian Psychology of the day, and that is – “I am a product of my design and past”. Highly believed upon by Christians today and even preached by Pastors; is the teaching that we have a sin nature that we inherited from the fall of Adam and Eve. 


The result of this kind of thinking is that Christians believe that ‘sin’ is a battle they can never win. That is they believe that sin (particularly habitual) is a giant they cannot overcome; yes they may have seasons of trying to overcome this sin but eventually over time they surrender, and give-in! Some feel so defeated, they spiral out of control into further darker sins, like a person who has broken a strict diet, who then completely let’s go in a binge of eating – out of guilt for having broken their diet.


Right Kind of Thinking:

The man-made teaching that we are a product of our design or our past is a lie, and there is no scripture to back it up, unless we are saying God made us, or caused us to be sinful. That speaks to poor design, and then a God I would prefer not believing in. Genesis 2:16-17, “And the LORD God commanded the man, saying, Of every tree of the garden thou mayest freely eat: But of the tree of knowledge of good and evil, thou shalt not eat of it: for in the day that thou eatest thereof thou shalt surely die” – note that God was warning them that if they partook of the tree, then the judgement would be ‘death’. There is no mention here of sin being passed on from generation to generation as judgment for their failure, for if we had to follow that thought through we would then imply that God is not JUST, as we then would be born in sin, which would then mean that a baby who dies in the womb or at birth is destined for the pits of hell. God forbid!!!!


But Were Adam and Eve Not Dying Anyway?

 No, Genesis 3:22 says (after Adam and Eve had fallen into sin, by partaking of the fruit from the tree of good and evil) – “And the LORD God said, Behold, the man is become as one of us, to know good and evil: and now, lest he put forth his hand, and take also of the tree of life, and eat, and live for ever: Therefore the LORD God sent him forth from the garden of Eden…”. It was this “tree of life” that was giving them ‘eternal mortal life’ when they partook of it’s fruit, but when they sinned, they were removed from the Garden of Eden, and destined to ‘DIE’ physically as we are today. There was no spiritual death, nor a passing unfairly of their sin to us; but only the judgement of God by death. Romans 5:12 says “Wherefore, as by one man sin entered into the world, and death by sin; and so death passed upon all men, for that all have sinned:” – note the emphasis, that death passed unto all men, not sin; yes judgement fell upon all men (Romans 3:23) for all have sinned and come short of God’s glory; but it’s not INHERITED SIN from Adam, but each man and woman sinning of their own accord.


But Then How Are All Guilty Of Sin?

Because of our FLESH. We are not born sinful, but we have a tendency to sin, because our flesh enjoys comfort and luxury. Our flesh is our physical bodies (our passions and wants)and we know our bodies would rather do nothing, than do hard labour, it would rather eat sweets and chocolates, than fruit and vegetables. Our flesh is our hindrance and it is called by scripture, as the OLD MAN (Ephesians 4:22). But ok, how do I overcome sin if I have my body, my flesh? The answer is found in Romans 6, and it is the saved Christians Chapter of Victory! Romans 6:6 – “Knowing this, that our old man is crucified with him, that the body of sin might be destroyed, that henceforth we should not serve sin. For he that is dead is freed from sin”. 6:17 – “But God be thanked, that ye werethe servants of sin, but ye have obeyed from the heart that form of doctrine which was delivered you. Being then made free from sin, ye became the servants of righteousness”.


How we overcome is simple, we understand that we already have the victory over our ‘past sins’ in Jesus Christ. As Jesus died at Calvary, so too did our passions and lusts when we believed in Him. That doesn’t mean we are sinless, or that we will never sin; but it does mean that SIN is not a foe we can never defeat, nor a giant we can never overcome, but that it has already been defeated when we believed the Gospel of Jesus Christ. It doesn’t mean the temptation won’t be there to sin (we still have our flesh), but it does mean, that when we are tempted we MAKE THE CHOICE to give in or to say NO, but more so; we have the POWER in the Holy Spirit, as born-again children of God to just say NO! (1 Corinthians 10:13). It’s a simple concept, but it takes a while before it pierces the heart and is completely practical! You may not see this in your Christian experience, as you continue to commit habitual sin, but this is the TRUTH of the BIBLE, and the pathway to the VICTORY you ALREADY HAVE.


“But now being made free from sin,and become servants to God, ye have your fruit unto holiness, and the end everlasting life. Likewise reckon ye also yourself to be dead indeed unto sin, but alive unto God through Jesus Christ our LORD”. 


Victory over sin, is not through a focus on ‘not sinning’ but recognizing one’s existing victory and power over sin through belief in Jesus Christ, through fellowship in Jesus Christ and through the work of Jesus Christ on Calvary! Bless you!

Don't be shellfish...Share on FacebookShare on Google+Tweet about this on TwitterShare on LinkedInShare on TumblrEmail this to someone

God’s Church: Is It Necessary?

“Now the LORD is that Spirit: and where the Spirit of the Lord is, there is liberty” (2 Corinthians 3:17) 


God’s Church: Is It Necessary? 

Churches have always been pillars of light through the ages, cornerstones of society – for truth, for the gospel of Jesus Christ and homes to those seeking refuge from the world. However, there is much confusion today as to what ‘Church’ is, what it should be like and the need for us to attend Church; and thus the focus for today.


What is it? 

The first church began in Acts 2, as Peter preached and 3000 got saved – “Then they gladly received his word were baptized: and the same day there were added unto them three thousand souls” (Acts 2:41). Paying particular attention to these words, note they were not added to a building, or a body representing multiple churches, but rather to an existing group of ‘believers’. A Church is not a building, it’s the gathering or meeting of believers in Jesus Christ – who make up the body of Christ.

There are two types of ‘Church’ in the Bible; the Universal Church, which is the collection of all believers (saved christians) across all Churches, across the world (1 Corinthians 12:13). The second type of Church, is that of the Local Church, or a church found in a specific place (Romans 1:1, 1 Corinthians 1:2). That is, the church you attend will be your local church. The Universal Church – is a spiritual body (non-physical), whereas a local church is a physical gathering of people, who may or may not be saved.


What Church should I attend? 

Simple answer – attend a Church that holds fast to the Bible, as without it, there is no Christianity (Psalm 138:2, John 1:1, 2 Tim 2:15). Secondly, the Church should believe the Gospel of Jesus Christ, by that it should preach and teach how Jesus Christ (who is God’s Son and who is God), left heaven to come and die to pay the price for all our ‘sin’ – and that this is the only way one can enter into heaven. There are no merits, only the work of Jesus Christ at Calvary. Those two things should be enough to aid you in making a decision.Don’t make your decision however based on how ‘comfortable’ you are in the Church, or how warm and welcomed you felt, or the size of the church or it’s appearance – the two aforementioned points should be the sole basis for making that decision.


Why is it important? 

Because God has given you spiritual gifts and talents that are to be used for the building and the strengthening of the ‘Local Church(1 Corinthians 12). To not be part of a body of believers is selfish; and speaks to an abuse of what God desires and has given you by way of gift. Some may say, “but Churches have failed me and hurt me, I don’t see the point of attending one” – I believe the LORD could have said that about us, or even the disciples whom Him loved, and despite Him knowing they would betray Him, He still spent the majority of His time with them, teaching them and enabling them for the work He called them to do. Never let that be your excuse – it’s a poor one. We are too love others, despite what they may say about us, how they treat us, or how they may wrong us. That’s Christ’s example! 


Secondly, if you are a newborn Christian, you going to need some basic discipleship and encouragement to help you grow – and it is here that you will get that. You need wiser men and women, to teach you, encourage you and direct you. Faithful men and women are like ‘road-signs’ on a long journey – you don’t need them all the time, but at certain points they can faithfully give ‘necessary direction’.Thirdly, because you need the ‘preaching’ for growing in faith (Romans 10:17), for without “faith” it is impossible to please (Hebrews 11:6). A short overview, but some key points which emphasize the necessity for church attendance. Bless you!

Don't be shellfish...Share on FacebookShare on Google+Tweet about this on TwitterShare on LinkedInShare on TumblrEmail this to someone

God’s Word: Real World Application


Previously we looked at how God’s Word is Perfect which is pivotal to what we are going to look at today, so please review if necessary.The onus of today’s discussion however is that which the modern day Christian struggle’s with and that is the real-world application of their Bibles. There is so much Christian material – books, DVD’s, internet articles and tons of mp3 sermons online, and there is nothing wrong with that. However these things have become our ‘sustenance’ as opposed to the Word of God. That is, we see the Bible as just a ‘book’, and look for external sources to aid us in our trials, in that which we struggle with, while even considering or exploring psychology, a unbiblical approach. Our source for all things in this life then, is not Christ; but mediums through which we can experience Christ.


What We Do:

Christians today are found in a world that is ever-demanding, from media, to their jobs, friends, family and not to mention the Church. With all this pull, the Christian finds himself or herself, unsure and perplexed on how to manage all of this, or even to cope. Added to that is our own personal struggle with our ‘flesh’ and it’s demands, or put simply, our habitual sins.


And so, we go out looking for ways to survive and cope. We listen to the preaching on Sundays, but find it demanding even more from us. We search the Internet – passing in various keywords into Google to try and find something relevant or some other Christian who is going through the same difficulty as us. Perhaps our marriage is falling apart, or has reached a state, where both partners are in the ‘blame game’, and in wanting to save it, they resort to Christian psychologists or even modern day Freudian psychology. If you notice the pattern above, and I am sure you can identify, the intent of the heart is RIGHT, but it’s misdirection. How so?


What We Should Do:

Simply because unconsciously or by intent – we don’t believe the Bible can provide ‘real-world application’ to where we are at and what we are struggling with. And the reason we feel that way is because it’s not easy to get the answer – and so much so because we want the answer quickly. We’re not willing to ‘dig’, to allow God’s truth to permeate our lives, to spend time in prayer, to spend time studying God’s Word, and that is because we’re too busy, or too distracted. Why should I search for an answer to something, that someone has written about or already solved? That’s the approach.


This is not wrong in a sense, but what we do miss out on when we do this; that is for the opportunity to have our minds renewed by the reading of God’s Word, we miss the opportunity for us to learn the lesson ourselves, and far more, we miss the opportunity to build on our relationship with Jesus Christ. If in trial, we are searching the Bible for answers, pleading before God in prayer – through that process of taking our real world problems to Him – we start to grow in FAITH, to start to develop a dependence on God ALONE, and we start to gain a confidence in HIM (despite the harshest of storms).


The reasons people backslide or eventually leave Churches, or move away from Christianity despite having a head full of knowledge of Bible truth and doctrine, is that they never learnt by themselves, “How to get a hold of God”. That is, they never learnt, how to depend on Him fully for the answer to all their problems, and not just for the solution, but more so for strength to PUSH through and to carry on. Here are some verses to support the argument; (a) Psalm 27:14 (b) Psalm 119 (c) Proverbs 30:5 (d) Philippians 2:16

Don't be shellfish...Share on FacebookShare on Google+Tweet about this on TwitterShare on LinkedInShare on TumblrEmail this to someone