Amanda Bynes has been placed on an immediate, extended 30-day psychiatric hold, ahead of a planned conservatorship hearing Friday morning in L.A.

Doctors at the psychiatric hospital where the troubled actress has been held the last two weeks determined she was not well enough to leave the hospital to attend the hearing, where Bynes's parents are trying to win temporary conservatorship.

Bynes's doctors went to the judge overseeing the actress's case, sources told TMZ, and the judge traveled to the hospital to conduct an emergency hearing.

After that meeting, the judge granted the doctors' request.

According to the law, doctors can only get such an order if the patient is "gravely disabled as a result of a mental disorder."

Bynes's parents can still pursue temporary conservatorship, which would allow them to control her finances.