2012-08-20, 07:24 PM
There's nothing wrong necessarily, but the modal only shows when I click the link in the header. It doesn't work globally, though I could probably add a class/id to the images to hijack the action.
What I have figured out is stopping me is that no matter what group the user is in, the same showthread_newreply button is shown. Therefore, if I just add a name="modal" bit to it, it breaks all functionality for logged in users (shows just the mask). I know I could install PHP in Templates, but I don't want that security risk.
Maybe 1.8 and CSS buttons will help. If it works like I think, then a different button could be shown to guests from MyBB itself, and I could hijack just that button. But right now, I can't do much without a lot of work.
I suppose I could pop open showthread.php, create a new template, and if the user's ID is 0 (Guest), then a different showthread_newreply_guest template is eval'd. But then I need to forward the user to newreply, which is stopped by the event.preventDefault in the JavaScript. I suppose I could add a toURL variable in the JS, capture that, then forward. But then that variable would not be used 90% of the time and could break other parts of the forum.
What I have figured out is stopping me is that no matter what group the user is in, the same showthread_newreply button is shown. Therefore, if I just add a name="modal" bit to it, it breaks all functionality for logged in users (shows just the mask). I know I could install PHP in Templates, but I don't want that security risk.
Maybe 1.8 and CSS buttons will help. If it works like I think, then a different button could be shown to guests from MyBB itself, and I could hijack just that button. But right now, I can't do much without a lot of work.
I suppose I could pop open showthread.php, create a new template, and if the user's ID is 0 (Guest), then a different showthread_newreply_guest template is eval'd. But then I need to forward the user to newreply, which is stopped by the event.preventDefault in the JavaScript. I suppose I could add a toURL variable in the JS, capture that, then forward. But then that variable would not be used 90% of the time and could break other parts of the forum.