<div dir="ltr">What about using urlparse: <a href="http://docs.python.org/2/library/urlparse.html">http://docs.python.org/2/library/urlparse.html</a>?</div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/12/7 Gino Pirelli <span dir="ltr"><<a href="mailto:luipir@gmail.com" target="_blank">luipir@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><span style="font-family:arial,sans-serif;font-size:12.800000190734863px">Hi Luca</span><div style="font-family:arial,sans-serif;font-size:12.800000190734863px">
<br></div><div style="font-family:arial,sans-serif;font-size:12.800000190734863px">

usign QT you can:</div><div style="font-family:arial,sans-serif;font-size:12.800000190734863px"><br></div><div style="font-family:arial,sans-serif;font-size:12.800000190734863px">create QUrl and then query "url" with it's method  queryItemValue</div>


<div style="font-family:arial,sans-serif;font-size:12.800000190734863px"><br></div><div style="font-family:arial,sans-serif;font-size:12.800000190734863px">probably there's a pure python method... that it's always better reducing QT coupling. If you find a pure python way... please post it.</div>


<div style="font-family:arial,sans-serif;font-size:12.800000190734863px"><br></div><div style="font-family:arial,sans-serif;font-size:12.800000190734863px">ciao Ginetto</div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra">
<br><br><div class="gmail_quote">

On 6 December 2013 10:47, Luca Delucchi <span dir="ltr"><<a href="mailto:lucadeluge@gmail.com" target="_blank">lucadeluge@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


Hi everybody,<br>
<br>
I have a WFS layer and I would like to obtain the server url using pyqgis.<br>
Now I'm using layer.source(), but it return the entire url with all<br>
the parameters.<br>
Is there a way to abtain only the server url?<br>
When QGIS create the string for the request it append every time<br>
REQUEST parameter for first? Could I split the string using it?<br>
<br>
Thanks<br>
<span><font color="#888888"><br>
--<br>
ciao<br>
Luca<br>
<br>
<a href="http://gis.cri.fmach.it/delucchi/" target="_blank">http://gis.cri.fmach.it/delucchi/</a><br>
<a href="http://www.lucadelu.org" target="_blank">www.lucadelu.org</a><br>
_______________________________________________<br>
Qgis-developer mailing list<br>
<a href="mailto:Qgis-developer@lists.osgeo.org" target="_blank">Qgis-developer@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-developer" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br>
</font></span></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
Qgis-developer mailing list<br>
<a href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-developer" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Giovanni Allegri<br>
<a href="http://about.me/giovanniallegri" target="_blank">http://about.me/giovanniallegri</a><br>blog: <a href="http://blog.spaziogis.it" target="_blank">http://blog.spaziogis.it</a><br>GEO+ geomatica in Italia <a href="http://bit.ly/GEOplus" target="_blank">http://bit.ly/GEOplus</a>
</div>