I know that if they use do_shortcode wrapper, then it is possible to nest the shortcodes, however, codex says :
"Although the parser will fail if the shortcode macro is used to do another macro of the same name:"
Is there a way around this?
For example, if I have a shortcode to create a div:
some content in [div] div [/ div] I want to be able to use:
[div] [div] a nested div [/ div] [/ div]
But this standard will fail with the do_shortcode wrapper.
I have a duplicate of the shortcode attached to _parent attached to my temporary outline name, but I have not created div_parent1, div_parent2 etc. only from the Nest 1 level depth ...
If you are writing a shortcut then there is a simple solution that you can write several shortcodes that call the same function. I have shortcodes to create HTML blocks such as divs, and many such names such as div, block1, block2 add_shortcode ('div', 'devondev_block'); Add_shortcode ('block', 'devondev_block'); Add_shortcode ('block2', 'devondev_block'); They all call the same function. They can be nested until you remember to use different short codes.
WordPress short code support is only suffixed with trying to parsing with regex, it is possible to do this type of parsing with a mixture of reggaeks, a finite state machine, and a stack. This approach can control nesting and can be very fast, especially when there are very few shortcodes every time I encounter it, I have to try.
Popular posts from this blog
I am currently working on a school project and I think that is to gather some problems with the MPEG file I The scope of my project is: 1) Split the MPEG file into pieces of many fixed sizes. 2) Collecting some of them and leaving some part. Problem 1: When I run the file in the media player, it will play the video until it reaches that segment which I left Give it Example: Chunk = ["yui_1", "yui_2", "yui_3", "yui_5", "yui_6"] Duration of each segment: 1 second * If you think I have left the "yui_4" section. * If I went to collect all the parts except "yui_4", then the video will play the first 2 seconds before being hanged throughout the period. Problem 2: When I gather the first part off the part, it is unable to run the full MPEG file is. Duration of each piece: 1 second Example: wheel = ["yui_2", "yui_3", "yui_4", "yui_5", "yui_6"...
I have created a crystal report with parameters, but this does not load the value. It only shows the title, I mean column name only. Please check your code and correct me. And I tried to load that report in PDF format, which shows an error like "Load report failed" Please correct me. Protected Zero Button 2_Click (Object Sender, EventArgs E) {Report Document Reports Document = New Report Document (); Reportdocument.Load (Server.MapPath ("CrystalReport.rpt")); Reportdocument.SetDatabaseLogon ("", "", "Arvind", "My ScamDDB"); Report document. Setpermator val ("mrno", textbox 1. text); CrystalReportViewer1.ReportSource = Report Document; } Secure Zero LinkButton1_Click (Object Sender, EventArgs E) {Exportport (); Private Zero Exports () {MemoriStream Ostream; Response.Clear (); reaction. Buffer = true; Report Document Report Document = New Report Document (); Reportdocument.Load (Server.MapPath ("CrystalReor...
While pagging my user model in kppp, I can sort with some values, but not others. For example, I can order results from created or email , for example, but username or reputation seems to come back order by arbitrary command for example with a list of users: $ this-> paginate = array ('condition' => array ( 'User.is_active' = & gt; true), 'border' => 24, 'order' => array ('User.created' => DESC)); Works as expected, but $ this - & gt; Paged = array ('conditions' = & gt; array (' user.isIactive '= & gt; true),' border '= & gt; 24,' command '= & gt; array (' user repeats' = ' & Gt; DESC ')); No, no. I first thought that this could be a database issue, but when I search the database directly, sorted as expected. Note: I am using Mangodebi with the Mongo DB plugin of Ichikawa for the KPPHP; Pagnetizing users are used to work properl...
Comments
Post a Comment