Is the a reason why the Create new account is a link rather than a button? To combat spam?
I would like to convert the link into a button. I had a look at the code, and this is the html_writer code that creates the link.
blocks/login_logout/block_login_logout.php
if (!empty($signup)) {
$this->content->footer .= html_writer::start_tag('div');
$this->content->footer .= html_writer::link(new moodle_url($signup), get_string('startsignup'));
$this->content->footer .= html_writer::end_tag('div');
}
In trying to mimic the Create New Account button in /login/index_form.html tried...
<?php
...
if (!empty($signup)) {
$this->content->footer .= html_writer::start_tag('div');
?>
<div class="signupform">
<form action="../signup.php" method="get" id="signup">
<div><input type="submit" value="<?php print_string("startsignup") ?>" /></div>
</form>
</div>
<?php
$this->content->footer .= html_writer::end_tag('div');
}
...
?>
but it doesn't work.
Any one can point me in the right direction? StackOverflow?
Cheers
Frankie Kam