You have to use another PPC Mac with a functioning optical drive. That means your PowerBook. The PB must have at least 512 MBs of installed RAM.
With both computers turned off connect a Firewire cable between them. Boot the PPC G4 into
Target Disk Mode. Boot the PB normally from the Leopard installer DVD. After the installer loads select your language and click on the Continue button. When the menubar appears select Disk Utility from the Utilities menu. Select the drive entry (mfgr.'s ID and drive size) of the PPC G4 from the left side list. Click on the Erase tab in the DU main window. Set the Format drop down menu to Mac OS Extended, Journaled then click on the Erase button.
After formatting has completed quit DU and return to the installer. Proceed with the installation. When you reach the point where you select a target volume be sure to select the volume for the PPC G4.