Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6058545
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T08:36:39+00:00 2026-05-23T08:36:39+00:00

I need to add facebook twitter and google +1 button to a dynamically generated

  • 0

I need to add facebook twitter and google +1 button to a dynamically generated web page.
I am explaining my use case here:

User comes to my web portal which is a java/j2ee based web portal and adds few content (e.g. name,address, company, designation, place and also his picture.)

Then, I am generating a page like facebook profile page, http://www.mydomain.com/user_name.

So my goal is to add his contents along with the url and picture to his/her facebook wall using facebook share button.

I went through few codes that I got, one simple example is:

<a href="javascript:window.location=%22http://www.facebook.com/sharer.php?u=%22+encodeURIComponent(document.location)+%22&#38;t=%22+encodeURIComponent(document.title)" title="Share on Facebook..."><img src="/path/to/your/image/" width="12" height="12" alt="alt" /></a>

Can I enhance the same code to get my needs done? Also I need to twitter the same content. But I am not able to do it dynamically. How do I do that? Any reference or tutorials or code sample would be helpful.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T08:36:40+00:00Added an answer on May 23, 2026 at 8:36 am
    <a href="http://twitter.com/share" 
       data-url="http://your.url.com/yourdynamicpage" 
       class="twitter-share-button" 
       data-text="What should I share?" 
       data-count="horizontal">
    Tweet
    </a>
    <script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
    

    This will work

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to retrieve a user's email when they use facebook login on my
I'm trying to add facebook like button and twitter tweet button on a list,
I would like to add a Facebook like button to my asp.net page. I
I wanted to add user search auto-complete (like Facebook's) to my Rails app on
How do I add a FaceBook 'like' button to my master pages, does it
Why we need to add these pair of tags within our facebook application. What's
I need to be able to retrieve Facebook Places associated with a user's photos,
I need to add a custom field with the fb:request-form tag in facebook. ie:-
I need to provide Add Friend link in my facebook connect application. If I
I need to update my Facebook Fan Page in a django app so I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.