I found the solution to my question just 2 days ago.
In order to be able to switch quickly between work and home, I wanted to write a script which changes my proxy configuration for all applications at once. Most of the applications were easy, they all had some kind of configuration file, for which I just created a copy to use for work and for home.
The system proxy however, is saved in gconf. To make switching easy, I went to the network settings, changed the proxy to manual and entered all my information for the proxy (host & port).
Then if I wanted to surf without proxy, I simply had to execute the following command:
gsettings set org.gnome.system.proxy mode 'none'
In order to switch back to the proxy connection I had to use the following command:
gsettings set org.gnome.system.proxy mode 'manual'
No need to specify host & port again, since those are already saved. If, however, you have to work with several proxies and would need to switch between different hosts, you can specify the proxy data with the following commands:
gsettings set org.gnome.system.proxy.http port 8080
gsettings set org.gnome.system.proxy.http host 172.16.1.1
Changes take effect immediately.
Source