http status code in khtml
Miroslav Suchý
miroslav at suchy.cz
Sun Aug 20 10:46:42 BST 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
David Faure napsal(a):
> On Friday 27 January 2006 16:04, Miroslav Suchý wrote:
>> David Faure wrote:
>>> On Tuesday 24 January 2006 19:40, Miroslav Suchý wrote:
>>>> So I change and specify my question:
>>>> I have class derived from KHTMLPart and I need access to HTTP headers of
>>>> opened page. Can somebody point me where I can find it?
>>>>
>> > job->addMetaData("PropagateHttpHeader","true") should give you the
>> HTTP headers
>>> at the end of the job. When using KHTMLPart, you can connect to started(KIO::Job*) in order
>>> to get the job instance being used to download the stuff.
>> Why I do not get job instance?
>
> Because my advice was crap, actually. Look at khtml_part.cpp, it says emit started(0).
> This is because we don't want the progress info to depend on this job only, so it passes 0.
>
> I think you need to modify KHTMLPart to add a job() method, implemented as:
> KIO::Job* KHTMLPart::job() {
> return d->m_job;
> }
>
> Right now the job is completely internal to KHTMLPart, I see no way of accessing it
> from the outside.
>
> Or (binary incompatible, so for kde4), we could add a virtual void startingJob( KIO::Job * ) { }
> so that derived classes can do something with that job before it gets started.
> Connecting signals to it would have the undefined-order-of-slots problem though,
> so we should probably also make slotFinished() virtual in kde4.
>
Hi,
I was just checking developer release of KDE 4.0 and I hoped I'll find
these methods we spoke about in January. But I cannot find them nor
anything similar.
Summary:
I need to get http status code of page in KHTML. This is now not
possible. And David suggested to add in KDE 4.0 these method to:
in KHTMLPart:
KIO::Job* KHTMLPart::job() {
return d->m_job;
}
and
virtual void startingJob( KIO::Job * ) { }
which will be called before job is started.
Can these method be implemented in current KDE 4, before will be finall
release?
Regards
Miroslav Suchy
- --
,,,
(o o)
=================================oOO==(_)==OOo===========
) mailto:miroslav at suchy.cz
( ICQ: #70802630 tel:+420-603-775737 skype:MiroslavSuchy
) Pracujte opatrně s vodou. Je plná vodíku a kyslíku.
(________________________________________Oooo._____________
.oooO ( )
( ) ) /
\ ( (_/
\_)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFE6C+CZmvK+vtVT0wRAg7bAKCBYssQKYjoV+AJ9n7jEijFb9ImQACfSbNt
ekjjedBnVzljkbJCTUB4qCM=
=IYBh
-----END PGP SIGNATURE-----
More information about the kfm-devel
mailing list