SUBBUINDESIGN Blog

Top PHP Interview questions – 08

1001. How do I call a c program from php, it has to pass a string with it and have ti return a string? 1002. How do I run a php interface to a...

Top PHP Interview questions – 07

901. download file 902. test, mac 903. hide email address 904. How to submit form direct to email 905. How do I code a button that changes the value of a PHP variable? 906....

Top PHP Interview questions – 06

801. .How would you break up a delimited string into an array of substrings? 802. What regular expression syntax would you use to match the letter”b” at ;least once but not more than six...

Top PHP Interview questions – 05

500. when calling urls from a mysql database how do you make them active links on screen in php 501. How do I change this into a link? <?php echo $row_rsLocations [&#39;CODE&#39;] ; ?>...

Top PHP Interview questions – 04

401. How can i include a PHP PAGE on a non-php server?… I mean i want include a SIMPLE php page… 402. Why can&#39;t I get PHPSESSID to work (PWS on NT WorkStation 4.0,...

Top PHP Interview questions – 03

201. What is the PHP equivelent of ColdFusion&#39;s <CFHTTP> tag? (Both GET and POST operations) 202. What I do wrong to connect to a mysql DB-> Call to unsupported or undefined function mysql_connect() 203....

Top PHP Interview questions – 02

101. How do I write a php script within a php script to a file without escaping everything? 102. How can I create a dropdown for date field showing past 3 months, present month...

Top PHP Interview questions – 01

1. What Is PHP ? 2. How can I disable the output of error messages inside the HTML page? 3. Can I return other file formats (like Word, Excel, etc) using PHP? 4. Is...

Click Once and Unbind

Have something happen on a click event, but only once! Unbind the click handler after the element has been clicked once. $(‘#my-selector’).bind(‘click’, function() { $(this).unbind(‘click’); alert(‘Clicked and unbound!’); }); Also see Ben’s comment below...

Better Responsive Images Using Multiple Backgrounds

.bg-image { width: 100%; /* default background-position */ background-position: center center; /* lt ie 8 */ -ms-background-position-x: center; -ms-background-position-y: center; /* scale proportionately */ background-size: cover; /* IE8 workaround – http://louisremi.github.io/background-size-polyfill/ */ -ms-behavior: url(/backgroundsize.min.htc);...

Different Ways To Format CSS

Formatting has nothing whatsoever to do with how the CSS functions. These are merely aesthetic choices by the coder. But that’s not to say formatting isn’t important. That would be like saying the choice...

Swapping Out Text, Five Different Ways

It’s a common need in web apps: you click something and the text of the thing you just clicked changes. Perhaps something simple like a “Show” button that swaps to “Hide”, or “Expand Description”...

Centering Percentage Width/Height Elements

If you know the exact width/height of an element, you can center it smack dab in the middle of its parent element easily with this classic trick: top and left set to 50% and negative...

How to use fonts using CSS3 with fontface?

The CSS3 @font-face Rule Before CSS3, web designers had to use fonts that were already installed on the user’s computer. With CSS3, web designers can use whatever font he/she likes. When you have found/bought...

Book your train tickets from mobile through SMS

Now Book your train tickets using Mobile Phone, anywhere and anytime WITHOUT using Internet connection. Train passengers will be able to use their mobile phones to book tickets through a simple text-messaging-based-SMS facility or...

CSS3 Transitions

With CSS3, we can add an effect when changing from one style to another, without using Flash animations or JavaScripts. Internet Explorer 10, Firefox, Chrome, and Opera supports the transition property. Safari requires the...

How to use CSS3 Multiple Columns?

CSS3 Multiple Columns With CSS3, you can create multiple columns for laying out text – like in newspapers! In this chapter you will learn about the following multiple column properties: column-count column-gap column-rule Browser...

How to use CSS3 borders?

CSS3 Borders With CSS3, you can create rounded borders, add shadow to boxes, and use an image as a border – without using a design program, like Photoshop. In this chapter you will learn...

Web Design: A Guide To CSS3 Pseudo-Classes

The pseudo-classes are used to target elements without having to add extra classes, attributes or ID; that is why it is called in that way, pseudo-class. Throughout our previous posts, we havecovered a few new CSS3 pseudo-classes, including :not, :before and :after, :first-of-typeand we also...

Wrapping Content In Shapes With CSS3

How To Use Shape-Inside The shape-inside allows us to form four shapes: rectangle, circle, polygon, and ellipse, though the shape that seems to work at the moment, is only the polygon. In the following example, we will...

How to make responsive images using CSS and JSON

Current proposed responsive image solutions require that you inline media query values into HTML tags. <picture> <source media=”(min-width: 45em)” src=”large.jpg”> <source media=”(min-width: 18em)” src=”med.jpg”> <source src=”small.jpg”> <img src=”small.jpg” alt=””> </picture> This is a problem...

Windows 8 Hints and tips to increase the quality

Windows 8 has been with us for over half a year now, and if you’re used to previous versions of Windows then you’re going to notice that quite a bit has changed. In fact,...

How to make Underline Individual Words using jQuery?

jQuery $(‘h1’).each(function() { var words = $(this).text().split(‘ ‘); $(this).empty().html(function(){ for(i = 0; i < words.length; i++){ if(i == 0){ $(this).append(‘<span>’ + words[i] + ‘</span>’); } else { $(this).append(‘ <span>’ + words[i] + ‘</span>’); }...

Working with Attributes

Setting Single Attribute $(“img”).attr(“src”, “http://cdn.css-tricks.com/images/banner.jpg”); Setting Single Attribute (with function) $(“div”).attr(“id”, function (arr) { return “div-id” + arr; }) Setting Multiple Attributes $(“img”).attr({ src: “http://cdn.css-tricks.com/images/banner.jpg”, title: “banner”, alt: “banner” }); Getting Attribute var $source...