No provision of this code or of any law of this State which makes unlawful the use of the flag of the United States or of this State or of any picture or representation thereof shall apply to any act permitted by the statutes of the United States or of this State or by any regulations of the United States Army, or United States Air Force, or United States Navy, nor shall it be contrued to apply to any newspaper, periodical, book, pamphlet, circular, certificate, diploma, warrant or commission of appointment to office, ornamental picture, article of jewelry, or stationery for use in correspondence, on which is printed, painted, or placed a flag with no design or writing thereon and not connected with any advertisement.