1

I have a url I would like to split, so I essentially only have "Dub-Boro - Get Down.mp3"

http://dl.dropbox.com/u/**/Week%20of%20July%2025/Dub-Boro%20-%20Get%20Down.mp3

I was thinking of doing a split, but don't know how to approach it. Any ideas? Thanks

1 Answer 1

2
String[] path = uri.getPath().spit("/");
String mp3 = path[ path.length - 1 ];
Sign up to request clarification or add additional context in comments.

3 Comments

So the way I have it set up is that my url is changed to a string already. So I just need to split the string?
You can just split the string sure, but I'd keep this thing as URL. There is utility in having it wrapped in an object.
what about doing a string.replace()?

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.