The plaintiff, at the time of commencing an action of forcible entry or detainer or unlawful detainer, or at any time afterwards, upon filing the complaint, may apply to the superior court in which the action is pending for an order directing the defendant to appear and show cause, if any he or she has, why a writ of restitution should not issue restoring to the plaintiff possession of the property in the complaint described, and the judge shall by order fix a time and place for a hearing of the motion, which shall not be less than seven nor more than thirty days from the date of service of the order upon defendant. A copy of the order, together with a copy of the summons and complaint if not previously served upon the defendant, shall be served upon the defendant. The order shall notify the defendant that if he or she fails to appear and show cause at the time and place specified by the order the court may order the sheriff to restore possession of the property to the plaintiff and may grant such other relief as may be prayed for in the complaint and provided by this chapter.