Solution Timeline

All versions (edits) of solutions to Image sharing on Twitter page appear below in the order they were created. Comments that appear under revisions were those created when that particular revision was current.

To see the revision history of a single solution (with diffs), click on the solution number (ie. "#1") in the upper right corner of a solution revision below.

← Bounty Expand all edits
  1. Download this and unzip.
  2. Add your application consumer key and consumer secret key to the secret.php file in the lib directory.
  3. Enjoy!

Overview

I used a combination of both Jaisen Mathai's Twitter-Async Library and Matt Harris' Twitter OAtuh library. To complete your request. The final result is a one page PHP file that should do the job.

Instructions

  1. Download this and unzip.
  2. Add your application consumer key and consumer secret key to the secret.php file in the lib directory.
  3. Enjoy!

Overview

I used a combination of both Jaisen Mathai's Twitter-Async Library and Matt Harris' Twitter OAtuh library. To complete your request. The final result is a one page PHP file that should do the job.

Instructions

  1. Download this, unzip, and upload it to your webserver.
  2. Add your application consumer key and consumer secret key to the secret.php file in the lib directory.
  3. Enjoy!

Note(s)

The code is set to echo the URL of the image from the PHP into the HTML because to try and get it from the <div> would require possibly another HTTP request and the PHP script allows for only one request and then it will clear the session.

Overview

I used a combination of both Jaisen Mathai's Twitter-Async Library and Matt Harris' Twitter OAtuh library. To complete your request. The final result is a one page PHP file that should do the job.

Instructions

  1. Download this, unzip, and upload it to your webserver.
  2. Add your application consumer key and consumer secret key to the secret.php file in the lib directory.
  3. Enjoy!

Note(s)

The code is set to echo the URL of the image from the PHP into the HTML because to try and get it from the <div> would require possibly another HTTP request and the PHP script allows for only one request and then it will clear the session.

The end result looks like this

Overview

I used a combination of both Jaisen Mathai's Twitter-Async Library and Matt Harris' Twitter OAtuh library. The final result is a one page PHP file that should do the job. If you would like to test it out, I have a demo here.

Instructions

  1. Download this, unzip, and upload it to your webserver.
  2. Add your application consumer key and consumer secret key to the secret.php file in the lib directory.
  3. Enjoy!

Note(s)

The code is set to echo the URL of the image from the PHP into the HTML because to try and get it from the <div> would require possibly another HTTP request and the PHP script allows for only one request and then it will clear the session.

The end result looks like this

Overview

I used a combination of both Jaisen Mathai's Twitter-Async Library and Matt Harris' Twitter OAtuh library. The final result is a one page PHP file that should do the job. If you would like to test it out, I have a demo here.

Instructions

  1. Download this, unzip, and upload it to your webserver.
  2. Add your application consumer key and consumer secret key to the secret.php file in the lib directory.
  3. Enjoy!

Note(s)

The code is set to echo the URL of the image from the PHP into the HTML because to try and get it from the <div> would require possibly another HTTP request and the PHP script allows for only one request and then it will clear the session.

The end result looks like this

Overview

I used a combination of both Jaisen Mathai's Twitter-Async Library and Matt Harris' Twitter OAtuh library. The final result is a one page PHP file that should do the job. If you would like to test it out, I have a demo here.

Instructions

  1. Download this, unzip, and upload it to your webserver.
  2. Add your application consumer key and consumer secret key to the secret.php file in the lib directory.
  3. Enjoy!

Note(s)

The code is set to echo the URL of the image from the PHP into the HTML because to try and get it from the <div> would require possibly another HTTP request and the PHP script allows for only one request and then it will clear the session.

The end result looks like this

Overview

I used a combination of both Jaisen Mathai's Twitter-Async Library and Matt Harris' Twitter OAtuh library. The final result is a one page PHP file that should do the job. If you would like to test it out, I have a demo here.

Instructions

  1. Download this, unzip, and upload it to your webserver.
  2. Add your application consumer key and consumer secret key to the secret.php file in the lib directory.
  3. Enjoy!

Note(s)

The code is set to echo the URL of the image from the PHP into the HTML because to try and get it from the <div> would require possibly another HTTP request and the PHP script allows for only one request and then it will clear the session.

The end result looks like this

If you are trying to accomplish something like in Instagram (where an image is share in twitter, you click to expand it's details and view a thumbnail, you might want to take a look at the Twitter Cards.

  1. You will have to fill out a form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards.

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards.

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

End result :

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards.

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

End result :

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards.

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

End result :

http://dev.twitter.com/sites/default/files/images_documentation/card-web-photo_0_0.png

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards.

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

End result :

http://dev.twitter.com/sites/default/files/images_documentation/card-web-photo_0_0.png
End Result

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards.

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

End result : Notice the extra details underneath the image in the expanded view

End Result

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

End result : Notice the extra details underneath the image in the expanded view

End Result

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

End result : Notice the extra details underneath the image in the expanded view

End Result

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

End result : Notice the extra details underneath the image in the expanded view

End Result

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>

End result : Notice the extra details underneath the image in the expanded view

End Result

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>


End result : Notice the extra details underneath the image in the expanded view

End Result

If you are trying to accomplish something like in Instagram (where an image is shared in twitter, and once you click it expand it's details and view a thumbnail underneath the Tweet, you might want to take a look at the Twitter Cards

  1. You will have to fill out a quick and easy form with your site's details - https://dev.twitter.com/form/participate-twitter-cards

  2. You will have to make an image details page where you only display an individual image. eg: image-details.php

  3. On top of that image-details.php page add

  4. In the image gallery page, link the tweet this button to - http://twitter.com/home?status=<?php echo urlencode("Sample twitter status update - http://domain.com/image-details.php?imgId=123"); ?>


End result : Notice the extra details underneath the image in the expanded view

End Result

Overview

I used a combination of both Jaisen Mathai's Twitter-Async Library and Matt Harris' Twitter OAtuh library. The final result is a one page PHP file that should do the job. If you would like to test it out, I have a demo here.

Instructions

  1. Download this, unzip, and upload it to your webserver.
  2. Add your application consumer key and consumer secret key to the secret.php file in the lib directory.
  3. Enjoy!

Note(s)

The code is set to echo the URL of the image from the PHP into the HTML because to try and get it from the <div> would require possibly another HTTP request and the PHP script allows for only one request and then it will clear the session.

The end result looks like this

Winning solution