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

  • SEARCH
  • Home
  • 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 7489565
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T15:16:13+00:00 2026-05-29T15:16:13+00:00

How would I use $(‘#flashObj’).append(); to add text to the two areas that say

  • 0

How would I use $('#flashObj').append(); to add text to the two areas that say “append_HERE” in the below code?

edit: what if I had it stored in a variable as a string and wanted to change the values that way?

var flashLayout = '<div id="flashObj">'+
    '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="200" height="20">'+
        '<param name="movie" value="dbs/js/singlemp3player.swf?file=append_HERE.mp3&autoStart=false&backColor=000000&frontColor=ffffff&songVolume=90" />'+
        '<param name="wmode" value="transparent" />'+
        '<embed wmode="transparent" width="200" height="20" src="dbs/js/singlemp3player.swf?file=append_HERE.mp3&autoStart=false&backColor=000000&frontColor=ffffff&songVolume=90" type="application/x-shockwave-flash" />'+
    '</object></div>'
  • 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-29T15:16:14+00:00Added an answer on May 29, 2026 at 3:16 pm

    Javascript (and jQuery) work with DOM nodes (elements as objects) not ‘text’.

    You can either get that code as HTML text and do a regular string replace like so:

    var f = $('#flashObj');
    f.html( f.html().replace('append_HERE', 'append_HERE_the_new_stuff') );
    

    Or, even better you should avoid playing with HTML as text and instead change the attribute itself:

    var f = $('#flashObj param:first');
    f.attr('value', f.attr('value').replace('append_HERE', 'append_HERE_the_new_stuff') );
    
    var f = $('#flashObj embed');
    f.attr('src', f.attr('src').replace('append_HERE', 'append_HERE_the_new_stuff') );
    

    PS: You will probably want to do a global replace using a regular expression since "bar bar".replace("bar", "foo") returns 'foo bar'.

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

Sidebar

Related Questions

I am writing a Facebook application that would use a Postgres DB along with
How you would use jQuery to implement a div that executes a link when
In Winforms I would use Application.ProductVersion to get the version of my code. Is
I'm writing a PHP function that would use a table of sorts to look
We're looking into developing a product that would use Amazon's cloud tools (EC2, SQS,
I would like to create an application that would use the same system as
What are some situations that you would use XHTMLRenderer (flying saucer) over JTextPane with
I would use the System.Linq.Dynamic . I added the specified Dynamic.vb file, that starts
Trying to work out a map reduce on mongo that would use field value
I am making a site for a client and decided i would use code

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.