Remove everything after a certain character remove replace (ok)

https://stackoverflow.com/questions/5631384/remove-everything-after-a-certain-character

var s = '/Controller/Action?id=11112&value=4444';
s = s.substring(0, s.indexOf('?'));
document.write(s);
// /Controller/Action

Last updated

Navigation

Lionel

@Copyright 2023