Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I get a html code from some site(e.g. using vala(gtk)?

share|improve this question
stackoverflow is a better site for programming questions. – João Pinto Jan 7 '11 at 17:17
Ok, I will ask this question on stackoverflow. – kv1dr Jan 7 '11 at 18:24
There was a discussion about this earlier in Chat. Conclusion: This is a perfectly acceptable question for AU. As AU is for Ubuntu Users and Developers. Vala being a language for Gnome which is the default shipped desktop environment it is on topic. You're more than welcome to ask on StackOverflow but don't fret if you fear this is offtopic. If you feel differently please open a meta topic – Marco Ceppi Jan 7 '11 at 18:49
up vote 5 down vote accepted

Use the Vala GIO File open shown here

var web_page = File.new_for_uri ("");

This is the standard method of grabbing files and web pages and you can use the uri syntax for a number of supported protocols such as ssh, ftp, etc.

share|improve this answer
Thank you for code and for link. It works like a charm. – kv1dr Jan 7 '11 at 18:49

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.