Href overrides dmx-bind:href

This is not a big deal, and not sure if this is a sudden bug, or a sudden fix. For the last couple of years that I have worked on this particular project, my menu items used dmx-bind:href but they also had a regular href tag like so:

href="#" dmx-bind:href="!url?varBaseUrl.value+url_name:url"

This worked fine until yesterday when some extension updates appeared and I installed them. I did not download 7 beta, just the extensions that showed up as having an update. So now, if the href="#" is combined with dmx-bind:href="!url?varBaseUrl.value+url_name:url" the regular tag takes precedent and the link doesn't work. Which is expected when an href tag uses a hashtag.

Only reason I bring it up is in case someone else suddenly has this issue and was stumped for a little bit as to why their menus suddenly stopped working. Like I said, perhaps the intention is for the regular tag to take preference over the dmx-bind. The only reason those regular tags were on there anyway, was probably my lack of experience with Wappler when I started this project or I copied and pasted them from somewhere that did use the hashtag and I didn't remove them after adding dmx-bind. They aren't needed.

Anyway, that was a very long explanation just to let you know what the fix is if you have both on a link....haha

-Twitch

The dynamic property should always override the static property, if it doesn't then it is a bug. Does this happen on all links or on specific routing links?

It appeared to be all links that I had in a repeat. Let me check if it happens or just a static link not generated in a repeat.

Yes it is. :wink:

Definitely a bug @patrick

fwiw, I too am using a ternary.

1 Like

Modifier prevent default is not working (I think)

<a href="/login" dmx-on:click.prevent="serverconnect_logout.load(true)" internal>Logout</a>

Edit: Could be unrelated, disregard

This has been fixed with the latest extensions updates.

1 Like

Hmmm...not fixed for me.

What versions of ac files should I be confirming?

Check if dmxRouting.js is version 3.0.4

I'm on 3.0.4 and can confirm this problem still exists in Wappler 6.8.0 It's affecting all links. Details are in this bug report:

I've posted an update in the other topic

Ok @mebeingken, I take it back about it not being a big deal, it wasn't so much when I thought it was just href tags, but input name tags are real gotchas if they are in a repeat like so.

name="id" dmx-bind:name="'formRepeat['+$index+'][id]'"

Was driving me crazy as to why the id wasn't set in the server side repeat. I won't say "no big deal" again I promise haha.

-Twitch

Fixed in the latest inline extensions updates.