A three-dimensional porous photonic structure, whose internal pore surfaces can be provided with desired surface properties in a spatially selective manner with arbitrary patterns, and methods for making the same are described. When exposed to a fluid (e.g., via immersion or wicking), the fluid can selectively penetrate the regions of the structure with compatible surface properties. Broad applications, for example in security, encryption and document authentication, as well as in areas such as simple microfluidics and diagnostics, are anticipated.
 This work was supported by the United States government under the following grants: Air Force Office of Scientific Research Award FA9550-09-1-0669-DOD35CAP and Department of Energy Award DE-AC05-06OR23100. The government agency has certain rights in this invention.