in reply to BBCode Parser in configuration file

YAML can save objects into a file:
use strict; use YAML::Any; use DateTime; my $dt = DateTime->new( year => 1964, month => 10, day => 16, hour => 16, minute => 12, second => 47, nanosecond => 500000000, time_zone => 'Asia/Taipei', ); print Dump($dt);
Output:
--- !!perl/hash:DateTime formatter: ~ local_c: day: 16 day_of_quarter: 16 day_of_week: 5 day_of_year: 290 hour: 16 minute: 12 month: 10 quarter: 4 second: 47 year: 1964 local_rd_days: 717260 local_rd_secs: 58367 locale: !!perl/hash:DateTime::Locale::en_US default_date_format_length: medium default_time_format_length: medium en_complete_name: English United States en_language: English en_territory: United States id: en_US native_complete_name: English United States native_language: English native_territory: United States offset_modifier: 0 rd_nanosecs: 500000000 tz: !!perl/hash:DateTime::TimeZone::Asia::Taipei is_olson: 1 max_year: 2018 name: Asia/Taipei spans: - - -1.#INF - 59800434840 - -1.#INF - 59800464000 - 29160 - 0 - LMT - - 59800434840 - 61357104000 - 59800463640 - 61357132800 - 28800 - 0 - CT - - (... SNIP ...) - - 62474770800 - 1.#INF - 62474799600 - 1.#INF - 28800 - 0 - CST utc_rd_days: 717260 utc_rd_secs: 29567 utc_year: 1965

CountZero

A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

Replies are listed 'Best First'.
Re^2: BBCode Parser in configuration file
by Pr0t0n (Novice) on Jul 04, 2009 at 23:45 UTC
    Hmmm... yes read about that in a search, but I don't think that's gonna work for me because
    I can't use any of the variables of it in plain text 'cause that string is needed by this module:

    http://search.cpan.org/~tinita/Parse-BBCode-0.09/lib/Parse/BBCode.pm

    So I need that entire string from $p = Parse::BBCode-new();
    as an object and not in plain text, maybe I explain it wrong, if you follow that link
    you get BBCode parser I use.

    Hope you can help,
    Pr0t0n
      but I don't think that's gonna work for me
      Did you actually try it? You have to show some effort yourself.

      CountZero

      A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

        The only thing I needed was a push in the right direction and now finally a monk could give it to me, in this topic has he the right answer: http://www.perlmonks.org/?node_id=619561, but thanks for the help that you could give me, I appreciate it. Maybe you should read that topic it comes in handy, ones in a while.

        Greetz Pr0t0n
      A reply falls below the community's threshold of quality. You may see it by logging in.