marc wrote: > Elias Soong said... >> Hello, >> >> I'm using PmWiki 2.1.3. I'd like to use a box to write comment or >> warning information. I knew it could be like this: >> >> >> bgcolor=#eeeeff border="1px >> dotted blue"<< >> %bgcolor=#ccccff% INFORMATION TITLE %%\\ >> INFORMATION CONTEXT >> >> << >> However, define a new markup in config.php may be a more convenient >> solution. I've read http://www.pmwiki.org/wiki/PmWiki/CustomWikiStyles . >> and added such lines at the end of config.php: >> >> $WikiStyle['box']['bgcolor'] = '#eeeeff'; >> $WikiStyle['box']['border'] = '"1px dotted blue"'; >> >> Nevertheless, all text between %box% and %% keep unchanged. May be I >> made something wrong, I wrote to ask for help. > > You need to use CSS attribute names. Thus: > > $WikiStyle['box']['background-color'] = '#eeeeff'; > $WikiStyle['box']['border'] = '1px dotted blue'; > >> Further more, is it possible to define a new box markup which not only >> control text in it but also a marked title? > > >>box<< > %bgcolor=#ccccff%INFORMATION TITLE%%\\ > INFORMATION CONTEXT > >><< > > works. But since you need to indicate which content is the title, you'll > need a tag of some sort, so a new style is as good as any. You could do: > > $WikiStyle['box']['background-color'] = '#eeeeff'; > $WikiStyle['box']['border'] = '1px dotted blue'; > $WikiStyle['title']['background-color'] = '#ccccff'; > > Then: > > >>box<< > %title%INFORMATION TITLE%%\\ > INFORMATION CONTEXT > >><< >
Thank you, Marc! It works perfect! That's what I need. Sincerely yours, Elias _______________________________________________ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users