Showing posts with label twitter. Show all posts
Showing posts with label twitter. Show all posts

Wednesday, 10 August 2016

Twitter Bootstrap Interview Questions and Answers

Twitter Bootstrap Interview Questions and Answers

Question: How to make twitter bootstrap menu dropdown on hover rather than click?
ul.nav li.dropdown:hover > ul.dropdown-menu {
    display: block;    

Question: How can I make Bootstrap columns all the same height??
.row {
  display: -webkit-box;
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  flex-wrap: wrap;
.row > [class*='col-'] {
  display: flex;
  flex-direction: column;

Question: What is sr-only in Bootstrap 3??
It is class used to hide information intended only for screen readers from the layout of the rendered page.

Question: How to disallow twitter bootstrap modal window from closing?
<a data-backdrop="static" data-controls-modal="my_div_id" data-keyboard="false" href=""></a>

Question: What are different 4 tiers in twitter bootstrap?
  1. Extra small devices like smartphones (.col-xs-*)
  2. Small devices like tablets(.col-sm-*)
  3. Medium devices like laptops (.col-md-*)
  4. large devices like laptops/desktops(.col-lg-*)

Question: How to use media queries in twitter bootstrap 3?

Question: How to use media queries in twitter bootstrap 4?

Question: What is an em?
An em is a unit in the field of typography, One em is equal to the 16 point size.

Question: How to open a Bootstrap modal?

Question: How to make responsive image with align center?
.img-responsive {
    margin: 0 auto;

Question: How to create Confirm box before deleting modal/dialog?
Add data-target="#confirm-delete-id" in A tag

<a data-href="/delete-rec?id=203" data-target="#confirm-delete-id" data-toggle="modal" href="">Delete record #203</a>

Add HTML for confirmation box
<div aria-hidden="true" aria-labelledby="myModalLabel" class="modal fade" id="confirm-delete-id" role="dialog" tabindex="-1">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<div class="modal-body">
<div class="modal-footer">
<button class="btn btn-default" data-dismiss="modal" type="button">Cancel</button>
                <a class="btn btn-danger btn-ok" href="">Delete</a>


Question: How to disabled the button?
$('#buttonId').prop('disabled', true);

Monday, 16 November 2015

How to Send Tweets automatically with PHP?

How to Send Tweets automatically with PHP

Basic Requirements
  1. An Twitter account.
  2. An Twitter app. If don't have please create @
  3. Twitter Auth REST API, If don't have please download from
  4. An Server, You can also test in local wampserver or xampserver

How to Send Tweets automatically with PHP, Follow following Steps:
  1. Include twitter files.
  2. Collect all constants values from your twitter app (i.e

  3. Add constants in TwitterOAuth constructor.
    define('CONSUMER_KEY', 'YOUR_KEY');
    define('ACCESS_TOKEN', 'YOUR_TOKEN');
  5. Now post the message.
    $message='This is test tweet.';
    $twitter->post('statuses/update', array('status' => $message));
  6. Refresh the, you will see your message at top of page.

Wednesday, 22 April 2015

Twitter login failed leads to Page not found

I have integration Twitter Sign and Its working fine. :)
Problem: When any user sign in with wrong credentials, It redirect to "Sorry, that page doesn’t exist!"
I am assuming, It should remain on same page, so that user can retry!.

Please see screenshot below:

I am Expecting, It must on same page if some one add wrong credentials. So that user can retry.


See First login screenshot.
You are using Below URL for authentication

Authentication URL Must be start with like below

Sunday, 12 April 2015

Share count and Share URL of Facebook, Twitter, LinkedIn and Pinterest

Share count and Share URL of Facebook, Twitter, LinkedIn and Pininterest.

Share Count: There are different free api to get the share count of Facebook, Twitter, Linkedin and Pininterest. These number number of counts by all users.

Facebook Share (33)

   "id": "",
   "shares": 33

Twitter Share (7)


Linkedin Share (6)

Pinterest Share (0)

Share URL:Each Social Services (Facebook, Twitter, Linkedin and Pininterest), have its own sharing URL and its work on all global browsers.

Facebook Share (33)

Twitter Share (7)

Pinterest Share (0)

Linkedin Share (6)

Share on Twitter with Custom Text

Share on Twitter with Custom Text and Via

Monday, 24 November 2014

How to setup your twitter App?

How to setup your twitter App?

Setup your App in

  1. Login to (If Not registered, please register first)
  2. Add Mobile Number and verify (
  3. Go to Manage Apps page (i.e
  4. Create a New App
  5. Fill all required info
  6. In "What type of access does your application need" set "Read and write"
  7. Save API Key and API secret (Consumer key and Consumer Secret key)

Follow PHP Work from Below sites(I have test this, Its working)