To make WebMatrix better, I suggest you ...

Bug using Ctrl+k+d in few places (') replaced with (")

This is right code:
<body id="page" class="page <?php echo $this['config']->get('body_classes'); ?>" data-config='<?php echo $this['config']->get('body_config','{}'); ?>'>

This is invalid code:
<body id="page" class="page <?php echo $this['config']->get('body_classes'); ?>" data-config="<?php echo $this['config']->get('body_config','{}'); ?>">

Find the difference and you will know what i am talking about this is changed when hitting Ctrl+k+d Formatting Code.

2 votes
Vote
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    I agree to the terms of service
    Signed in as (Sign out)
    You have left! (?) (thinking…)
    Damir PečnikDamir Pečnik shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

    2 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)
      Submitting...
      • Eric Wong (WebMatrix Tester)Eric Wong (WebMatrix Tester) commented  ·   ·  Flag as inappropriate

        Hi Damir,

        Are you using an html file or a php file when you are seeing this? I think what is going on is our html parser is seeing the first ' around config as then end of the attribute value and treating it as such (we don't process that <?php is the start of a php region).

        Unfortunately, that means we won't be able to fix this. That said, is it possible for you to use the following instead?

        <body id="page" class="page <?php echo $this['config']->get('body_classes'); ?>" data-config="<?php echo $this['config']->get('body_config','{}'); ?>" >

        by using " instead of ' around your attribute value, we should parse it correctly.

        Hope this helps.

        Eric

      Feedback and Knowledge Base