0

i have a jquery script. see fiddle here, that loads some scripts depending on what option i select.

there are a few problems.

  1. I cant make the js unload/hide when the other option is selected (what if i have more options?)

  2. and the script doesnt load inside #feed-1307038796890991 but next to it.. wired

any help much appreciated. Thanks

4
  • It seems like the code in fiddler is working correctly. It loads the script properly. I think that there is something in the response that is doing all the work. To give a proper answer, could we see this too? Commented Jun 2, 2011 at 21:46
  • Why are you using 1 element arrays? Commented Jun 2, 2011 at 21:53
  • My advice would be not to use this "bloople" thing. Just parse the RSS feeds yourself. They're not that complicated. Commented Jun 3, 2011 at 20:52
  • Oh wait, that'd be an XSS problem. Are the RSS feeds hosted on the same site, or are they someone elses? Commented Jun 3, 2011 at 21:16

1 Answer 1

1

Here's a better attempt:

http://jsfiddle.net/Eric/vLzCU/7/

I really can't see what was going through your head when you wrote the code. Why are there two single element arrays? And why are you using a variable to index them?

Sign up to request clarification or add additional context in comments.

3 Comments

those scripts are different each time the user selects an option
@Patrioticcow: I'm not sure what you're trying to say.
it is like i have 3 scripts and they are connected to those option from that list. in my fiddle example u can see that. the only problem there is that if there is a script already loaded, if i select another option the script that is already loaded doesn't disappear. to if i load 10 scripts they will all be loaded into the page. What i want is to load a script and unload/hide the others

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.