Re: [Cppcms-users] What exactly url_mapper does?
Brought to you by:
artyom-beilis
From: Abhishek K. <abh...@gm...> - 2011-08-07 13:35:48
|
Hi, Could you please explain me these differences regarding the message board example application?: forums::forums(cppcms::service &srv) : master(srv) { dispatcher().assign(".*",&forums::prepare,this,0); mapper().assign("{1}"); // with id mapper().assign(""); // default } AND flat_thread::flat_thread(cppcms::service &s) : thread_shared(s) { dispatcher().assign(".*",&flat_thread::prepare,this,0); mapper().assign("{1}"); } I have referred the doxygen documentation, but still failed to make out much meaning regarding this particular problem. could you tell me as to why in forums constructor it was possible to have 2 mapper().assign() one for "" and other for "{1}" whereas, in flat_thread, it has only 1 mapper().assign() statement and thats "{1}". What conditions tell us that it would require 2 or 1 assign statements? I fully understand the dispatcher but this mapper, I am unable to. Hope you understand my problem. Please let me know if I am missing the basics of anything, i will refer it. Thanks in advance for your reply. |